diff options
Diffstat (limited to 'scripts/actors/actions/MovementAction.cs')
| -rw-r--r-- | scripts/actors/actions/MovementAction.cs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/scripts/actors/actions/MovementAction.cs b/scripts/actors/actions/MovementAction.cs index f29e2e8..8d864bd 100644 --- a/scripts/actors/actions/MovementAction.cs +++ b/scripts/actors/actions/MovementAction.cs @@ -13,9 +13,7 @@ public partial class MovementAction : Action { Vector2I finalDestination = actor.GridPosition + Offset; - TileData tile = game.Dungeon.GetCellTileData(finalDestination); - - if (tile == null || !(bool) tile.GetCustomData("isWalkable")) return; + if (!game.Map.IsTileWalkable(finalDestination)) return; actor.Walk(Offset); } |
