Compare commits
No commits in common. "602c9a26f2db345f3495d9bddfeab0607c353d41" and "534a8342131667f1eb10fc13283c6ab3ae711ed6" have entirely different histories.
602c9a26f2
...
534a834213
|
@ -3,6 +3,7 @@
|
|||
[ext_resource path="res://res/fonts/silkscreen/Silkscreen-Regular.ttf" type="DynamicFontData" id=1]
|
||||
|
||||
[sub_resource type="DynamicFont" id=1]
|
||||
size = 8
|
||||
font_data = ExtResource( 1 )
|
||||
|
||||
[resource]
|
||||
|
|
|
@ -22,7 +22,7 @@ script = ExtResource( 2 )
|
|||
use_parent_material = true
|
||||
frames = ExtResource( 1 )
|
||||
animation = "idle"
|
||||
frame = 3
|
||||
frame = 1
|
||||
playing = true
|
||||
centered = false
|
||||
|
||||
|
|
|
@ -14,21 +14,20 @@ func _ready():
|
|||
hp = 7
|
||||
|
||||
func _physics_process(delta):
|
||||
if Global.playing:
|
||||
if not shooting:
|
||||
shooting_timer += delta
|
||||
if shooting_timer >= 2.0:
|
||||
shooting = true
|
||||
shooting_timer = .0
|
||||
if shooting:
|
||||
attack_timer += delta
|
||||
if attack_timer >= .5 and not shot:
|
||||
_shoot()
|
||||
shot = true
|
||||
if attack_timer >= 1.0:
|
||||
attack_timer = 0
|
||||
shooting = false
|
||||
shot = false
|
||||
if not shooting:
|
||||
shooting_timer += delta
|
||||
if shooting_timer >= 2.0:
|
||||
shooting = true
|
||||
shooting_timer = .0
|
||||
if shooting:
|
||||
attack_timer += delta
|
||||
if attack_timer >= .5 and not shot:
|
||||
_shoot()
|
||||
shot = true
|
||||
if attack_timer >= 1.0:
|
||||
attack_timer = 0
|
||||
shooting = false
|
||||
shot = false
|
||||
|
||||
var player_position = player.global_position + Vector2(12, 12)
|
||||
var angle = get_angle_to(player_position)
|
||||
|
|
|
@ -75,7 +75,6 @@ func area_entered(area):
|
|||
stunned_timer = .0
|
||||
recharge_timer = .0
|
||||
$Sprite.play("stun")
|
||||
parent.call_deferred("free")
|
||||
|
||||
func get_recharge():
|
||||
var recharge = 2.0
|
||||
|
|
Loading…
Reference in New Issue