summaryrefslogtreecommitdiffstats
path: root/Tile.gd
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2020-07-19 18:17:36 +0200
committerJérémy Zurcher <jeremy@asynk.ch>2020-07-19 18:17:36 +0200
commit2320bc526783ac3fb86e52dde07e8bb736a76286 (patch)
tree8080437f639775e67b3c113153a8972c534cbf72 /Tile.gd
parentfa92fda3e7ea53d479402dcdbd153177ef030c21 (diff)
downloadgodot-hexgrid-2320bc526783ac3fb86e52dde07e8bb736a76286.zip
godot-hexgrid-2320bc526783ac3fb86e52dde07e8bb736a76286.tar.gz
document public API
Diffstat (limited to 'Tile.gd')
-rw-r--r--Tile.gd5
1 files changed, 4 insertions, 1 deletions
diff --git a/Tile.gd b/Tile.gd
index 0aaa0de..a3285e5 100644
--- a/Tile.gd
+++ b/Tile.gd
@@ -24,10 +24,13 @@ func configure(p : Vector2, c: Vector2, o :Array) -> void:
add_child(s)
visible = false
-func has_road(a) -> bool:
+# is there a road with given orientation that drives out of that Tile
+func has_road(orientation : int) -> bool:
print("Tile#has_road() must be overriden in a subclass")
return false
+# is the line of sight blocked from a Tile to another, d beeing the distance between from and to,
+# dt beeing the distance between from and this Tile
func block_los(from : Tile, to : Tile, d : float, dt : float) -> bool:
print("Tile#block_los() must be overriden in a subclass")
return false