Added WIP game modes; renamed control_modes folder to jet_controls

This commit is contained in:
2026-10-18 18:11:32 -05:00
parent 79b7265688
commit 4462600e06
23 changed files with 57 additions and 32 deletions
+5 -9
View File
@@ -25,21 +25,17 @@ func _get_jet_type(faction: int) -> Jet:
func create_player_jet(faction: int = 0) -> Jet:
var jet: Jet = _get_jet_type(faction)
get_tree().root.add_child(jet)
print("1")
await get_tree().process_frame
await get_tree().process_frame
await get_tree().process_frame
await get_tree().process_frame
print("2")
get_tree().root.add_child.call_deferred(jet)
await jet.ready
jet.set_as_player()
return jet
func create_cpu_jet(faction: int = 0) -> Jet:
var jet = _get_jet_type(faction)
get_tree().root.add_child(jet)
await get_tree().process_frame
get_tree().root.add_child.call_deferred(jet)
await jet.ready
jet.set_as_cpu()
return jet