added ammo type models

This commit is contained in:
Derek
2025-01-16 20:15:09 -06:00
parent 5c6f010fdc
commit 0a3bdd26d4
16 changed files with 634 additions and 80 deletions

View File

@@ -7,6 +7,9 @@ extends Control
## ITEM TEXTURES
#AMMO
const LIGHT_AMMO = preload("res://assets/Textures/ObjectTextures/light_ammo.png")
const MEDIUM_AMMO = preload("res://assets/Textures/ObjectTextures/medium_ammo.png")
const HEAVY_AMMO = preload("res://assets/Textures/ObjectTextures/heavy_ammo.png")
const SHOTGUN_AMMO = preload("res://assets/Textures/ObjectTextures/shotgun_ammo.png")
const ROCKET = preload("res://assets/Textures/ObjectTextures/rocket.png")
const MONEY = preload("res://assets/Textures/ObjectTextures/money.png")
@@ -30,11 +33,11 @@ func _ready() -> void:
0:
image.texture = LIGHT_AMMO
1:
image.texture = LIGHT_AMMO #medium
image.texture = MEDIUM_AMMO #medium
2:
image.texture = LIGHT_AMMO #heavy
image.texture = HEAVY_AMMO #heavy
3:
image.texture = LIGHT_AMMO #shotgun
image.texture = SHOTGUN_AMMO #shotgun
4:
image.texture = ROCKET
1:
@@ -52,10 +55,10 @@ func _ready() -> void:
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
alpha_amt = lerp(alpha_amt, 0.0,delta * 1)
alpha_amt = lerp(alpha_amt, 0.0,delta * 1.5)
modulate = Color(1, 1, 1, alpha_amt)
position += random_point * delta * 2
scale -= Vector2(.2,.2) * delta
position += random_point * delta * 1.5
scale = lerp(scale,Vector2(0,0), delta * .5)
if alpha_amt <= .01:
queue_free()