Rewriting ships: Added weapon base and changed hull parent to Node
This commit is contained in:
parent
95274d0a5b
commit
6957169ba5
13 changed files with 121 additions and 37 deletions
|
|
@ -6,3 +6,9 @@ extends Node2D
|
|||
func _physics_process(_delta) -> void:
|
||||
ship.engine.acceleration_axis = Input.get_axis("deccelerate", "accelerate")
|
||||
ship.engine.rotation_axis = Input.get_axis("rotateleft", "rotateright")
|
||||
for weapon in ship.weapons.list:
|
||||
match weapon.action_id:
|
||||
"primary":
|
||||
weapon.shoot_request = Input.get_action_strength("shootprimary")
|
||||
"secondary":
|
||||
weapon.shoot_request = Input.get_action_strength("shootsecondary")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue