summaryrefslogtreecommitdiffstats
path: root/src/BlockEntities/DropSpenserEntity.cpp (unfollow)
Commit message (Collapse)AuthorFilesLines
2022-07-19Pickups: improve coalescing implementationPickupsTiger Wang1-23/+18
+ Add ability to coalesce before spawning in to world. * Adapt coalescing for pickup entities already in the world to be more like Vanilla.
2021-05-03Add player statistics to API (#5193)nshah251-2/+2
* Fixed issue #5166 Co-authored-by: 12xx12 <44411062+12xx12@users.noreply.github.com> Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
2021-01-02Fix potential destruction crashes (#5095)Tiger Wang1-14/+14
* Fix potential destruction crashes * Fix destructors accessing destroyted objects * Fix cPlayer not destroying windows (Destroyed never called) * Tentatively fixes #4608, fixes #3236, fixes #3262 - Remove cEntity::Destroyed() and replace with cEntity::OnRemoveFromWorld() * Add missing call to OnRemoveFromWorld
2020-09-23Limit fortune level, style fixesTiger Wang1-3/+2
2020-09-21Implement Dropspenser Hook (#4903)KrystilizeNevaDies1-1/+10
* Implement Dropspenser Hook Implemented a hook for dropspensing. HOOK_DROPSPENSE When plugin callback returns true then dropspense is cancelled * Update src/Bindings/PluginManager.h Co-authored-by: peterbell10 <peterbell10@live.co.uk> * Create OnDropSpense.lua * Fix indent * Forgot include Forgot to include the plugin manager. Although now im confused why it was working on my end without including the plugin manager * Update plugins.lua with dropspense * fix typos * haha notepad++ go brr Co-authored-by: peterbell10 <peterbell10@live.co.uk>
2020-09-05Add more statistic tracking (#4837)12xx121-0/+9
+ Added possible 1.8 stats + Added stat tracking for 1.8.2 + Added stat tracking for 1.9 + Added the breed cow achievement Co-authored-by: 12xx12 <12xx12100@gmail.com>
2020-05-15Enable some more clang-tidy linter checks (#4738)peterbell101-1/+0
* Avoid inefficient AString -> c_str() -> AString round trip * Avoid redundant string init expressions * Avoid unnecessary return, continue, etc. * Add .clang-format to help with clang-tidy fix-its * Avoid unnecessary passing by value * Avoid unnecessary local copying * Avoid copying in range-for loops * Avoid over-complicated boolean expressions * Some violations missed by my local clang-tidy * Allow unnecessary continue statements * Add brackets * Another expression missed locally * Move BindingsProcessor call into clang-tidy.sh and add space * Fix pushd not found error * Different grouping of CheckBlockInteractionRate
2020-04-16Using Super.Mattes D1-2/+2
2019-09-29Refactored more of Entities and BlockEntities to use Vector3. (#4403)Mattes D1-22/+20
2018-07-27cWorld: Manually bind deprecated broadcast functions (#4265)peterbell101-1/+1
Ref: https://github.com/cuberite/cuberite/pull/4264#discussion_r204769193
2018-05-02Prefer static_cast to reinterpret_cast (#4223)peterbell101-1/+1
* 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.
2017-09-19Changed BroadcastSoundEffect, SendSoundEffect, and CastThunderbolt parameters to vectors (#3959)Lane Kolbly1-2/+2
* 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-06-16BlockEntities: Support cloning self.Mattes D1-2/+14
2017-06-13FastRandom rewrite (#3754)peterbell101-1/+1
2017-06-05Fixes problems with windows:Lukas Pioch1-1/+1
- Changed cPlayer:OpenWindow to accept a ref, tolua adds a nil check - Close open lua window in destructor, to avoid dangling pointers
2017-02-15Updated sounds and effect IDs (#3422)mathiascode1-2/+2
2016-06-15- Add a activation flag to droppers and dispensers. Previously droppers and dispensers shot items with every block update.QUSpilPrgm1-3/+3
- Fixes a range check inside cIncrementalRedstoneSimulator::Simulate
2016-02-05Bulk clearing of whitespaceLogicParrot1-6/+6
2015-12-18Reorganised the redstone simulatorTiger Wang1-15/+1
-> Many thanks to @worktycho for the idea, and @Haxi52 for the implementation plan! * Uses classes and inheritance now * Speed should be improved
2015-12-13allow use failures to propagate from the entity/block to the playerGargaj1-1/+2
2015-11-24Add enum for Sound and Particle EffectsDave Tucker1-7/+8
Fixes #2603 Signed-off-by: Dave Tucker <dave@dtucker.co.uk>
2015-07-12Fixed DropSpenser sound #2333mmdk951-2/+2
2015-01-11Initial convertion of a_Dt to std::chronoTycho1-1/+1
also refactored cWorld::m_WorldAge and cWorld::m_TimeOfDay
2014-12-13Own classes for all windows.Howaner1-0/+1
2014-10-23En masse NULL -> nullptr replaceTiger Wang1-9/+13
2014-10-20En masse NULL -> nullptr replaceTiger Wang1-3/+3
2014-10-12convert old style casts to fix warningsSteven Riehl1-11/+7
2014-09-30Removed WSSCompactTiger Wang1-48/+0
2014-09-26Removed more unessicary includesTycho1-1/+0
2014-09-13Implemented Chest MinecartsTiger Wang1-1/+0
2014-07-17Basic style fixes.madmaxoft1-1/+1
2014-07-17Normalized comments.madmaxoft1-4/+4
This was mostly done automatically and then visually inspected for obvious errors. All //-style comments should have a 2-space separation from the code, and 1 space after the comment sign.
2014-07-15Fixed a DropSpenser AddFace bugTiger Wang1-1/+1
2014-02-24BlockEntities is warnings freeTycho1-0/+1
2014-02-12Removed some unneeded BroadcastWholeWindow()sTiger Wang1-7/+0
2013-11-28Moved json includes to where they are really needed.madmaxoft1-0/+1
2013-11-24Moved source to srcAlexander Harkness1-0/+0
2013-11-10Bundled fixes [SEE DESC]Tiger Wang1-1/+1
* Fixed compiler warning in Monster.cpp * Future proofed particle effects * Improved pickups, made less jittery
2013-11-02Fixed dropspensing speed and positionTiger Wang1-1/+22
2013-08-19Moved entities into the Entities subfolder.madmaxoft1-1/+1
2013-07-29Changed everyting to Unix line endings.Alexander Harkness1-245/+245
2013-06-12Implemented the Hopper block handlermadmaxoft@gmail.com1-10/+10
Hoppers can be placed properly, but won't work yet. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1583 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-30Window contents are sent whenever the window is opened by a player.madmaxoft@gmail.com1-1/+0
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1533 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-28Moved BlockEntities to a separate foldermadmaxoft@gmail.com1-2/+2
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1527 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-28Block entities now receive the cChunk param in their Tick() functionmadmaxoft@gmail.com1-16/+13
They can safely access that chunk and any of its neighbors during ticking. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1526 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-27DropSpensers: Fixed activation when receiving redstone signal. Now only one item is dropspensed.madmaxoft@gmail.com1-1/+15
Fix for FS #378, http://www.mc-server.org/support/index.php?do=details&task_id=378 git-svn-id: http://mc-server.googlecode.com/svn/trunk@1521 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-26Fixed cItemGrid API, no more changeable GetSlot().madmaxoft@gmail.com1-1/+24
Also fixed possible water and lava duplication glitches in the dispenser. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1520 0a769ca7-a7f5-676a-18bf-c427514a06d6
2013-05-26Implemented droppersmadmaxoft@gmail.com1-0/+212
Added a common ancestor class "DropSpenser" that has the common code for dropper and dispenser and is Lua-accessible, too. The Debuggers plugin now triggers both droppers and dispensers when rclking them with a redstone torch. git-svn-id: http://mc-server.googlecode.com/svn/trunk@1514 0a769ca7-a7f5-676a-18bf-c427514a06d6