summaryrefslogtreecommitdiffstats
path: root/src/NetherPortalScanner.cpp (unfollow)
Commit message (Collapse)AuthorFilesLines
2020-04-19Correct world access in NetherPortalScannerTiger Wang1-6/+16
2020-04-18MoveToWorld must always be provided a worldTiger Wang1-21/+21
2020-04-18Only store IDs across ticksTiger Wang1-4/+15
2020-04-03Pulled the BlockID and BlockInfo headers from Globals.h. (#4591)Mattes D1-0/+1
The BlockID.h file was removed from Globals.h and renamed to BlockType.h (main change) The BlockInfo.h file was removed from Globals.h (main change) The ENUM_BLOCK_ID and ENUM_ITEM_ID enum names were replaced with ENUM_BLOCK_TYPE and ENUM_ITEM_TYPE (cosmetics) The various enums, such as eDimension, eDamageType and eExplosionSource were moved from BlockType.h to Defines.h, together with the helper functions for converting between them and strings (StringToDimension et al.) (minor) Many inline functions were moved from headers to their respective cpp files, so that BlockType.h could be included only into the cpp file, rather than the header. That broke our tests a bit, since they pick bits and pieces out of the main code and provide stubs for the rest; they had to be re-stubbed and re-verified. eMonsterType values are no longer tied to E_ITEM_SPAWN_EGG_META_* values
2020-03-24Send respawn packet by default (#4540)Mat1-1/+1
2020-03-05Stabilise MoveToWorld (#4004)Mat1-1/+1
* Stabilise MoveToWorld * Fix comments and deprecate ScheduleMoveToWorld * Enhanced thread safety for m_WorldChangeInfo * Return unique_ptr from cAtomicUniquePtr::exchange * cWorld now calls entity cEntity::OnAddToWorld and cEntity::OnRemoveFromWorld. Allows broadcasting entities added to the world from the world's tick thread. This also factors out some common code from cEntity::DoMoveToWorld and cEntity::Initialize. As a consequence, cEntity::Destroy(false) (i.e. Destroying the entity without broadcasting) is impossible. This isn't used anywhere in Cuberite so it's now deprecated. * Update entity position after removing it from the world. Fixes broadcasts being sent to the wrong chunk. * Fix style * cEntity: Update LastSentPosition when sending spawn packet * Add Wno-deprecated-declarations to the lua bindings * Kill uses of ScheduleMoveToWorld
2019-04-18Make Nether portals spawn the player inside of them (#4325)DaPorkchop_1-2/+2
Currently the player is spawned immediately in front of them. Simply changing `cNetherPortalScanner::OutOffset` to 0.5 wasn't enough, as the player would always be spawned on top of the portal, however checking for non-solid blocks instead of air fixes this.
2018-09-24Add a formatting function for Vector3 (#4282)peterbell101-2/+2
* Vector3: Add custom fmt compatible formatter. * cLuaState: Add fmt version of ApiParamError * Use vector formatting in manual bindings * Always log vectors with FLOG
2018-07-26CheckBasicStyle: Check number of empty lines between functions (#4267)peterbell101-1/+0
Add check for number of empty lines between functions and fix the corresponding failures
2018-05-06Use clang-tidy to check more code conventions (#4214)Bond-0091-0/+8
* Create clang-tidy.sh * Add clang-tidy to circle.yml * Fixed some naming violations Fixes #4164
2017-08-02Removed double includes (#3885)Lukas Pioch1-1/+0
2015-06-13Work on NetherPortalScanner. Setup portal scanner to reset PortalCooldown. Changed where player is spawned. Added a_InitSpawn flag to CreateAndInitializeWorld.Lane Kolbly1-1/+7
2015-06-13NetherPortalScanner: Fixed type conversion warnings.Mattes D1-2/+2
2015-06-10Implemented nether portal scanning code.Lane Kolbly1-0/+290