summaryrefslogtreecommitdiffstats
path: root/src/Blocks/BlockPiston.h (unfollow)
Commit message (Collapse)AuthorFilesLines
2021-05-14Re-implement up/down placement metadata (#5219)Tiger Wang1-2/+2
+ Use player position when placing blocks which can face up or down, seems to better correspond to Vanilla behaviour. * Fixes #4651
2021-03-28Do not fake a tool when converting to pickups (#5170)Tiger Wang1-1/+1
* When the cause of destruction was world-induced (CanBeAt check failed) there is no tool. Pass the nullptr directly to ConvertToPickups and let it handle it. * Fixes #4795 - Remove unused a_Digger parameter to ConvertToPickups.
2020-10-08Merged OnBreak with OnPlayerBreak (#4967)12xx121-2/+4
Co-authored-by: 12xx12 <12xx12100@gmail.com> Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
2020-10-05Fix cmake not adding Werror on clang, and _lots_ of warnings (#4963)peterbell101-2/+2
* Fix cmake not adding Werror on clang, and _lots_ of warnings * WIP: Build fixes * Cannot make intermediate blockhandler instance * Tiger's changes * Fix BitIndex check * Handle invalid NextState values in cMultiVersionProtocol Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
2020-09-25Unify block entity pickup conversionTiger Wang1-1/+1
- Removed normal BlockHandler knowledge of block entities during conversion + Added cBlockEntity::ConvertToPickups that handles it
2020-09-20BlockHandler initialisation is a constant expression (#4891)Tiger Wang1-16/+20
* BlockHandler initialisation is a constant expression If we can't make it all namespaces, this is the next best I guess. + Tag handlers constexpr, const as needed + Inherit constructors * Privatise handler functions * More constexpr Co-authored-by: Alexander Harkness <me@bearbin.net>
2020-08-04Corrected wakeup sequencesTiger Wang1-6/+1
* Pistons/Ice no longer need to FastSetBlock first (#4600), and the former don't drop items when broken in creative - Begin migration away from stationary fluids * Tick the chunk after applying a client's changed * Broadcast pending blocks at the end of a tick
2020-07-19Precompile unordered_map/setTiger Wang1-1/+0
+ Add inclusions to Globals.h * Sort Globals.h - Remove sys/stat.h from Globals.h
2020-04-16Using Super.Mattes D1-2/+2
2020-04-11Fix rotation metas on blocksAlexander Harkness1-2/+2
2020-04-10Add mixins for blocks that rotate based on player yaw at placementAlexander Harkness1-46/+2
Also add observer block handler.
2020-03-22Ender chest is not affected by piston (#4526)Mat1-1/+1
2019-10-16Refactored block-to-pickup conversion. (#4417)Mattes D1-14/+27
2018-07-25At long last... Piston animations!Tiger Wang1-0/+6
* Fixes #3198 * Fixes #57 (again lol)
2017-08-01cBlockHandler: take player by refpeterbell101-2/+2
2017-07-17Allocate redstone component handlers upfrontpeterbell101-4/+4
2017-02-14Added some blocks and items (#3503)mathiascode1-0/+4
2016-07-31Redstone fixes (#3285)Tiger Wang1-3/+3
* Comparators and pistons no longer update instantly * Fixes #3168. * Consolidated comparator code * As a result, fixed an issue where GetPowerLevel didn't consider block entities behind it (only GetFrontPowerLevel did)
2016-07-29Revert "Redstone fixes"Mattes D1-3/+3
2016-07-29Comparators and pistons no longer update instantlyTiger Wang1-3/+3
* Fixes #3168.
2016-02-05Bulk clearing of whitespaceLogicParrot1-5/+5
2015-12-18Reorganised the redstone simulatorTiger Wang1-1/+1
-> Many thanks to @worktycho for the idea, and @Haxi52 for the implementation plan! * Uses classes and inheritance now * Speed should be improved
2015-11-07Refactored code to use vectors in the cPistonHandler classbibo381-3/+3
2015-11-07Added some code improvementsbibo381-6/+6
2015-11-07Renamed GetDirectionVec into VectorFromMetaData to improve code readability.bibo381-1/+1
2015-11-07Commented the GetDirectionVec methodbibo381-0/+3
2015-11-07Fixed the style problems and added some commentsbibo381-0/+1
2015-11-07Removed unused CanPull methodbibo381-11/+0
2015-11-07Extracted block moving code into a seperate methodbibo381-0/+4
2015-11-07Replaced the usage of pistonMeta with a direction vector to allow better meta value abstractionbibo381-1/+3
2015-11-07Added the CanPushBlock method for the piston push check.bibo381-2/+7
This allows the recursive check for blocks to push, which is needed to implement the slime blocks into the piston system.
2015-07-31Unified the doxy-comment format.Mattes D1-5/+5
2015-07-14Improved mapsTiger Wang1-0/+6
2015-05-09More style checking.Mattes D1-1/+1
Spaces around some operators are checked.
2015-03-20Removed Metavalue from Piston drops. Bugfix #1765bibo381-0/+2
2014-10-01Added Daylight Sensors to the "can't push" listMasy981-0/+2
2014-10-01Added missing 1.8 blocks, E_METAs and soundsMasy981-0/+2
2014-09-17Added first test to show the object can be createdTycho1-1/+1
2014-09-11Added barrier blockMasy981-0/+1
2014-07-30Added beacon.Howaner1-0/+1
2014-07-17Basic style fixes.madmaxoft1-2/+2
2014-07-17Normalized comments.madmaxoft1-1/+1
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-15Added various missing blocks in the lists in BlockInfo.cppMasy981-1/+0
2014-07-11SuggestionsTiger Wang1-1/+1
2014-07-07Implemented trapped chests & othersTiger Wang1-15/+3
+ Added trapped chests * Fixed a bunch of bugs in the redstone simulator concerning wires and repeaters * Other potential bugfixes
2014-05-29SuggestionsTiger Wang1-1/+6
2014-05-25Hopefully fixed piston duplication issuesTiger Wang1-1/+128
* Fixes #879 * Fixes #714
2014-02-04Improved Type safety of eBlockFaceTycho1-1/+1
May Fix #640
2014-02-01Changed Signiture of OnDestroyedByPlayerTycho1-1/+1
2014-02-01Changed pointers to referencesTycho1-2/+2
2014-02-01Changed signitures of Several BLockHandler MethodsTycho1-2/+2
Changed the signitures of the following to use interfaces: GetPlacementBlockTypeMeta OnPlaced OnPlacedByPlayer OnDestroyed OnNeighbourChanged NeighbourChanged OnUse CanBeAt Check
2013-12-07Fixed some new 1.7 client crash bugsTiger Wang1-0/+6
Some technical blocks were removed; trying to render them as items caused a crash.
2013-11-24Moved source to srcAlexander Harkness1-0/+0
2013-08-10Piston head, when removed, removes the associated piston body, too.madmaxoft1-0/+15
Fixes FS 388
2013-08-09Piston head, when removed, removes the associated piston body, too.madmaxoft1-0/+15
Fixes FS 388
2013-07-29Changed everyting to Unix line endings.Alexander Harkness1-28/+28
2013-01-12Merged branch "branches/hooks" into "trunk".madmaxoft@gmail.com1-7/+20
git-svn-id: http://mc-server.googlecode.com/svn/trunk@1139 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-10-03Moved blockticking into blockhandler classes.madmaxoft@gmail.com1-4/+4
Also slightly refactored the variable / argument names (BlockID is deprecated, use BlockType instead) git-svn-id: http://mc-server.googlecode.com/svn/trunk@921 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-29Unified folder name-casingmadmaxoft@gmail.com1-0/+0
git-svn-id: http://mc-server.googlecode.com/svn/trunk@902 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-09-24Source files cleanup: The rest of the files renamed.madmaxoft@gmail.com1-1/+1
git-svn-id: http://mc-server.googlecode.com/svn/trunk@887 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-16Some code improvementslapayo94@gmail.com1-3/+3
git-svn-id: http://mc-server.googlecode.com/svn/trunk@677 0a769ca7-a7f5-676a-18bf-c427514a06d6
2012-07-15A new Block handling system :olapayo94@gmail.com1-0/+15
It was really a lot of work :D Took me the complete weekend :D Would really like to here your opinion on this =) The aim of this is to put all the actions for one block in one place so it is not spread around the source. (ToPickup, Action in cWorld, Action in cChunk, Action here, action there :D) git-svn-id: http://mc-server.googlecode.com/svn/trunk@671 0a769ca7-a7f5-676a-18bf-c427514a06d6