summaryrefslogtreecommitdiffstats
path: root/src/Blocks/ChunkInterface.cpp (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Merged OnBreak with OnPlayerBreak (#4967)12xx122020-10-081-2/+2
| | | | Co-authored-by: 12xx12 <12xx12100@gmail.com> Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
* BlockHandler initialisation is a constant expression (#4891)Tiger Wang2020-09-201-2/+1
| | | | | | | | | | | | | * BlockHandler initialisation is a constant expression If we can't make it all namespaces, this is the next best I guess. + Tag handlers constexpr, const as needed + Inherit constructors * Privatise handler functions * More constexpr Co-authored-by: Alexander Harkness <me@bearbin.net>
* Remove unneeded MarkDirty, SendToClients parameters of SetMetaTiger Wang2020-08-281-2/+2
| | | | | | | | Partially reverts #3129, whose addition of these parameters was superseded by #3149 that fixed generated leaves' metas. References: https://github.com/cuberite/cuberite/pull/4417#discussion_r334950513 e0bcd754009f16480437b2c1fa5e7fbedab31496
* OnBroken/OnPlaced are for entity actionsTiger Wang2020-08-041-6/+15
| | | | | | * Call OnPlaced/OnBroken in PlaceBlock/DigBlock - Remove unused Placing/Breaking handlers * Have the blockhandler's Check handle neighbour updating, instead of QueueTickBlockNeighbors
* Pulled the BlockID and BlockInfo headers from Globals.h. (#4591)Mattes D2020-04-031-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
* Moved growing from cWorld / cChunk to cBlockHandler descendants.Mattes D2019-10-281-18/+6
|
* Refactored block-to-pickup conversion. (#4417)Mattes D2019-10-161-10/+24
|
* Force all headers other than "Globals.h" to be included with relative paths (#4269)peterbell102018-08-291-1/+1
| | | | | | | Closes #4236 CMake now creates a header file in the build directory under the path "include/Globals.h" which just includes "src/Globals.h" with an absolute path. Then instead of adding "src/" to the include directories, it adds "include/". #include "Globals.h" still works by including the build generated file and any other src-relative path will not work.
* CheckBasicStyle: Check number of empty lines between functions (#4267)peterbell102018-07-261-7/+0
| | | | Add check for number of empty lines between functions and fix the corresponding failures
* cChunkInterface GetBlock, GetBlockMeta, GetBlockTypeMeta use vectors (#4050)Bond-0092017-11-201-17/+7
|
* Updated cChunk::SetMeta, fixed grass growth, reduced markDirty/setMeta usageLogicParrot2016-04-161-5/+2
|
* Reorganised the redstone simulatorTiger Wang2015-12-181-10/+0
| | | | | | -> Many thanks to @worktycho for the idea, and @Haxi52 for the implementation plan! * Uses classes and inheritance now * Speed should be improved
* allow use failures to propagate from the entity/block to the playerGargaj2015-12-131-2/+2
|
* Fixed minor style issues.madmaxoft2014-09-271-1/+1
|
* Removed more unessicary includesTycho2014-09-261-0/+1
|
* Fixed styleTycho2014-09-251-0/+66
|
* Merge branch 'master' into redstoneTestsTycho2014-09-171-2/+2
|\ | | | | | | | | Conflicts: src/Blocks/ChunkInterface.h
* | Added first test to show the object can be createdTycho2014-09-171-0/+66
|/
* cBlockInfo now manages the respective cBlockHandlerandrew2014-03-021-1/+1
|
* Added missing filesTycho2014-02-021-0/+12