1
0
Commit Graph

26 Commits

Author SHA1 Message Date
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
a4dbb5c582
Prefer static_cast to reinterpret_cast (#4223)
* Change reinterpret_cast -> static_cast wherever possible
* Remove more unnecessary `const_cast`s.

reinterpret_casts should be avoided for the same reason as c-style casts - they don't do any type-checking. reinterpret_cast was mainly being used for down-casting in inheritance hierarchies but static_cast works just as well while also making sure that there is actually an inheritance relationship there.
2018-05-02 08:50:36 +01:00
Bond-009
76a0971279 Fixed 2 small warnings (#4055) 2017-10-02 20:59:25 +01:00
Bond-009
10c5c1227e BroadcastBlockBreakAnimation and BroadcastBlockEntity use vectors (#4038) 2017-09-25 18:17:45 +02:00
Lukas Pioch
c5f590d460 Removed UTF-8 BOM (#4033) 2017-09-19 10:34:08 +02:00
peterbell10
e225b7f826 Replace ItemCallbacks with lambdas (#3993) 2017-09-11 23:20:49 +02:00
LogicParrot
49c443896d Revert "Replace ItemCallbacks with lambdas (#3948)"
This reverts commit 496c337cdf.
2017-09-02 08:50:23 +01:00
peterbell10
496c337cdf Replace ItemCallbacks with lambdas (#3948) 2017-09-01 13:04:50 +02:00
Tiger Wang
4ef47aed62 Changed entity ownership model to use smart pointers 2017-08-07 19:24:16 +01:00
Mattes D
0dd1cd750b BlockEntities: Support cloning self. 2017-06-16 14:11:28 +02:00
peterbell10
360d8eade0 FastRandom rewrite (#3754) 2017-06-13 21:35:30 +02:00
Mattes D
0bffa29358 Removed ClientHandle.h dependencies from common headers. 2016-11-18 20:00:04 +01:00
Gargaj
f9008a4860 allow use failures to propagate from the entity/block to the player 2015-12-13 13:27:38 +01:00
Dave Tucker
83870f9fc0 Add enum for Sound and Particle Effects
Fixes #2603

Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
2015-11-24 13:21:40 +00: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
tycho
77f1f58c0a Make -Werror disabling file only
Ad fix a load of warnings
2015-05-19 19:32:10 +01:00
Mattes D
cc069ccb2a Changed cEntity::m_UniqueID to UInt32. 2015-03-21 15:18:17 +01:00
Tycho
2a9664d6ca Initial convertion of a_Dt to std::chrono
also refactored cWorld::m_WorldAge and cWorld::m_TimeOfDay
2015-01-11 21:12:26 +00:00
Tiger Wang
8d9049603b NULL -> nullptr 2014-12-16 23:18:59 +00:00
Howaner
bcbd73f7d8 MobSpawner fixes. 2014-12-01 14:58:13 +01:00
Howaner
2478e290f9 Many api fixes, add vanilla names to mob type -> string functions and mob spawner fixes. 2014-11-29 15:20:44 +01:00
Howaner
8b028c5c78 Finished mob spawner implementation. 2014-11-18 15:33:41 +01:00
Howaner
5e71d5299c Fixed compile errors. 2014-09-27 00:07:17 +02:00
Howaner
718eb227ab Implemented mob spawner. 2014-09-19 23:00:54 +02:00
Howaner
3d94a7ea56 Created MobSpawnerEntity class. 2014-09-17 17:45:13 +02:00