summaryrefslogtreecommitdiffstats
path: root/src/MobSpawner.cpp (unfollow)
Commit message (Collapse)AuthorFilesLines
2023-04-08Implement slime chunks. (#5484)Michal Havlíček1-1/+4
* Implement slime chunks. * add cWorld::IsSlimeChunk * add documentation for cWorld::IsSlimeChunk
2022-04-20Valid Height is now checked by vector.x12xx12x1-1/+1
2021-08-20Slime spawinig in swamps (#5281)JK2K1-2/+19
* test commit * hook test/ .gitignore * Slime add light limitation * Slime spawning moon light * Casting fix for clang * Removal of redundant changes Extracted moon phases amount to const
2021-01-11Convert most calls to blocking GetHeight/GetBiomeAt to direct chunk accessesTiger Wang1-7/+0
* Hopefully fixes #5094
2020-09-27Fixing Mob spawner behaviour (#4930)12xx121-102/+115
* fixed mob spawner failure (whoopsie in the BlockEntity.GetChunkZ()) Style * fixed spawning behaviour * fixed saving entity type saving * checkstyle * removed debug log * removed short saving * Style Co-authored-by: 12xx12 <12xx12100@gmail.com> Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
2020-04-04Implement wither skeletons (#4563)Mat1-1/+18
2020-04-03Pulled the BlockID and BlockInfo headers from Globals.h. (#4591)Mattes D1-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
2020-03-27Reduce ghast spawn rate againMat1-1/+1
2020-03-27Reduce ghast spawn rateMat1-1/+1
2020-03-26Improvements to blaze and ghast (#4547)Mat1-1/+9
2020-03-25Fix nether mob spawning (#4546)Mat1-80/+93
* Fix nether mob spawning * Remove zombie from nether mobs
2019-10-28Moved growing from cWorld / cChunk to cBlockHandler descendants.Mattes D1-77/+76
2018-08-02Experience orb (#4259)changyong guo1-2/+8
* Replace cWorld::FindClosesPlayer with cWorld::DoWithClosestPlayer * Implement experience reward splitting into the orb sizes used in vanilla * Modified speed calculation in cExpOrb::Tick to make the orbs fly towards the player Fixes #4216
2018-04-11Removed duplicate code (#4198)Bond-0091-63/+148
Should also fix dogs not despawning
2017-09-11Replace ItemCallbacks with lambdas (#3993)peterbell101-10/+1
2017-09-02Revert "Replace ItemCallbacks with lambdas (#3948)"LogicParrot1-1/+10
This reverts commit 496c337cdfa593654018c171f6a74c28272265b5.
2017-09-01Replace ItemCallbacks with lambdas (#3948)peterbell101-10/+1
2017-08-07Changed entity ownership model to use smart pointersTiger Wang1-6/+7
2017-07-21FastRandom: Remove discrepancy between arg and return value type. (#3846)Mattes D1-9/+5
2017-06-16Remove sign conversionpeterbell101-1/+2
2017-06-13FastRandom rewrite (#3754)peterbell101-10/+6
2016-03-01Mobs no longer spawn at the top of the nether.tonibm191-0/+5
I don't really know if this is the right place for the check, but it works. Add bedrock check fix typo Using code provided by NiLSpace and fixed a horse's bug -Horses can no longer be "controlled" if they're not tamed and saddled removed unrelated horse code Fixed mobs spawning above bedrock
2016-01-16Fixed non-natural spawning near player (egg, breeding, etc.)LogicParrot1-174/+184
2015-10-29Added cave spider to MobSpawnerLukas Pioch1-0/+11
2015-05-24Made -Weverything an error.tycho1-1/+1
2015-05-09CheckBasicStyle: checks spaces around * and &.Mattes D1-2/+2
2015-03-20Correct world height validations.Tommy Santerre1-1/+1
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-14Fixed grass spread, closes #1743Tiger Wang1-5/+4
- Removed the salt parameter in cFastRandom functions, it wasn't doing what we thought it was following the move to C++11
2015-02-20Fixed monster spawn randomness.Mattes D1-1/+2
Fixes #1699.
2014-12-20Added RabbitsMasy981-0/+2
2014-12-18Added Entity GuardianMasy981-0/+6
2014-12-05Fixed reported parentheses around comparisons.Mattes D1-4/+4
2014-12-02updated mooshroom check for myceliump-mcgowan1-1/+1
2014-12-02extra formatting parenthesesp-mcgowan1-2/+2
2014-12-02added spawning rule to mooshroomp-mcgowan1-0/+13
2014-10-23En masse NULL -> nullptr replaceTiger Wang1-1/+1
2014-10-20En masse NULL -> nullptr replaceTiger Wang1-1/+1
2014-09-19Implemented mob spawner.Howaner1-6/+7
2014-09-17Added first test to show the object can be createdTycho1-50/+50
2014-07-21Style: Normalized to no spaces before closing parenthesis.madmaxoft1-1/+1
2014-07-21Style: Normalized spaces after if, for and while.madmaxoft1-1/+1
2014-07-20Bug and crash fixesTiger Wang1-1/+2
* Fixes end portals' solidity * Fixed crashes to do with multithreading and removing an entity from the wrong world * Fixed crashes due to bad merge * Fixed crashes due to an object being deleted twice * Simplified cWorld::Start() and added comments to configuration files
2014-07-19Fixed style: spaces after commas.madmaxoft1-1/+1
2014-07-17Fixed basic whitespace problems.madmaxoft1-1/+1
Indenting by spaces and alignment by spaces, as well as trailing whitespace on non-empty lines.
2014-05-09Fixed MSVC 64-bit build warnings.Mattes D1-3/+3
2014-05-08Fixed MSVC 64-bit build warnings.Mattes D1-3/+3
2014-04-18Did some static analysis, fixed some bugs and optimized a lot of codejfhumann1-2/+2
2014-03-31Realised suggestionsTiger Wang1-5/+8
2014-03-31Fixed a few Y too high/low assertsTiger Wang1-5/+7
2014-03-16Add new leaves to all classes.Howaner1-1/+1
2014-03-01g_BlockXXX => cBlockInfo::XXXandrew1-7/+7
2014-02-09Fixed compile and some warnings in MSVSTiger Wang1-1/+1
2013-11-24Moved source to srcAlexander Harkness1-0/+0
2013-11-08MobSpawner: Added skeleton and wolf conditions.madmaxoft1-19/+91
This fixes the flood of warnings in the server console in Debug mode.
2013-11-04Autogeneration of settings.ini and webadmin.iniTiger Wang1-3/+3
Fixes issue #75
2013-10-29Changes based on madmaxoft's nitpicker notes.Samuel Barney1-14/+10
2013-10-29Update to allow the light map to remain the same, but allow alteration of sky light values based on time.Samuel Barney1-9/+16
2013-10-28Got spiders and other mobs respecting night and day for spawningSamuel Barney1-11/+19
2013-10-28Made mob spawning code use the chunk so that it could use varying sizes of areas for different mobs.Samuel Barney1-18/+56
2013-10-26Disabling Endermen and spiders until I rework the CanSpawnHere to take a chunk and a position.Samuel Barney1-1/+2
2013-10-25Checked Endermen; they work; adding them back in.Samuel Barney1-1/+0
2013-10-25Fixed mob spawning so that hostile mobs will not spawn incorrectly.Samuel Barney1-68/+38
2013-10-23Bats only spawn where there is no sunlight, and the light level is below 5Samuel Barney1-1/+1
2013-10-21Current Mob Spawning code.Samuel Barney1-13/+13
2013-10-20Fixed memory leaks in cMobSpawner.madmaxoft1-43/+33
2013-10-20Moved all MobTypesManager functions to cMonster.madmaxoft1-4/+2
This removes some of the memory leaks and is more logical in structure. Also the functions are exported to Lua.
2013-10-20Fixed loading allowed mobs in world.madmaxoft1-1/+8
2013-09-08renaming the cChunk::getRandomBlock method + removing a buggy working logmgueydan1-3/+0
2013-09-08Adding mobtype filter inside world.inimgueydan1-1/+2
2013-09-08Implementing the MobSpawner (not used yet) that contains spawning rulesmgueydan1-0/+277