Tiger Wang
c53a0ba5f6
Unify block entity pickup conversion
...
- Removed normal BlockHandler knowledge of block entities during conversion
+ Added cBlockEntity::ConvertToPickups that handles it
2020-09-25 09:07:01 +00:00
Tiger Wang
68cced73af
BlockHandler initialisation is a constant expression ( #4891 )
...
* 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>
2020-09-20 13:50:52 +00:00
Mattes D
9ee47e5999
Using Super.
2020-04-16 20:07:48 +00:00
Mat
0718c44e77
Silk touch pickaxe drops grass block ( #4485 )
2020-03-17 02:23:50 +02:00
Mattes D
61904af626
Moved growing from cWorld / cChunk to cBlockHandler descendants.
2019-10-28 10:45:43 +01:00
Mattes D
221cc4ec5c
Refactored block-to-pickup conversion. ( #4417 )
2019-10-16 10:06:34 +02:00
peterbell10
ee84197014
Force all headers other than "Globals.h" to be included with relative paths ( #4269 )
...
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.
2018-08-29 01:51:25 +01:00
peterbell10
759618b035
Remove double includes part 2 ( #3890 )
2017-08-03 15:34:19 +02:00
peterbell10
360d8eade0
FastRandom rewrite ( #3754 )
2017-06-13 21:35:30 +02:00
LogicParrot
c921f47d85
Prevented snow from killing grass
2016-04-16 21:54:35 +03:00
LogicParrot
373d9f92a4
Updated cChunk::SetMeta, fixed grass growth, reduced markDirty/setMeta usage
2016-04-16 19:04:45 +03:00
LogicParrot
ca6ef58b1e
Bulk clearing of whitespace
2016-02-05 23:50:18 +02:00
Julian Laubstein
b87e0b6b15
Adjusted height validation using cChunkDef::IsValidHeight()
2015-11-23 03:17:32 +01:00
Tiger Wang
8656e149c8
Improved maps
2015-07-14 21:46:30 +01:00
Samuel Barney
ba0577bbd0
Moved grabbing the light value to after the transparency check.
2015-07-03 13:05:02 -06:00
Samuel Barney
0307b6aba0
Added missing parens
2015-07-02 16:19:23 -06:00
Samuel Barney
e248539d74
Grass now only dies if it has an opaque block above it.
...
Grass only spreads to a dirt block if the light level is above 4 and the block above it is transparent.
2015-07-02 16:16:05 -06:00
Samuel Barney
e70e2b8ecc
Rebased version of Code
2015-06-22 11:29:38 -06:00
Tommy Santerre
3f6d823aa4
Correct world height validations.
...
Unify the way we test block above the current one (Height - 1 instead of a_RelY + 1).
Allow generation of world of flat height = 255
2015-03-19 20:32:17 -04:00
Tiger Wang
e94886c140
Fixed grass spread, closes #1743
...
- Removed the salt parameter in cFastRandom functions, it wasn't doing
what we thought it was following the move to C++11
2015-03-14 00:59:53 +00:00
Alexander Harkness
7348bf3853
Grass checks for sufficient light before spreading
2015-03-05 19:30:00 +00:00
Tiger Wang
a26541a7c3
En masse NULL -> nullptr replace
2014-10-22 20:12:49 -07:00
Mattes D
eeb580a74e
Functions in cPluginManager get references instead of pointers.
2014-10-15 19:09:09 +02:00
Howaner
7d3016c7ad
Code improvements
2014-09-30 20:59:59 +02:00
Howaner
425df6b694
Fixed 1.8 dirt types
2014-09-30 20:31:27 +02:00
Tycho
a3f940f47c
Removed more unessicary includes
2014-09-26 18:13:19 +01:00
Masy98
acae3c9c65
Moved sound-configs into BlockID.h and fixed/ added loads of sounds
2014-09-09 16:00:26 +02:00
Howaner
b5ffe06f88
Code formatting fixes.
2014-08-19 22:14:37 +02:00
Howaner
bc4a51781e
Add lava and water check to block handlers.
2014-05-07 20:37:36 +02:00
Howaner
36a2aa2f21
Rename CanChangeDirtToGrass to CanDirtGrowGrass
2014-05-07 12:59:48 +02:00
Howaner
4d7b250a50
Remove old import
2014-04-06 21:45:55 +02:00
Howaner
039191499c
Add CanChangeDirtToGrass function to Block Handlers.
2014-04-06 21:41:01 +02:00
Howaner
32d054e8fd
Merge branch 'master' into Slabs
...
Conflicts:
src/Blocks/BlockDirt.h
2014-04-03 22:03:18 +02:00
Howaner
cbb0352e51
Remove old function
2014-04-03 21:44:23 +02:00
Howaner
ca08a44c98
Grass now grows under up-side-down slabs
2014-04-03 21:43:40 +02:00
madmaxoft
8288e53c0b
Fixed a few Clang warnings in BlockHandlers.
2014-03-30 23:13:13 +02:00
Howaner
9c46112486
Change SpreadSource prefix to ss
2014-03-27 23:20:28 +01:00
Howaner
3774b1be64
Add SpreadSource
2014-03-27 23:20:28 +01:00
andrew
d73cdba1f6
g_BlockXXX => cBlockInfo::XXX
2014-03-01 21:34:19 +02:00
Tycho
b82fc394dd
Changed Signiture of OnUpdate
2014-02-02 06:49:37 -08:00
Tycho
6e6409b1a0
Removed cWorld Include
2014-01-26 07:10:29 -08:00
Tiger Wang
c08910d4af
Fixed assertion during dirt block OnUpdate()
2013-12-19 23:06:26 +00:00
madmaxoft
c70c2fa42f
Changed cBlockHandler->OnUpdate() to use cChunk directly.
2013-11-30 15:58:27 +01:00
madmaxoft
463de118a0
Grass doesn't spread to podzol or grassless dirt blocks.
2013-11-30 13:48:22 +01:00
Alexander Harkness
675b4aa878
Moved source to src
2013-11-24 14:19:41 +00:00