99 lines
3.2 KiB
Text
99 lines
3.2 KiB
Text
[gd_scene load_steps=12 format=3 uid="uid://bkabgl6p44c5b"]
|
|
|
|
[ext_resource type="Script" uid="uid://c1e46eu5tbni0" path="res://games/space invaders/ship.gd" id="1_jsxp6"]
|
|
[ext_resource type="Script" uid="uid://0v0y62pyhpq4" path="res://games/space invaders/space_invaders.gd" id="1_k5cbn"]
|
|
[ext_resource type="Texture2D" uid="uid://d1p5uve4nterl" path="res://sprites/invadersShip.png" id="3_k5cbn"]
|
|
[ext_resource type="Texture2D" uid="uid://yff1qo402ihn" path="res://sprites/ufo.png" id="4_k5cbn"]
|
|
|
|
[sub_resource type="Gradient" id="Gradient_4laqq"]
|
|
interpolation_mode = 1
|
|
offsets = PackedFloat32Array(0, 0.882845)
|
|
|
|
[sub_resource type="FastNoiseLite" id="FastNoiseLite_ceqm6"]
|
|
frequency = 0.0683
|
|
|
|
[sub_resource type="NoiseTexture2D" id="NoiseTexture2D_k5cbn"]
|
|
width = 640
|
|
height = 360
|
|
color_ramp = SubResource("Gradient_4laqq")
|
|
noise = SubResource("FastNoiseLite_ceqm6")
|
|
|
|
[sub_resource type="CircleShape2D" id="CircleShape2D_jdxs5"]
|
|
radius = 24.1868
|
|
|
|
[sub_resource type="Curve2D" id="Curve2D_jdxs5"]
|
|
_data = {
|
|
"points": PackedVector2Array(0, 0, 0, 0, 40, 70, 0, 0, 0, 0, 600, 70, 0, 0, 0, 0, 600, 150, 0, 0, 0, 0, 40, 150, 0, 0, 0, 0, 40, 230, 0, 0, 0, 0, 600, 230)
|
|
}
|
|
point_count = 6
|
|
|
|
[sub_resource type="CircleShape2D" id="CircleShape2D_gagve"]
|
|
radius = 32.0
|
|
|
|
[sub_resource type="LabelSettings" id="LabelSettings_k5cbn"]
|
|
font_size = 36
|
|
|
|
[node name="SpaceInvaders" type="Node" node_paths=PackedStringArray("ufo_path")]
|
|
script = ExtResource("1_k5cbn")
|
|
ufo_path = NodePath("UfoPath/PathFollow2D")
|
|
|
|
[node name="TextureRect" type="TextureRect" parent="."]
|
|
anchors_preset = 15
|
|
anchor_right = 1.0
|
|
anchor_bottom = 1.0
|
|
grow_horizontal = 2
|
|
grow_vertical = 2
|
|
texture = SubResource("NoiseTexture2D_k5cbn")
|
|
|
|
[node name="Ship" type="CharacterBody2D" parent="." node_paths=PackedStringArray("bullet_spawn", "bullet_goal")]
|
|
position = Vector2(336, 319)
|
|
rotation = -1.5708
|
|
motion_mode = 1
|
|
script = ExtResource("1_jsxp6")
|
|
bullet_spawn = NodePath("Spawn")
|
|
bullet_goal = NodePath("Goal")
|
|
|
|
[node name="Sprite2D" type="Sprite2D" parent="Ship"]
|
|
rotation = 1.5708
|
|
scale = Vector2(3, 3)
|
|
texture = ExtResource("3_k5cbn")
|
|
|
|
[node name="CollisionShape2D" type="CollisionShape2D" parent="Ship"]
|
|
shape = SubResource("CircleShape2D_jdxs5")
|
|
|
|
[node name="Spawn" type="Marker2D" parent="Ship"]
|
|
position = Vector2(34, 1.48619e-06)
|
|
|
|
[node name="Goal" type="Marker2D" parent="Ship"]
|
|
position = Vector2(335, 1.46433e-05)
|
|
|
|
[node name="UfoPath" type="Path2D" parent="."]
|
|
position = Vector2(0, 23)
|
|
curve = SubResource("Curve2D_jdxs5")
|
|
|
|
[node name="PathFollow2D" type="PathFollow2D" parent="UfoPath"]
|
|
position = Vector2(40, 70)
|
|
rotates = false
|
|
loop = false
|
|
|
|
[node name="UFO" type="Area2D" parent="UfoPath/PathFollow2D"]
|
|
|
|
[node name="Sprite2D" type="Sprite2D" parent="UfoPath/PathFollow2D/UFO"]
|
|
scale = Vector2(3, 3)
|
|
texture = ExtResource("4_k5cbn")
|
|
|
|
[node name="CollisionShape2D" type="CollisionShape2D" parent="UfoPath/PathFollow2D/UFO"]
|
|
shape = SubResource("CircleShape2D_gagve")
|
|
|
|
[node name="Label" type="Label" parent="."]
|
|
anchors_preset = 5
|
|
anchor_left = 0.5
|
|
anchor_right = 0.5
|
|
offset_left = -196.0
|
|
offset_right = 196.0
|
|
offset_bottom = 50.0
|
|
grow_horizontal = 2
|
|
text = "Shoot The UFO with O!"
|
|
label_settings = SubResource("LabelSettings_k5cbn")
|
|
|
|
[connection signal="area_entered" from="UfoPath/PathFollow2D/UFO" to="." method="_on_ufo_area_entered"]
|