Make shield vessels unarmed hexagons
This commit is contained in:
parent
3fc04f816a
commit
18a7d44db4
3 changed files with 20 additions and 5 deletions
|
|
@ -29,6 +29,7 @@ enum Icon {
|
|||
GAS,
|
||||
LEFT_ARROW, RIGHT_ARROW,
|
||||
MINUS, PLUS,
|
||||
SHIELD_VESSEL,
|
||||
}
|
||||
|
||||
# Size the glyphs were originally drawn against. Every glyph dimension is
|
||||
|
|
@ -213,6 +214,8 @@ func _draw() -> void:
|
|||
_draw_minus(center, pulse, s)
|
||||
Icon.PLUS:
|
||||
_draw_plus(center, pulse, s)
|
||||
Icon.SHIELD_VESSEL:
|
||||
_draw_shield_vessel(center, pulse, s)
|
||||
|
||||
|
||||
func _draw_close(center: Vector2, pulse: float, s: float) -> void:
|
||||
|
|
@ -229,6 +232,14 @@ func _draw_ship(center: Vector2, pulse: float, s: float) -> void:
|
|||
NeonDraw.draw_glowing_polygon(self, points, _active_color(), pulse, core_color)
|
||||
|
||||
|
||||
func _draw_shield_vessel(center: Vector2, pulse: float, s: float) -> void:
|
||||
var points: PackedVector2Array = PackedVector2Array()
|
||||
for i in range(6):
|
||||
var angle: float = -PI / 2.0 + float(i) * TAU / 6.0
|
||||
points.append(center + Vector2(cos(angle), sin(angle)) * 11.0 * s)
|
||||
NeonDraw.draw_glowing_polygon(self, points, _active_color(), pulse, core_color)
|
||||
|
||||
|
||||
func _draw_arrow(center: Vector2, pulse: float, direction: float, s: float) -> void:
|
||||
var r: float = 9.0 * s
|
||||
var tip: Vector2 = center + Vector2(0, r * direction)
|
||||
|
|
|
|||
Loading…
Reference in a new issue