@@ -25,6 +25,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
2525#include " nodedef.h"
2626#include " nodemetadata.h"
2727#include " gamedef.h"
28+ #include " irrlicht_changes/printing.h"
2829#include " log.h"
2930#include " nameidmapping.h"
3031#include " content_mapnode.h" // For legacy name-id mapping
@@ -91,13 +92,13 @@ bool MapBlock::onObjectsActivation()
9192 return false ;
9293
9394 verbosestream << " MapBlock::onObjectsActivation(): "
94- << " activating objects of block " << PP ( getPos () ) << " ("
95+ << " activating objects of block " << getPos () << " ("
9596 << m_static_objects.getStoredSize () << " objects)" << std::endl;
9697
9798 if (m_static_objects.getStoredSize () > g_settings->getU16 (" max_objects_per_block" )) {
9899 errorstream << " suspiciously large amount of objects detected: "
99100 << m_static_objects.getStoredSize () << " in "
100- << PP ( getPos () ) << " ; removing all of them." << std::endl;
101+ << getPos () << " ; removing all of them." << std::endl;
101102 // Clear stored list
102103 m_static_objects.clearStored ();
103104 raiseModified (MOD_STATE_WRITE_NEEDED, MOD_REASON_TOO_MANY_OBJECTS);
@@ -111,7 +112,7 @@ bool MapBlock::saveStaticObject(u16 id, const StaticObject &obj, u32 reason)
111112{
112113 if (m_static_objects.getStoredSize () >= g_settings->getU16 (" max_objects_per_block" )) {
113114 warningstream << " MapBlock::saveStaticObject(): Trying to store id = " << id
114- << " statically but block " << PP ( getPos () ) << " already contains "
115+ << " statically but block " << getPos () << " already contains "
115116 << m_static_objects.getStoredSize () << " objects."
116117 << std::endl;
117118 return false ;
@@ -487,7 +488,7 @@ void MapBlock::deSerialize(std::istream &in_compressed, u8 version, bool disk)
487488 if (!ser_ver_supported (version))
488489 throw VersionMismatchException (" ERROR: MapBlock format not supported" );
489490
490- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )<<std::endl);
491+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()<<std::endl);
491492
492493 m_day_night_differs_expired = false ;
493494
@@ -515,18 +516,18 @@ void MapBlock::deSerialize(std::istream &in_compressed, u8 version, bool disk)
515516 NameIdMapping nimap;
516517 if (disk && version >= 29 ) {
517518 // Timestamp
518- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
519+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
519520 <<" : Timestamp" <<std::endl);
520521 setTimestampNoChangedFlag (readU32 (is));
521522 m_disk_timestamp = m_timestamp;
522523
523524 // Node/id mapping
524- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
525+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
525526 <<" : NameIdMapping" <<std::endl);
526527 nimap.deSerialize (is);
527528 }
528529
529- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
530+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
530531 <<" : Bulk node data" <<std::endl);
531532 u8 content_width = readU8 (is);
532533 u8 params_width = readU8 (is);
@@ -551,7 +552,7 @@ void MapBlock::deSerialize(std::istream &in_compressed, u8 version, bool disk)
551552 /*
552553 NodeMetadata
553554 */
554- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
555+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
555556 <<" : Node metadata" <<std::endl);
556557 if (version >= 29 ) {
557558 m_node_metadata.deSerialize (is, m_gamedef->idef ());
@@ -570,7 +571,7 @@ void MapBlock::deSerialize(std::istream &in_compressed, u8 version, bool disk)
570571 } catch (SerializationError &e) {
571572 warningstream<<" MapBlock::deSerialize(): Ignoring an error"
572573 <<" while deserializing node metadata at ("
573- <<PP ( getPos () )<<" : " <<e.what ()<<std::endl;
574+ <<getPos ()<<" : " <<e.what ()<<std::endl;
574575 }
575576 }
576577
@@ -584,25 +585,25 @@ void MapBlock::deSerialize(std::istream &in_compressed, u8 version, bool disk)
584585 readU8 (is);
585586 }
586587 if (version == 24 ) {
587- TRACESTREAM (<< " MapBlock::deSerialize " << PP ( getPos () )
588+ TRACESTREAM (<< " MapBlock::deSerialize " << getPos ()
588589 << " : Node timers (ver==24)" << std::endl);
589590 m_node_timers.deSerialize (is, version);
590591 }
591592
592593 // Static objects
593- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
594+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
594595 <<" : Static objects" <<std::endl);
595596 m_static_objects.deSerialize (is);
596597
597598 if (version < 29 ) {
598599 // Timestamp
599- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
600+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
600601 <<" : Timestamp" <<std::endl);
601602 setTimestampNoChangedFlag (readU32 (is));
602603 m_disk_timestamp = m_timestamp;
603604
604605 // Node/id mapping
605- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
606+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
606607 <<" : NameIdMapping" <<std::endl);
607608 nimap.deSerialize (is);
608609 }
@@ -611,13 +612,13 @@ void MapBlock::deSerialize(std::istream &in_compressed, u8 version, bool disk)
611612 correctBlockNodeIds (&nimap, data, m_gamedef);
612613
613614 if (version >= 25 ){
614- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
615+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
615616 <<" : Node timers (ver>=25)" <<std::endl);
616617 m_node_timers.deSerialize (is, version);
617618 }
618619 }
619620
620- TRACESTREAM (<<" MapBlock::deSerialize " <<PP ( getPos () )
621+ TRACESTREAM (<<" MapBlock::deSerialize " <<getPos ()
621622 <<" : Done." <<std::endl);
622623}
623624
0 commit comments