summaryrefslogtreecommitdiffstats
path: root/src/Blocks/BlockRail.h (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Clean up CanBeAt Functions (#5587)Alexander Harkness29 hours1-23/+5
| | | | | | | * Use cChunkDef::IsValidHeight for CanBeAt functions, and related helpers. * Add mixins for SolidSurfaceUnderneat and DirtLikeUnderneath * Minor fixes after change review.
* Allow certain blocks to be placed on top of upside-down stairs/slabs (#5468)Michal Havlíček2023-01-251-2/+28
| | | | | | | | | | | * Placing certain blocks on top of upside down slabs and stairs * remove TODO * fix style errors * IsAnyStairType helper function * Block placement on stairs and slabs
* ClientHandle: Fix block interaction regressions (#5431)Tiger Wang2022-07-161-1/+3
| | | | | | | | * ClientHandle: Fix block interaction regressions * Fix reach distance being halved. * Fix fire extinguish not working, fixes #5422. * AddFaceDirection: deprecate non-vector version
* Move item placement into item handlers (#5184)Tiger Wang2021-05-051-141/+96
| | | | | | | | | | | | | | | | | | | | | | | | | * Move item placement into item handlers + Add appropriate CanBeAt checks in cPlayer::PlaceBlocks, into which all placement handlers call. * Partly addresses #5157 * Fixes #4878 * Fixes #2919 * Fixes #4629 * Fixes #4239 * Fixes #4849 Co-authored-by: changyong guo <guo1487@163.com> Co-authored-by: Xotheus <shady3300@outlook.com> Co-authored-by: Krist Pregracke <krist@tiger-scm.com> * Review fixes * Update APIDesc.lua * Rename Co-authored-by: changyong guo <guo1487@163.com> Co-authored-by: Xotheus <shady3300@outlook.com> Co-authored-by: Krist Pregracke <krist@tiger-scm.com>
* Merged OnBreak with OnPlayerBreak (#4967)12xx122020-10-081-2/+3
| | | | Co-authored-by: 12xx12 <12xx12100@gmail.com> Co-authored-by: Tiger Wang <ziwei.tiger@outlook.com>
* Fix cmake not adding Werror on clang, and _lots_ of warnings (#4963)peterbell102020-10-051-1/+1
| | | | | | | | | | | | | | | * 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>
* BlockHandler initialisation is a constant expression (#4891)Tiger Wang2020-09-201-21/+16
| | | | | | | | | | | | | * 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>
* Rail: avoid invalid game states (#4864)Tiger Wang2020-09-131-12/+10
| | | | | | + Check CanBeAt Ref: #4859 Co-authored-by: Alexander Harkness <me@bearbin.net>
* Vector3 in Handlers (#4680)Mattes D2020-04-211-22/+28
| | | Refactored all cBlockHandler and cItemHandler descendants to use Vector3.
* Using Super.Mattes D2020-04-161-4/+4
|
* Refactored block-to-pickup conversion. (#4417)Mattes D2019-10-161-38/+57
|
* cBlockRail: Fix assertion failure (#4075)peterbell102017-11-211-3/+3
|
* cChunkInterface GetBlock, GetBlockMeta, GetBlockTypeMeta use vectors (#4050)Bond-0092017-11-201-49/+50
|
* Only allow rails to be placed where valid.peterbell102017-09-211-1/+8
| | | | Fixes #3507.
* Removed unneeded includes (#3902)Lukas Pioch2017-08-061-2/+0
|
* cBlockHandler: take player by refpeterbell102017-08-011-1/+1
|
* Made cBlockHandler OnPlacedByPlayer call OnPlaced, made BlockRailHandler use NeighborChanged instead of OnNeighborChanged.Lane Kolbly2017-07-181-16/+16
|
* Fix meta mirror (#3470)Mattes D2016-12-091-32/+56
|
* Bulk clearing of whitespaceLogicParrot2016-02-051-15/+15
|
* Reorganised the redstone simulatorTiger Wang2015-12-181-3/+4
| | | | | | -> Many thanks to @worktycho for the idea, and @Haxi52 for the implementation plan! * Uses classes and inheritance now * Speed should be improved
* Improved mapsTiger Wang2015-07-141-13/+7
|
* Added neighbor specification in the OnNeighborChanged() block callback.Mattes D2015-07-011-19/+17
| | | | | Fixes the OnNeighborChanged endless recursion with large melon / pumpkin fields. Fixes #2213.
* Fixed compile and a few more warningstycho2015-05-191-1/+6
|
* More style checking.Mattes D2015-05-091-8/+8
| | | | Spaces around some operators are checked.
* Merge branch 'master' into redstoneTiger Wang2014-12-131-16/+72
|\
| * BasicStyle: Added missing braces to control statements.Mattes D2014-12-051-16/+72
| |
* | Fixed some block checksTiger Wang2014-10-251-2/+2
|/ | | | * Fixes #1330
* Basic style fixes.madmaxoft2014-07-171-11/+11
|
* Normalized comments.madmaxoft2014-07-171-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.
* Did some static analysis, fixed some bugs and optimized a lot of codejfhumann2014-04-181-1/+1
|
* Fixed a few Clang warnings in BlockHandlers.madmaxoft2014-03-301-0/+1
|
* Fixed Minor typos.narroo2014-03-261-6/+6
|
* Added MetaRotate/Mirror Support for a number of classes.narroo2014-03-241-0/+135
|
* g_BlockXXX => cBlockInfo::XXXandrew2014-03-011-2/+2
|
* Improved Type safety of eBlockFaceTycho2014-02-041-2/+2
| | | | May Fix #640
* Changed pointers to referencesTycho2014-02-011-18/+18
|
* Changed signitures of Several BLockHandler MethodsTycho2014-02-011-3/+3
| | | | | | | | | | | | | Changed the signitures of the following to use interfaces: GetPlacementBlockTypeMeta OnPlaced OnPlacedByPlayer OnDestroyed OnNeighbourChanged NeighbourChanged OnUse CanBeAt Check
* Refactored GetPlacementBlockTypeMetaTycho2014-01-261-1/+0
|
* Merge branch 'master' into GeneratingBenchmark2Tycho2014-01-261-9/+19
|\ | | | | | | | | | | Conflicts: src/Blocks/BlockRail.h src/World.h
| * Fixed weird meta with curved railsTiger Wang2014-01-191-5/+15
| |
| * Added more rail functionalityTiger Wang2014-01-191-4/+4
| |
* | Refactored cBlockHandler::OnUse and dependentsTycho2014-01-261-71/+71
|/
* Fixed rails not updating with diagonalsTiger Wang2013-12-251-0/+34
|
* Moved source to srcAlexander Harkness2013-11-241-0/+398