forked from team-sg/hero-mark-2
made it so roboturret can be flipped in editor
This commit is contained in:
parent
319eec7f5b
commit
6a180c4f0c
2 changed files with 3 additions and 6 deletions
|
@ -24,11 +24,8 @@ func _physics_process(delta):
|
|||
|
||||
func spawn_bullet():
|
||||
var arrow = ArrowProjectile.instance()
|
||||
if scale.x > 0:
|
||||
arrow.global_position = global_position + shootpos.position
|
||||
else:
|
||||
arrow.global_position = global_position + shootpos.position
|
||||
arrow.direction = sign(shootpos.position.x)
|
||||
arrow.global_position = global_position + (shootpos.position * scale)
|
||||
arrow.direction = sign(shootpos.position.x) * scale.x
|
||||
arrow.target_group = "player"
|
||||
arrow.speed = arrow_speed
|
||||
Game.get_map().add_child(arrow)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue