summaryrefslogtreecommitdiff
path: root/godot/scripts/vehicles/Gunboat.gd
diff options
context:
space:
mode:
authorAnson Bridges <bridges.anson@gmail.com>2022-10-20 13:54:06 -0400
committerAnson Bridges <bridges.anson@gmail.com>2022-10-20 13:54:06 -0400
commitd34c96aa69d2aee1aaa3bb12366b36ff22d674c0 (patch)
tree12c32c2c452922c92d1daf84a4bd5bebb539c204 /godot/scripts/vehicles/Gunboat.gd
parent6dd265a0aee5fa0ed21b3d272fa3bc07d5d483d9 (diff)
network work work workHEADmaster
Diffstat (limited to 'godot/scripts/vehicles/Gunboat.gd')
-rw-r--r--godot/scripts/vehicles/Gunboat.gd11
1 files changed, 9 insertions, 2 deletions
diff --git a/godot/scripts/vehicles/Gunboat.gd b/godot/scripts/vehicles/Gunboat.gd
index 1defce2..1403a50 100644
--- a/godot/scripts/vehicles/Gunboat.gd
+++ b/godot/scripts/vehicles/Gunboat.gd
@@ -22,7 +22,7 @@ const damage_threshold = 20
const max_depth = 2
#boat ids
-onready var nav_rid = $NavigationMeshInstance.get_region_rid()
+onready var nav_rid = 0#$NavigationMeshInstance.get_region_rid()
#controls
var throttle: float = 0.0
@@ -43,8 +43,15 @@ func _ready():
for sail in $SAILS.get_children():
sail.set_sheet(sail_out)
world = get_tree().get_root().find_node("GAMEWORLD", true, false)
+ var plr = get_tree().get_root().find_node("PLAYERS", true, false)
+ for player in get_node("CREW").get_children():
+ var t: Transform = player.global_transform
+ get_node("CREW").remove_child(player)
+ plr.add_child(player, true)
+ player.global_transform = t
+ #call_deferred("remove_child", get_node("CREW"))
if get_tree().get_network_unique_id() == 1:
- print("enabling navigation for server")
+ pass#print("enabling navigation for server")
#$NavigationMeshInstance.set_enabled(true)
func on_no_control():