|
@@ -28,7 +28,7 @@ var posiy
|
|
var dirx = 0
|
|
var dirx = 0
|
|
var diry = 0
|
|
var diry = 0
|
|
|
|
|
|
-export var dire = Direction.UP
|
|
|
|
|
|
+var dire
|
|
var dire_delta = 0
|
|
var dire_delta = 0
|
|
|
|
|
|
var target_pos
|
|
var target_pos
|
|
@@ -48,8 +48,10 @@ func _ready():
|
|
cell_size = int (grid.get_cell_size().x)
|
|
cell_size = int (grid.get_cell_size().x)
|
|
cell_half_size = cell_size / 2
|
|
cell_half_size = cell_size / 2
|
|
|
|
|
|
|
|
+ # Adjust spawn situation
|
|
posix = int (position.x / 64)
|
|
posix = int (position.x / 64)
|
|
posiy = int (position.y / 64)
|
|
posiy = int (position.y / 64)
|
|
|
|
+ dire = int((rotation_degrees + 45) / 90)
|
|
|
|
|
|
apply_turn()
|
|
apply_turn()
|
|
|
|
|