Fixed ship collision shape

This commit is contained in:
Rain Clark 2024-05-12 00:14:36 -04:00
parent 3d5e3cd8b8
commit ca5ac810b4

View File

@ -1,11 +1,8 @@
[gd_scene load_steps=4 format=3 uid="uid://cbo47ftx0vcro"] [gd_scene load_steps=3 format=3 uid="uid://cbo47ftx0vcro"]
[ext_resource type="Script" path="res://scripts/ship.gd" id="1_japvq"] [ext_resource type="Script" path="res://scripts/ship.gd" id="1_japvq"]
[ext_resource type="Texture2D" uid="uid://qcnuvee2jcp0" path="res://assets/img/ship.png" id="1_ymcdl"] [ext_resource type="Texture2D" uid="uid://qcnuvee2jcp0" path="res://assets/img/ship.png" id="1_ymcdl"]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_115lu"]
size = Vector2(35, 35)
[node name="Ship" type="CharacterBody2D" groups=["ship"]] [node name="Ship" type="CharacterBody2D" groups=["ship"]]
collision_mask = 2 collision_mask = 2
script = ExtResource("1_japvq") script = ExtResource("1_japvq")
@ -20,9 +17,9 @@ emission_sphere_radius = 3.0
spread = 105.9 spread = 105.9
gravity = Vector2(0, 0) gravity = Vector2(0, 0)
[node name="CollisionShape2D" type="CollisionShape2D" parent="."] [node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="."]
rotation = 1.54049 position = Vector2(0, -1)
shape = SubResource("RectangleShape2D_115lu") polygon = PackedVector2Array(-3, -31, 4, -31, 32, 28, 32, 33, 28, 33, 1, 16, -24, 33, -32, 33, -32, 27)
[node name="ShotCooldown" type="Timer" parent="."] [node name="ShotCooldown" type="Timer" parent="."]
wait_time = 2.0 wait_time = 2.0