Commit Graph

6 Commits

Author SHA1 Message Date
5c609cc1c1 Added getShape() and setShape() APIs to StraightOnlyRail and Rail 2021-07-22 18:37:30 +01:00
e97234d420 Refactor Rail handling to allow LSP-complaint shape handling
the reason there hasn't been any API until now is because of how inconvenient it was to expose a LSP-compliant API _and_ use the same base class for handling all the connection logic. This commit fixes that problem by abstracting shape handling away from BaseRail entirely, so that now it deals exclusively with connections. Deciding the shape of rail to use is now the job of the subclasses.
2021-07-22 17:35:10 +01:00
2476f40cc6 Rail: store shape instead of connections
shape is what we'll eventually expose on the API.
2021-07-22 16:45:42 +01:00
b96565faa4 Drop some obviously useless static function variables
these are better suited as constant literals.
2020-09-05 18:39:47 +01:00
921aa091e0 Merge commit '04191ec44a00dd058f5d7e9e315d451e44285494'
# Conflicts:
#	resources/vanilla
#	tests/phpstan/configs/l7-baseline.neon
2020-06-17 20:40:12 +01:00
5499ac620c Removed pocketmine subdirectory, map PSR-4 style 2019-07-30 19:14:57 +01:00