Skip to content

Commit

Permalink
Improved rail block related names.
Browse files Browse the repository at this point in the history
Notably:
- **fixed** `AbstractRailBlock` `allowCurves` -> `uncurvable`: its name was inverted
- `RailPlacementHelper` -> `RailShaper`: it's used to update states (not just for placement), and it sets states (doesn't just get them)
  • Loading branch information
supersaiyansubtlety committed May 3, 2024
1 parent 6aed4cb commit 9e94c39
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 16 deletions.
1 change: 1 addition & 0 deletions buildSrc/src/main/resources/minecraft_specific_words.txt
Original file line number Diff line number Diff line change
Expand Up @@ -408,6 +408,7 @@ uniquifier
unapply
unblocker
uncached
uncurvable
unmap
unpowering
unpowered
Expand Down
15 changes: 7 additions & 8 deletions mappings/net/minecraft/block/AbstractRailBlock.mapping
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
CLASS net/minecraft/unmapped/C_mgkftsgg net/minecraft/block/AbstractRailBlock
FIELD f_afdevxyp allowCurves Z
FIELD f_afdevxyp uncurvable Z
FIELD f_hugfgcne WATERLOGGED Lnet/minecraft/unmapped/C_xhwijdsd;
FIELD f_qnbjbbpm STRAIGHT_SHAPE Lnet/minecraft/unmapped/C_zscvhwbd;
FIELD f_vrvdpeyj ASCENDING_SHAPE Lnet/minecraft/unmapped/C_zscvhwbd;
METHOD <init> (ZLnet/minecraft/unmapped/C_triydqro$C_xnkxsdfy;)V
ARG 1 allowCurves
ARG 1 uncurvable
ARG 2 settings
METHOD m_gnxvkdbi canMakeCurves ()Z
METHOD m_gnxvkdbi isUncurvable ()Z
METHOD m_hrqcdmdw getShapeProperty ()Lnet/minecraft/unmapped/C_vzlztuyw;
METHOD m_lczpeazs isRail (Lnet/minecraft/unmapped/C_txtbiemp;)Z
ARG 0 state
Expand All @@ -15,12 +15,11 @@ CLASS net/minecraft/unmapped/C_mgkftsgg net/minecraft/block/AbstractRailBlock
ARG 2 world
ARG 3 pos
ARG 4 notify
METHOD m_oyknusit shouldDropRail (Lnet/minecraft/unmapped/C_hynzadkk;Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_wqmdpcsg;)Z
COMMENT Checks if this rail should be dropped.
METHOD m_oyknusit shouldBreak (Lnet/minecraft/unmapped/C_hynzadkk;Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_wqmdpcsg;)Z
COMMENT Checks if this rail should break.
COMMENT
COMMENT <p>This method will return true if:
COMMENT <ul><li>The rail block is ascending.</li>
COMMENT <li>The block in the direction of ascent does not have a top rim.</li></ul>
COMMENT @return {@code true} if the block below or the block {@code shape} is ascending
COMMENT toward has no top rim, or {@code false} otherwise
ARG 0 pos
ARG 1 world
ARG 2 shape
Expand Down
4 changes: 2 additions & 2 deletions mappings/net/minecraft/block/DetectorRailBlock.mapping
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ CLASS net/minecraft/unmapped/C_zqpbsygh net/minecraft/block/DetectorRailBlock
FIELD f_jedrripe CODEC Lcom/mojang/serialization/MapCodec;
FIELD f_pxzqiwxu SHAPE Lnet/minecraft/unmapped/C_cgckxfsw;
FIELD f_quzejqpi SCHEDULED_TICK_DELAY I
METHOD m_eipmlwqv updateNearbyRails (Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_hynzadkk;Lnet/minecraft/unmapped/C_txtbiemp;Z)V
METHOD m_eipmlwqv updateNeighboringRails (Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_hynzadkk;Lnet/minecraft/unmapped/C_txtbiemp;Z)V
ARG 1 world
ARG 2 pos
ARG 3 state
Expand All @@ -19,7 +19,7 @@ CLASS net/minecraft/unmapped/C_zqpbsygh net/minecraft/block/DetectorRailBlock
ARG 0 cart
METHOD m_nhdhwndc getCartDetectionBox (Lnet/minecraft/unmapped/C_hynzadkk;)Lnet/minecraft/unmapped/C_hbcjzgoe;
ARG 1 pos
METHOD m_wvmxinfs updatePoweredStatus (Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_hynzadkk;Lnet/minecraft/unmapped/C_txtbiemp;)V
METHOD m_wvmxinfs updatePowered (Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_hynzadkk;Lnet/minecraft/unmapped/C_txtbiemp;)V
ARG 1 world
ARG 2 pos
ARG 3 state
2 changes: 2 additions & 0 deletions mappings/net/minecraft/block/PoweredRailBlock.mapping
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@ CLASS net/minecraft/unmapped/C_kgjmyjbt net/minecraft/block/PoweredRailBlock
ARG 1 world
ARG 2 pos
ARG 3 state
ARG 4 towardSouthWest
ARG 5 distance
METHOD m_thcgcfzo isPoweredByOtherRails (Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_hynzadkk;ZILnet/minecraft/unmapped/C_wqmdpcsg;)Z
ARG 1 world
ARG 2 pos
ARG 3 towardSouthWest
ARG 4 distance
ARG 5 shape
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
CLASS net/minecraft/unmapped/C_baboixhf net/minecraft/block/RailPlacementHelper
CLASS net/minecraft/unmapped/C_baboixhf net/minecraft/block/RailShaper
FIELD f_eahnpbkg world Lnet/minecraft/unmapped/C_cdctfzbn;
FIELD f_hemssstp allowCurves Z
FIELD f_hemssstp uncurvable Z
FIELD f_hlyugvpt state Lnet/minecraft/unmapped/C_txtbiemp;
FIELD f_rryvaloh pos Lnet/minecraft/unmapped/C_hynzadkk;
FIELD f_wturrxrq block Lnet/minecraft/unmapped/C_mgkftsgg;
FIELD f_wturrxrq rail Lnet/minecraft/unmapped/C_mgkftsgg;
FIELD f_zqdajzpc neighbors Ljava/util/List;
METHOD <init> (Lnet/minecraft/unmapped/C_cdctfzbn;Lnet/minecraft/unmapped/C_hynzadkk;Lnet/minecraft/unmapped/C_txtbiemp;)V
ARG 1 world
Expand All @@ -17,17 +17,17 @@ CLASS net/minecraft/unmapped/C_baboixhf net/minecraft/block/RailPlacementHelper
METHOD m_iyefeyle computeRailShape (Lnet/minecraft/unmapped/C_baboixhf;)V
ARG 1 placementHelper
METHOD m_kdjdlukx getNeighborCount ()I
METHOD m_krxloedb getBlockState ()Lnet/minecraft/unmapped/C_txtbiemp;
METHOD m_krxloedb getState ()Lnet/minecraft/unmapped/C_txtbiemp;
METHOD m_mwvknrio isVerticallyNearRail (Lnet/minecraft/unmapped/C_hynzadkk;)Z
ARG 1 pos
METHOD m_pbhepuoc getNeighboringRail (Lnet/minecraft/unmapped/C_hynzadkk;)Lnet/minecraft/unmapped/C_baboixhf;
METHOD m_pbhepuoc createNeighboring (Lnet/minecraft/unmapped/C_hynzadkk;)Lnet/minecraft/unmapped/C_baboixhf;
ARG 1 pos
METHOD m_uhplfsvb computeNeighbors (Lnet/minecraft/unmapped/C_wqmdpcsg;)V
ARG 1 shape
METHOD m_wbrfjfef updateBlockState (ZZLnet/minecraft/unmapped/C_wqmdpcsg;)Lnet/minecraft/unmapped/C_baboixhf;
ARG 1 powered
ARG 2 forceUpdate
ARG 3 railShape
ARG 3 shape
METHOD m_xktdbyvo getNeighbors ()Ljava/util/List;
METHOD m_xzghrphx canConnect (Lnet/minecraft/unmapped/C_hynzadkk;)Z
ARG 1 pos
Expand Down

0 comments on commit 9e94c39

Please sign in to comment.