Animate ship crafter deliveries
This commit is contained in:
parent
fc68c4e8cf
commit
798deb48a1
5 changed files with 140 additions and 4 deletions
16
VesselDelivery.gd
Normal file
16
VesselDelivery.gd
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
extends Node2D
|
||||
|
||||
# Visual-only craft-to-mothership flight. GameState owns position/progress;
|
||||
# this node just renders a finished hull headed toward the hangar.
|
||||
var vessel_type: String = GameState.VESSEL_INTERCEPTOR
|
||||
|
||||
|
||||
func _ready() -> void:
|
||||
z_index = -1
|
||||
queue_redraw()
|
||||
|
||||
|
||||
func _draw() -> void:
|
||||
var color: Color = Color(0.45, 0.8, 1.0) if vessel_type == GameState.VESSEL_SHIELD else Color(0.95, 0.55, 0.85) if vessel_type == GameState.VESSEL_TRANSPORTER else Color(0.25, 0.85, 1.0)
|
||||
var hull := PackedVector2Array([Vector2(0, -20), Vector2(13, 15), Vector2(0, 9), Vector2(-13, 15)])
|
||||
NeonDraw.draw_glowing_polygon(self, hull, color, 1.0)
|
||||
Loading…
Reference in a new issue