1
0
Fork 0
Commit Graph

37 Commits

Author SHA1 Message Date
Tiger Wang 225c2fa9f6 Always use relative coordinates in AddBlock
+ Pass block, use relatives
* Fixes everything immediately converting abs back to rel and getting block, when these data were already available
2020-08-02 15:52:06 +01:00
Mattes D 9ee47e5999 Using Super. 2020-04-16 20:07:48 +00:00
Mattes D 01b8ed5295
Pulled the BlockID and BlockInfo headers from Globals.h. (#4591)
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-04-03 08:57:01 +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 4727ed2084 Add a formatting function for Vector3 (#4282)
* Vector3: Add custom fmt compatible formatter.

* cLuaState: Add fmt version of ApiParamError

* Use vector formatting in manual bindings

* Always log vectors with FLOG
2018-09-24 21:33:39 +01:00
peterbell10 950aeffff8
CheckBasicStyle: Check number of empty lines between functions (#4267)
Add check for number of empty lines between functions and fix the corresponding failures
2018-07-26 22:24:36 +01:00
peterbell10 c94d7184eb Broadcast refactor (#4264)
* Move Broadcast functions from cChunkMap to cBroadcaster

- Remove cBroadcastInterface in favour of cBroadcaster.

- cChunk: Remove broadcast functions.

* resurect broadcast interface

* Absorb cBroadcaster into cWorld.
Removes the need for forwarding the function calls.

* Improve const-correctness

* Use Int8 instead of char

+ Comment `ForClients` functions

* Improve comments

* Broadcaster: Rename ForClients functions
2018-07-24 22:30:49 +01:00
peterbell10 757231cc6e
Add the fmt library (#4065)
* Replaces AppendVPrintf with fmt::sprintf
* fmt::ArgList now used as a type safe alternative to varargs.
* Removed SIZE_T_FMT compatibility macros. fmt::sprintf is fully portable and supports %zu.
* Adds FLOG functions to log with fmt's native formatting style.
2018-01-03 17:41:16 +00:00
Lane Kolbly 30c8470a52 Changed BroadcastSoundEffect, SendSoundEffect, and CastThunderbolt parameters to vectors (#3959)
* Made BroadcastSoundEffect take vector parameters.

* Added docs for new vectored methods

* Removed old code

* Fixed lua warnings

* Made old BroadcastSoundEffect not an override.

* m_Block to m_BlockPos, used Vector3d constructor where prettier.

* a_Block to a_BlockPos

* Changed thunderbolt a_Block to a_BlockPos
2017-09-19 15:12:54 +01:00
Lane Kolbly 7bdbfad1bb Changed int parameters to vector parameters in cCuboid and simulators (#3874) 2017-08-17 15:48:38 +02:00
mathiascode dae2adde65 Updated sounds and effect IDs (#3422) 2017-02-15 06:05:24 +01:00
LogicParrot ca6ef58b1e Bulk clearing of whitespace 2016-02-05 23:50:18 +02:00
Mathias 89f3dec7ac Updated old forum links 2016-01-31 02:25:03 +02:00
Lukas Pioch d620dcdd08 Moved variables into scope, removed unused variables and fixed variables 2015-12-17 10:48:36 +01:00
bibo38 3c9e113985 Now Water sources will also be created on top of existing water sources.
See also on http://minecraft.gamepedia.com/Water#Source_blocks
Fixes #2097
2015-07-15 23:36:51 +02:00
tycho b2fa71a32a Fix comments 2015-05-28 12:54:04 +01:00
tycho dae9e5792a Made -Weverything an error. 2015-05-24 12:56:56 +01:00
bibo38 54d97f8c17 Removed wrong else clause, which caused that the following if-Statement got only executed in rare cases. This has blocked the creation of new Fluid-Sources. Bugfix #1783 2015-03-19 13:23:03 +01:00
Mattes D 3da6e4374e Fixed basic style. 2014-12-25 00:44:09 +01:00
Ivan Đorđević 99055f644b Removed unneeded newlines 2014-12-17 11:25:59 +01:00
gushromp c2d32ce31b Merge branch 'master' of https://github.com/gushromp/MCServer
Conflicts:
	src/Simulator/FloodyFluidSimulator.cpp
2014-12-16 22:58:23 +01:00
gushromp fd325e3990 Fixed water from spreading on bottom of world 2014-12-16 22:54:39 +01:00
gushromp 6cf3aa70f1 Fixed water from spreading on bottom of world 2014-12-16 22:38:57 +01:00
Tiger Wang a26541a7c3 En masse NULL -> nullptr replace 2014-10-22 20:12:49 -07:00
Tycho a3f940f47c Removed more unessicary includes 2014-09-26 18:13:19 +01:00
madmaxoft 5e198c6730 Basic style fixes. 2014-07-17 22:50:58 +02:00
Howaner d529971e27 Changed BroadcastSoundEffect function to take floating pos. 2014-07-13 02:08:02 +02:00
Tiger Wang 69befa9851 Fixed bad water/redstone simulator communication
* Fixes #713
2014-06-27 23:16:37 +01:00
madmaxoft 58224863c0 Fixed vanilla fluid simulator.
Fixes #919.
2014-05-02 22:07:30 +02:00
andrew d86fc1af06 Added some comments 2014-03-07 20:49:40 +02:00
andrew 8808523942 Fixed water/lava interaction 2014-03-07 15:42:03 +02:00
andrew 1ea17c0a75 Implemented vanilla-like fluid simulator 2014-03-05 15:54:38 +02:00
Tycho b82fc394dd Changed Signiture of OnUpdate 2014-02-02 06:49:37 -08:00
madmaxoft 8610d45ef1 Fixed compiler warning when iterating over a fixed array of items (ARRAYCOUNT). 2013-12-20 16:01:34 +01:00
Tiger Wang 0905369fc7 Fixed Floody lava to stone fizzle 2013-12-10 00:29:59 +00:00
Alexander Harkness 675b4aa878 Moved source to src 2013-11-24 14:19:41 +00:00