Commit Graph
450 Commits
Author SHA1 Message Date
peterbell10andGitHub d3c1c626f5 Deal with covered switches consistently (#4161)
* Fixes a number of "<function>: not all control paths return a value" warnings on MSVC.

* Introduces the UNREACHABLE global macro and uses it instead of conditionally compiled switch defaults.

* Move cNBTParseErrorCategory from FastNBT.h into FastNBT.cpp to prevent bad calls to message()
2018-02-04 23:07:12 +00:00
Bond-009andAlexander Harkness d11335e4f6 Add world name in logs from cWorld (#4148) 2018-01-16 22:04:39 +00:00
Alexander HarknessandGitHub 6309c6a97f improve rain simulation (#4017)
* Uses vanilla logic to decide which blocks rain falls through.
 * Rain falls infinitely above the world, and stops at y=0.
 * Entities will now be extinguished if they are under rain-blocking
blocks, and fire will now be extinguished by rain similarly.
 * Create IsWeatherWetAtXYZ to identify wetness at a particular location. 
 * Use new code for enderman rain detection.
 * Fixes issue #916
 * Disable warnings for global constructors in the fire simulator.
2017-12-26 21:25:57 +00:00
peterbell10andMattes D c54bf40ef9 cWorld Threads: Seperate initialization and thread start.
Prevents nullptr dereferences before Start has been called.
2017-10-21 19:33:22 +02:00
peterbell10andMattes D 1537ebed6f cWorld: Move Initialization from Start to the constructor.
Start now does nothing more than launch the world's threads.
2017-10-21 19:33:22 +02:00
Bond-009andMattes D 10c5c1227e BroadcastBlockBreakAnimation and BroadcastBlockEntity use vectors (#4038) 2017-09-25 18:17:45 +02:00
Lane Kolblyandpeterbell10 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
Lukas PiochandMattes D c5f590d460 Removed UTF-8 BOM (#4033) 2017-09-19 10:34:08 +02:00
peterbell10andMattes D e225b7f826 Replace ItemCallbacks with lambdas (#3993) 2017-09-11 23:20:49 +02:00
Lane KolblyandAlexander Harkness b12f4ef7d5 Made world data paths adjustable, and added API to temporarily disable saving chunks to disk. (#3912) 2017-09-07 13:41:16 +01:00
Bond-009andMattes D 104f9e127b Changed some int parameters to vector parameters (#3937) 2017-09-07 10:25:34 +02:00
peterbell10andAlexander Harkness ef1f371dab Add cWorld::RemoveEntity and use in cEntity (#4003)
* Add cWorld::RemoveEntity and use in cEntity

* cEntity: Remove uneeded asserts from Destroy and DoMoveToWorld
2017-09-05 15:11:35 +01:00
LogicParrotandAlexander Harkness 49c443896d Revert "Replace ItemCallbacks with lambdas (#3948)"
This reverts commit 496c337cdf.
2017-09-02 08:50:23 +01:00
peterbell10andMattes D 496c337cdf Replace ItemCallbacks with lambdas (#3948) 2017-09-01 13:04:50 +02:00
peterbell10andLukas Pioch 1779db1201 cWorld: Add entities without holding of m_CSEntitiesToAdd
* Fixes deadlock when cWorld::AddEntity is called while holding chunk map CS.
2017-08-29 15:46:36 +02:00
peterbell10andAlexander Harkness f4f2fc7c3d Add cUUID class (#3871) 2017-08-25 13:43:18 +01:00
Pablo BeltránandMattes D b18f6637b6 Fully implemented leashes (#3798) 2017-08-21 10:46:41 +02:00
Tiger WangandGitHub 72d7027861 Merge pull request #3489 from cuberite/EntityOwnership
* Changed entity ownership model to use smart pointers
2017-08-18 11:17:56 +01:00
Lane KolblyandMattes D 7bdbfad1bb Changed int parameters to vector parameters in cCuboid and simulators (#3874) 2017-08-17 15:48:38 +02:00
Tiger Wang 4ef47aed62 Changed entity ownership model to use smart pointers 2017-08-07 19:24:16 +01:00
peterbell10andLukas Pioch 759618b035 Remove double includes part 2 (#3890) 2017-08-03 15:34:19 +02:00
Lukas PiochandTiger Wang 4691bc5a29 Removed double includes (#3885) 2017-08-02 19:57:20 +01:00
peterbell10andLukas Pioch 8eb5672920 cWorld::SendBlockTo take player by ref 2017-08-01 08:21:20 +02:00
peterbell10andTiger Wang a56cfd1f42 Remove smart pointer macros 2017-07-21 14:41:51 +01:00
Mattes DandLukas Pioch 167c4bf2e6 Simulators: Added area-based wakeup. 2017-07-16 10:01:19 +02:00
Lane KolblyandLukas Pioch 793acd267f Changing pickup lifetime and combining semantics, making these adjustable in the lua api. (#3843) 2017-07-12 12:13:27 +02:00
Lukas PiochandGitHub 885d828712 Added bed entity (#3823)
* Added bed entity

* Export cBedEntity to lua
* Set color of bed through item damage value
* Added bed entity to APIDoc
* NBT: Added loading and saving
* Crafting recipes for the colored beds
2017-07-07 09:31:45 +02:00
Bond-009andLukas Pioch 3d56ad01aa Let water vaporise in the Nether by default 2017-06-20 09:28:00 +02:00
peterbell10andLukas Pioch f4de38af80 Remove sign conversion 2017-06-16 07:07:02 +02:00
peterbell10andLukas Pioch 360d8eade0 FastRandom rewrite (#3754) 2017-06-13 21:35:30 +02:00
Lukas Pioch 73a3c4e3be Exported boat
- NBT: Added saving / loading of material
- Added the material in the item handler of the boat
- Drop the correct boat if destroyed
- APIDoc: Added desc and functions
2017-05-24 19:02:18 +02:00
Pablo BeltránandMattes D 2359611c57 Don't destroy monster when last target type is a player (#3721)
In current Cuberite version if you are pursued by monsters you just have to disconnect and connect again to get rid of them. If no other player is in your chunk monsters will get destroyed.
2017-05-21 10:29:06 +02:00
Mattes Dandworktycho 2c3c1f1527 Tracer replacement (#3704)
* Replaced cTracer usage with cLineBlockTracer.

* Exported new cLineBlockTracer utility functions to Lua API.
2017-05-11 13:34:36 +01:00
Lukas Pioch 5580d558a5 Added missing checks for Initialize function and updated APIDoc 2017-05-08 06:31:45 +02:00
Bond-009andMattes D ca3aa4ca06 Changed world_end to world_the_end #3531 (#3538) 2017-02-24 10:02:16 +01:00
mathiascodeandMattes D dae2adde65 Updated sounds and effect IDs (#3422) 2017-02-15 06:05:24 +01:00
mathiascodeandMattes D 4311f4a658 Added some blocks and items (#3503) 2017-02-14 11:13:55 +01:00
Lawton MizellandMattes D 043aa4e574 Made survival the default gamemode (#3563) 2017-02-07 16:00:30 +01:00
Mattes DandGitHub 97980d1103 World: Remember the age persistently. (#3556) 2017-01-19 22:45:23 +01:00
Mattes DandGitHub dfa8f278ea World: Removed LineBlockTracer test code. (#3555)
The test for LineBlockTracer is already in the Debuggers plugin (/spidey and testtracer commands).
2017-01-19 21:06:42 +01:00
Mattes D a4955dfda3 Removed asserts about chunk queued.
The assumption is not needed and was invalid under a stress-test.
2017-01-19 16:25:07 +01:00
Mattes D 7cc3fb098d DeadlockDetect now lists some tracked CS's stats. 2017-01-18 09:03:05 +01:00
Fabian SteinandMattes D 90fcf9814f World: Add check for unknown RedstoneSimulator (#3496) 2016-12-29 00:41:20 +01:00
Mattes D 0e3b3be766 Initial support for the 1.11 protocol. 2016-12-16 00:07:22 +01:00
Tiger WangandAlexander Harkness 8c6d0b51c7 Use CMake's Android generators to crosscompile 2016-12-12 14:32:32 +00:00
Mattes D 0bffa29358 Removed ClientHandle.h dependencies from common headers. 2016-11-18 20:00:04 +01:00
bibo38andMattes D cb640ffea4 Spectators added (#2852) 2016-10-12 14:38:45 +02:00
LogicParrotandGitHub 7e9e7f7911 Configurable dirty unused chunk cap to avoid RAM overuse (#3359)
Configurable dirty unused chunk cap to avoid RAM overuse
2016-09-03 18:38:29 +03:00
ElNounchandMattes D e9d1a942d1 Delay EntityChangedWorld players' callback until Entity fully linked to world (#3330)
Otherwise, some API calls just don't seem to happen
.gitignore tweak for test executables
2016-08-22 19:43:43 +02:00
ElNounchandMattes D 343531bafa Added cWorld:SetSpawn() API and Lua binding (#3316) 2016-08-15 10:41:32 +02:00