From c7d45ec085086ab86192a7890b9622320d57b89d Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Fri, 3 Jun 2016 10:30:38 -0300 Subject: Removed demos they go to their own project now --- demos/2d/space_shooter/asteroid.gd | 43 ---- demos/2d/space_shooter/asteroid.tscn | 129 ----------- demos/2d/space_shooter/bg_gradient.png | Bin 1572 -> 0 bytes demos/2d/space_shooter/big_star.png | Bin 275 -> 0 bytes demos/2d/space_shooter/enemy1.gd | 36 ---- demos/2d/space_shooter/enemy1.png | Bin 7048 -> 0 bytes demos/2d/space_shooter/enemy1.tscn | 108 ---------- demos/2d/space_shooter/enemy2.gd | 47 ---- demos/2d/space_shooter/enemy2.png | Bin 5676 -> 0 bytes demos/2d/space_shooter/enemy2.tscn | 98 --------- demos/2d/space_shooter/enemy_shot.gd | 31 --- demos/2d/space_shooter/enemy_shot.png | Bin 330 -> 0 bytes demos/2d/space_shooter/enemy_shot.tscn | 99 --------- demos/2d/space_shooter/engine.cfg | 22 -- demos/2d/space_shooter/explosion.tscn | 37 ---- demos/2d/space_shooter/fire.png | Bin 357 -> 0 bytes demos/2d/space_shooter/game_state.gd | 22 -- demos/2d/space_shooter/icon.png | Bin 6931 -> 0 bytes demos/2d/space_shooter/level.tscn | 354 ------------------------------- demos/2d/space_shooter/main_menu.gd | 11 - demos/2d/space_shooter/main_menu.tscn | 64 ------ demos/2d/space_shooter/meteorite.png | Bin 6072 -> 0 bytes demos/2d/space_shooter/parallax.tscn | 201 ------------------ demos/2d/space_shooter/rail.gd | 19 -- demos/2d/space_shooter/ship.gd | 81 ------- demos/2d/space_shooter/ship.png | Bin 2815 -> 0 bytes demos/2d/space_shooter/ship.tscn | 229 -------------------- demos/2d/space_shooter/shoot.png | Bin 222 -> 0 bytes demos/2d/space_shooter/shot.gd | 40 ---- demos/2d/space_shooter/shot.tscn | 103 --------- demos/2d/space_shooter/small_star.png | Bin 90 -> 0 bytes demos/2d/space_shooter/sound_explode.wav | Bin 75832 -> 0 bytes demos/2d/space_shooter/sound_shoot.wav | Bin 78888 -> 0 bytes demos/2d/space_shooter/tile.png | Bin 810 -> 0 bytes demos/2d/space_shooter/tileset.tres | 20 -- demos/2d/space_shooter/tileset_edit.tscn | 35 --- 36 files changed, 1829 deletions(-) delete mode 100644 demos/2d/space_shooter/asteroid.gd delete mode 100644 demos/2d/space_shooter/asteroid.tscn delete mode 100644 demos/2d/space_shooter/bg_gradient.png delete mode 100644 demos/2d/space_shooter/big_star.png delete mode 100644 demos/2d/space_shooter/enemy1.gd delete mode 100644 demos/2d/space_shooter/enemy1.png delete mode 100644 demos/2d/space_shooter/enemy1.tscn delete mode 100644 demos/2d/space_shooter/enemy2.gd delete mode 100644 demos/2d/space_shooter/enemy2.png delete mode 100644 demos/2d/space_shooter/enemy2.tscn delete mode 100644 demos/2d/space_shooter/enemy_shot.gd delete mode 100644 demos/2d/space_shooter/enemy_shot.png delete mode 100644 demos/2d/space_shooter/enemy_shot.tscn delete mode 100644 demos/2d/space_shooter/engine.cfg delete mode 100644 demos/2d/space_shooter/explosion.tscn delete mode 100644 demos/2d/space_shooter/fire.png delete mode 100644 demos/2d/space_shooter/game_state.gd delete mode 100644 demos/2d/space_shooter/icon.png delete mode 100644 demos/2d/space_shooter/level.tscn delete mode 100644 demos/2d/space_shooter/main_menu.gd delete mode 100644 demos/2d/space_shooter/main_menu.tscn delete mode 100644 demos/2d/space_shooter/meteorite.png delete mode 100644 demos/2d/space_shooter/parallax.tscn delete mode 100644 demos/2d/space_shooter/rail.gd delete mode 100644 demos/2d/space_shooter/ship.gd delete mode 100644 demos/2d/space_shooter/ship.png delete mode 100644 demos/2d/space_shooter/ship.tscn delete mode 100644 demos/2d/space_shooter/shoot.png delete mode 100644 demos/2d/space_shooter/shot.gd delete mode 100644 demos/2d/space_shooter/shot.tscn delete mode 100644 demos/2d/space_shooter/small_star.png delete mode 100644 demos/2d/space_shooter/sound_explode.wav delete mode 100644 demos/2d/space_shooter/sound_shoot.wav delete mode 100644 demos/2d/space_shooter/tile.png delete mode 100644 demos/2d/space_shooter/tileset.tres delete mode 100644 demos/2d/space_shooter/tileset_edit.tscn (limited to 'demos/2d/space_shooter') diff --git a/demos/2d/space_shooter/asteroid.gd b/demos/2d/space_shooter/asteroid.gd deleted file mode 100644 index ab71f413eb..0000000000 --- a/demos/2d/space_shooter/asteroid.gd +++ /dev/null @@ -1,43 +0,0 @@ - -extends Area2D - -# Member variables -const SPEED = -200 -const Y_RANDOM = 10 - -var points = 1 -var speed_y = 0.0 -var destroyed = false - - -func _fixed_process(delta): - translate(Vector2(SPEED, speed_y)*delta) - - -func _ready(): - speed_y = rand_range(-Y_RANDOM, Y_RANDOM) - - -func destroy(): - if (destroyed): - return - destroyed = true - get_node("anim").play("explode") - set_fixed_process(false) - get_node("sfx").play("sound_explode") - # Accumulate points - get_node("/root/game_state").points += 1 - - -func is_enemy(): - return not destroyed - - -func _on_visibility_enter_screen(): - set_fixed_process(true) - # Make it spin! - get_node("anim").play("spin") - - -func _on_visibility_exit_screen(): - queue_free() diff --git a/demos/2d/space_shooter/asteroid.tscn b/demos/2d/space_shooter/asteroid.tscn deleted file mode 100644 index ad57f6ef7c..0000000000 --- a/demos/2d/space_shooter/asteroid.tscn +++ /dev/null @@ -1,129 +0,0 @@ -[gd_scene load_steps=9 format=1] - -[ext_resource path="res://asteroid.gd" type="Script" id=1] -[ext_resource path="res://meteorite.png" type="Texture" id=2] -[ext_resource path="res://sound_explode.wav" type="Sample" id=3] - -[sub_resource type="CircleShape2D" id=1] - -custom_solver_bias = 0.0 -radius = 22.0 - -[sub_resource type="Animation" id=2] - -resource/name = "explode" -length = 1.0 -loop = false -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath("particles:config/emitting") -tracks/0/interp = 1 -tracks/0/keys = { "cont":false, "times":FloatArray( 0, 0.1 ), "transitions":FloatArray( 1, 1 ), "values":[ true, false ] } -tracks/1/type = "value" -tracks/1/path = NodePath("sprite:visibility/visible") -tracks/1/interp = 1 -tracks/1/keys = { "cont":false, "times":FloatArray( 0 ), "transitions":FloatArray( 1 ), "values":[ false ] } -tracks/2/type = "method" -tracks/2/path = NodePath(".") -tracks/2/interp = 1 -tracks/2/keys = { "times":FloatArray( 0.7 ), "transitions":FloatArray( 1 ), "values":[ { "args":[ ], "method":"queue_free" } ] } - -[sub_resource type="Animation" id=3] - -length = 3.0 -loop = true -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath("sprite:transform/rot") -tracks/0/interp = 1 -tracks/0/keys = { "cont":true, "times":FloatArray( 0, 3 ), "transitions":FloatArray( 1, 1 ), "values":[ 0.0, 360.0 ] } - -[sub_resource type="ColorRamp" id=4] - -offsets = FloatArray( 0, 1 ) -colors = ColorArray( 1, 1, 1, 1, 1, 1, 1, 0 ) - -[sub_resource type="SampleLibrary" id=5] - -samples/sound_explode = { "db":0.0, "pitch":1.0, "sample":ExtResource( 3 ) } - -[node name="asteroid" type="Area2D"] - -input/pickable = true -shapes/0/shape = SubResource( 1 ) -shapes/0/transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -shapes/0/trigger = false -gravity_vec = Vector2( 0, 1 ) -gravity = 98.0 -linear_damp = 0.1 -angular_damp = 1.0 -script/script = ExtResource( 1 ) - -[node name="sprite" type="Sprite" parent="."] - -texture = ExtResource( 2 ) - -[node name="anim" type="AnimationPlayer" parent="."] - -playback/process_mode = 1 -playback/default_blend_time = 0.0 -root/root = NodePath("..") -anims/explode = SubResource( 2 ) -anims/spin = SubResource( 3 ) -playback/active = true -playback/speed = 1.0 -blend_times = [ ] -autoplay = "" - -[node name="collision" type="CollisionShape2D" parent="."] - -shape = SubResource( 1 ) -trigger = false -_update_shape_index = -1 - -[node name="visibility" type="VisibilityNotifier2D" parent="."] - -rect = Rect2( -10, -10, 20, 20 ) - -[node name="particles" type="Particles2D" parent="."] - -config/amount = 32 -config/lifetime = 0.5 -config/emitting = false -config/half_extents = Vector2( 20, 20 ) -config/explosiveness = 0.1 -config/texture = ExtResource( 2 ) -params/direction = 0.0 -params/spread = 180.0 -params/linear_velocity = 200.0 -params/spin_velocity = 0.0 -params/orbit_velocity = 0.0 -params/gravity_direction = 0.0 -params/gravity_strength = 9.8 -params/radial_accel = 0.0 -params/tangential_accel = 0.0 -params/damping = 0.0 -params/initial_angle = 0.0 -params/initial_size = 0.5 -params/final_size = 0.2 -params/hue_variation = 0.0 -params/anim_speed_scale = 1.0 -params/anim_initial_pos = 0.0 -color/color_ramp = SubResource( 4 ) - -[node name="sfx" type="SamplePlayer2D" parent="."] - -params/volume_db = 0.0 -params/pitch_scale = 1.0 -params/attenuation/min_distance = 1.0 -params/attenuation/max_distance = 2048.0 -params/attenuation/distance_exp = 1.0 -config/polyphony = 1 -config/samples = SubResource( 5 ) -config/pitch_random = 0.0 - -[connection signal="enter_screen" from="visibility" to="." method="_on_visibility_enter_screen"] - -[connection signal="exit_screen" from="visibility" to="." method="_on_visibility_exit_screen"] - - diff --git a/demos/2d/space_shooter/bg_gradient.png b/demos/2d/space_shooter/bg_gradient.png deleted file mode 100644 index 3e71976dc6..0000000000 Binary files a/demos/2d/space_shooter/bg_gradient.png and /dev/null differ diff --git a/demos/2d/space_shooter/big_star.png b/demos/2d/space_shooter/big_star.png deleted file mode 100644 index 7726a7aa12..0000000000 Binary files a/demos/2d/space_shooter/big_star.png and /dev/null differ diff --git a/demos/2d/space_shooter/enemy1.gd b/demos/2d/space_shooter/enemy1.gd deleted file mode 100644 index e127eb2777..0000000000 --- a/demos/2d/space_shooter/enemy1.gd +++ /dev/null @@ -1,36 +0,0 @@ - -extends Area2D - -# Member variables -const SPEED = -200 - -var destroyed=false - - -func _fixed_process(delta): - get_parent().translate(Vector2(SPEED*delta, 0)) - - -func is_enemy(): - return not destroyed - - -func destroy(): - if (destroyed): - return - destroyed = true - get_node("anim").play("explode") - set_fixed_process(false) - get_node("sfx").play("sound_explode") - # Accumulate points - get_node("/root/game_state").points += 5 - - -func _on_visibility_enter_screen(): - set_fixed_process(true) - get_node("anim").play("zigzag") - get_node("anim").seek(randf()*2.0) # Make it start from any pos - - -func _on_visibility_exit_screen(): - queue_free() diff --git a/demos/2d/space_shooter/enemy1.png b/demos/2d/space_shooter/enemy1.png deleted file mode 100644 index 242d8f0055..0000000000 Binary files a/demos/2d/space_shooter/enemy1.png and /dev/null differ diff --git a/demos/2d/space_shooter/enemy1.tscn b/demos/2d/space_shooter/enemy1.tscn deleted file mode 100644 index 5fd4435382..0000000000 --- a/demos/2d/space_shooter/enemy1.tscn +++ /dev/null @@ -1,108 +0,0 @@ -[gd_scene load_steps=9 format=1] - -[ext_resource path="res://enemy1.gd" type="Script" id=1] -[ext_resource path="res://enemy1.png" type="Texture" id=2] -[ext_resource path="res://explosion.tscn" type="PackedScene" id=3] -[ext_resource path="res://sound_explode.wav" type="Sample" id=4] - -[sub_resource type="ConvexPolygonShape2D" id=1] - -custom_solver_bias = 0.0 -points = Vector2Array( -25.3272, 15.4072, -31.2711, -7.28794, -1.01097, -20.7969, 24.9263, -4.58614, 30.3299, 13.2457, -2.63205, 17.5686 ) - -[sub_resource type="Animation" id=2] - -length = 1.0 -loop = false -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath("sprite:visibility/visible") -tracks/0/interp = 1 -tracks/0/keys = { "cont":false, "times":FloatArray( 0 ), "transitions":FloatArray( 1 ), "values":[ false ] } -tracks/1/type = "value" -tracks/1/path = NodePath("explosion:config/emitting") -tracks/1/interp = 1 -tracks/1/keys = { "cont":false, "times":FloatArray( 0, 0.1 ), "transitions":FloatArray( 1, 1 ), "values":[ true, false ] } -tracks/2/type = "method" -tracks/2/path = NodePath("..") -tracks/2/interp = 1 -tracks/2/keys = { "times":FloatArray( 0.9 ), "transitions":FloatArray( 1 ), "values":[ { "args":[ ], "method":"queue_free" } ] } - -[sub_resource type="Animation" id=3] - -length = 2.0 -loop = true -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath(".:transform/pos") -tracks/0/interp = 1 -tracks/0/keys = { "cont":true, "times":FloatArray( 0, 1 ), "transitions":FloatArray( -1.86607, -1.86607 ), "values":[ Vector2( 0, -100 ), Vector2( 0, 100 ) ] } - -[sub_resource type="SampleLibrary" id=4] - -samples/sound_explode = { "db":0.0, "pitch":1.0, "sample":ExtResource( 4 ) } - -[node name="enemy1" type="Node2D"] - -[node name="area" type="Area2D" parent="."] - -transform/pos = Vector2( 0, -100 ) -input/pickable = true -shapes/0/shape = SubResource( 1 ) -shapes/0/transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -shapes/0/trigger = false -gravity_vec = Vector2( 0, 1 ) -gravity = 98.0 -linear_damp = 0.1 -angular_damp = 1.0 -script/script = ExtResource( 1 ) - -[node name="collision" type="CollisionPolygon2D" parent="area"] - -build_mode = 0 -polygon = Vector2Array( -31.2711, -7.28794, -1.01097, -20.7969, 24.9263, -4.58614, 30.3299, 13.2457, -2.63205, 17.5686, -25.3272, 15.4072 ) -shape_range = Vector2( -1, -1 ) -trigger = false - -[node name="sprite" type="Sprite" parent="area"] - -texture = ExtResource( 2 ) - -[node name="explosion" parent="area" instance=ExtResource( 3 )] - -transform/rot = -91.1436 -config/explosiveness = 0.1 -params/gravity_strength = 9.8 - -[node name="anim" type="AnimationPlayer" parent="area"] - -playback/process_mode = 1 -playback/default_blend_time = 0.0 -root/root = NodePath("..") -anims/explode = SubResource( 2 ) -anims/zigzag = SubResource( 3 ) -playback/active = true -playback/speed = 1.0 -blend_times = [ ] -autoplay = "" - -[node name="visibility" type="VisibilityNotifier2D" parent="area"] - -rect = Rect2( -10, -10, 20, 20 ) - -[node name="sfx" type="SamplePlayer2D" parent="area"] - -params/volume_db = 0.0 -params/pitch_scale = 1.0 -params/attenuation/min_distance = 1.0 -params/attenuation/max_distance = 2048.0 -params/attenuation/distance_exp = 1.0 -config/polyphony = 1 -config/samples = SubResource( 4 ) -config/pitch_random = 0.0 - -[connection signal="enter_screen" from="area/visibility" to="area" method="_on_visibility_enter_screen"] - -[connection signal="exit_screen" from="area/visibility" to="area" method="_on_visibility_exit_screen"] - - diff --git a/demos/2d/space_shooter/enemy2.gd b/demos/2d/space_shooter/enemy2.gd deleted file mode 100644 index 773c266d8c..0000000000 --- a/demos/2d/space_shooter/enemy2.gd +++ /dev/null @@ -1,47 +0,0 @@ - -extends Area2D - -# Member variables -const SPEED = -220 -const SHOOT_INTERVAL = 1 - -var shoot_timeout = 0 -var destroyed=false - - -func _fixed_process(delta): - translate(Vector2(SPEED*delta, 0)) - shoot_timeout -= delta - - if (shoot_timeout < 0): - shoot_timeout = SHOOT_INTERVAL - - # Instance a shot - var shot = preload("res://enemy_shot.tscn").instance() - # Set pos as "shoot_from" Position2D node - shot.set_pos(get_node("shoot_from").get_global_pos()) - # Add it to parent, so it has world coordinates - get_parent().add_child(shot) - - -func is_enemy(): - return not destroyed - - -func destroy(): - if (destroyed): - return - destroyed = true - get_node("anim").play("explode") - set_fixed_process(false) - get_node("sfx").play("sound_explode") - # Accumulate points - get_node("/root/game_state").points += 10 - - -func _on_visibility_enter_screen(): - set_fixed_process(true) - - -func _on_visibility_exit_screen(): - queue_free() diff --git a/demos/2d/space_shooter/enemy2.png b/demos/2d/space_shooter/enemy2.png deleted file mode 100644 index 5b63033696..0000000000 Binary files a/demos/2d/space_shooter/enemy2.png and /dev/null differ diff --git a/demos/2d/space_shooter/enemy2.tscn b/demos/2d/space_shooter/enemy2.tscn deleted file mode 100644 index 56d9f49720..0000000000 --- a/demos/2d/space_shooter/enemy2.tscn +++ /dev/null @@ -1,98 +0,0 @@ -[gd_scene load_steps=8 format=1] - -[ext_resource path="res://enemy2.gd" type="Script" id=1] -[ext_resource path="res://enemy2.png" type="Texture" id=2] -[ext_resource path="res://explosion.tscn" type="PackedScene" id=3] -[ext_resource path="res://sound_explode.wav" type="Sample" id=4] - -[sub_resource type="ConvexPolygonShape2D" id=1] - -custom_solver_bias = 0.0 -points = Vector2Array( -31.9306, -11.1163, 15.748, -16.1351, 32.2383, -3.94662, 25.7856, 13.6192, -20.4591, 16.1286 ) - -[sub_resource type="Animation" id=2] - -length = 1.0 -loop = false -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath("explosion:config/emitting") -tracks/0/interp = 1 -tracks/0/keys = { "cont":false, "times":FloatArray( 0, 0.1 ), "transitions":FloatArray( 1, 1 ), "values":[ true, false ] } -tracks/1/type = "value" -tracks/1/path = NodePath("sprite:visibility/visible") -tracks/1/interp = 1 -tracks/1/keys = { "cont":false, "times":FloatArray( 0 ), "transitions":FloatArray( 1 ), "values":[ false ] } -tracks/2/type = "method" -tracks/2/path = NodePath(".") -tracks/2/interp = 1 -tracks/2/keys = { "times":FloatArray( 0.9 ), "transitions":FloatArray( 1 ), "values":[ { "args":[ ], "method":"queue_free" } ] } - -[sub_resource type="SampleLibrary" id=3] - -samples/sound_explode = { "db":0.0, "pitch":1.0, "sample":ExtResource( 4 ) } - -[node name="enemy2" type="Area2D"] - -input/pickable = true -shapes/0/shape = SubResource( 1 ) -shapes/0/transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -shapes/0/trigger = false -gravity_vec = Vector2( 0, 1 ) -gravity = 98.0 -linear_damp = 0.1 -angular_damp = 1.0 -script/script = ExtResource( 1 ) - -[node name="collision" type="CollisionPolygon2D" parent="."] - -build_mode = 0 -polygon = Vector2Array( -31.9306, -11.1163, 15.748, -16.1351, 32.2383, -3.94662, 25.7856, 13.6192, -20.4591, 16.1286 ) -shape_range = Vector2( -1, -1 ) -trigger = false - -[node name="sprite" type="Sprite" parent="."] - -texture = ExtResource( 2 ) - -[node name="explosion" parent="." instance=ExtResource( 3 )] - -transform/rot = -91.1436 -config/explosiveness = 0.1 -params/gravity_strength = 9.8 - -[node name="anim" type="AnimationPlayer" parent="."] - -playback/process_mode = 1 -playback/default_blend_time = 0.0 -root/root = NodePath("..") -anims/explode = SubResource( 2 ) -playback/active = true -playback/speed = 1.0 -blend_times = [ ] -autoplay = "" - -[node name="visibility" type="VisibilityNotifier2D" parent="."] - -rect = Rect2( -10, -10, 20, 20 ) - -[node name="sfx" type="SamplePlayer2D" parent="."] - -params/volume_db = 0.0 -params/pitch_scale = 1.0 -params/attenuation/min_distance = 1.0 -params/attenuation/max_distance = 2048.0 -params/attenuation/distance_exp = 1.0 -config/polyphony = 1 -config/samples = SubResource( 3 ) -config/pitch_random = 0.0 - -[node name="shoot_from" type="Position2D" parent="."] - -transform/pos = Vector2( -84.6027, 0.358482 ) - -[connection signal="enter_screen" from="visibility" to="." method="_on_visibility_enter_screen"] - -[connection signal="exit_screen" from="visibility" to="." method="_on_visibility_exit_screen"] - - diff --git a/demos/2d/space_shooter/enemy_shot.gd b/demos/2d/space_shooter/enemy_shot.gd deleted file mode 100644 index 6c782b69f1..0000000000 --- a/demos/2d/space_shooter/enemy_shot.gd +++ /dev/null @@ -1,31 +0,0 @@ - -extends Area2D - -# Member variables -const SPEED = -800 - -var hit = false - - -func _process(delta): - translate(Vector2(delta*SPEED, 0)) - - -func _ready(): - set_process(true) - - -func is_enemy(): - return true - - -func _hit_something(): - if (hit): - return - hit = true - set_process(false) - get_node("anim").play("splash") - - -func _on_visibility_exit_screen(): - queue_free() diff --git a/demos/2d/space_shooter/enemy_shot.png b/demos/2d/space_shooter/enemy_shot.png deleted file mode 100644 index 04287211a9..0000000000 Binary files a/demos/2d/space_shooter/enemy_shot.png and /dev/null differ diff --git a/demos/2d/space_shooter/enemy_shot.tscn b/demos/2d/space_shooter/enemy_shot.tscn deleted file mode 100644 index da6ed6f806..0000000000 --- a/demos/2d/space_shooter/enemy_shot.tscn +++ /dev/null @@ -1,99 +0,0 @@ -[gd_scene load_steps=6 format=1] - -[ext_resource path="res://enemy_shot.gd" type="Script" id=1] -[ext_resource path="res://enemy_shot.png" type="Texture" id=2] - -[sub_resource type="RectangleShape2D" id=1] - -custom_solver_bias = 0.0 -extents = Vector2( 10, 4 ) - -[sub_resource type="ColorRamp" id=2] - -offsets = FloatArray( 0, 1 ) -colors = ColorArray( 1, 0.0491249, 0.0113636, 1, 1, 1, 1, 0 ) - -[sub_resource type="Animation" id=3] - -length = 1.0 -loop = false -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath("hit_splash:config/emitting") -tracks/0/interp = 1 -tracks/0/keys = { "cont":false, "times":FloatArray( 0, 0.1 ), "transitions":FloatArray( 1, 1 ), "values":[ true, false ] } -tracks/1/type = "method" -tracks/1/path = NodePath(".") -tracks/1/interp = 1 -tracks/1/keys = { "times":FloatArray( 0.9 ), "transitions":FloatArray( 1 ), "values":[ { "args":[ ], "method":"queue_free" } ] } -tracks/2/type = "value" -tracks/2/path = NodePath("sprite:visibility/visible") -tracks/2/interp = 1 -tracks/2/keys = { "cont":false, "times":FloatArray( 0 ), "transitions":FloatArray( 1 ), "values":[ false ] } - -[node name="enemy_shot" type="Area2D"] - -input/pickable = true -shapes/0/shape = SubResource( 1 ) -shapes/0/transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -shapes/0/trigger = false -gravity_vec = Vector2( 0, 1 ) -gravity = 98.0 -linear_damp = 0.1 -angular_damp = 1.0 -script/script = ExtResource( 1 ) - -[node name="visibility" type="VisibilityNotifier2D" parent="."] - -transform/pos = Vector2( 1.8353, -0.0742126 ) -transform/scale = Vector2( 1.54149, 0.770745 ) -rect = Rect2( -10, -10, 20, 20 ) - -[node name="sprite" type="Sprite" parent="."] - -texture = ExtResource( 2 ) - -[node name="collision" type="CollisionShape2D" parent="."] - -shape = SubResource( 1 ) -trigger = false -_update_shape_index = -1 - -[node name="hit_splash" type="Particles2D" parent="."] - -config/amount = 32 -config/lifetime = 0.5 -config/emitting = false -config/explosiveness = 0.1 -params/direction = 0.0 -params/spread = 180.0 -params/linear_velocity = 50.0 -params/spin_velocity = 0.0 -params/orbit_velocity = 0.0 -params/gravity_direction = 0.0 -params/gravity_strength = 0.0 -params/radial_accel = 0.0 -params/tangential_accel = 0.0 -params/damping = 0.0 -params/initial_angle = 0.0 -params/initial_size = 3.0 -params/final_size = 3.0 -params/hue_variation = 0.0 -params/anim_speed_scale = 1.0 -params/anim_initial_pos = 0.0 -color/color_ramp = SubResource( 2 ) - -[node name="anim" type="AnimationPlayer" parent="."] - -playback/process_mode = 1 -playback/default_blend_time = 0.0 -root/root = NodePath("..") -anims/splash = SubResource( 3 ) -playback/active = true -playback/speed = 1.0 -blend_times = [ ] -autoplay = "" - -[connection signal="exit_screen" from="visibility" to="." method="_on_visibility_exit_screen"] - - diff --git a/demos/2d/space_shooter/engine.cfg b/demos/2d/space_shooter/engine.cfg deleted file mode 100644 index 8563bd8aa9..0000000000 --- a/demos/2d/space_shooter/engine.cfg +++ /dev/null @@ -1,22 +0,0 @@ -[application] - -name="Simple Shooter" -main_scene="res://main_menu.tscn" -icon="res://icon.png" - -[autoload] - -game_state="res://game_state.gd" - -[display] - -width=1024 -height=600 - -[input] - -move_up=[key(Up)] -move_down=[key(Down)] -move_left=[key(Left)] -move_right=[key(Right)] -shoot=[key(Space)] diff --git a/demos/2d/space_shooter/explosion.tscn b/demos/2d/space_shooter/explosion.tscn deleted file mode 100644 index 7c8f94be7d..0000000000 --- a/demos/2d/space_shooter/explosion.tscn +++ /dev/null @@ -1,37 +0,0 @@ -[gd_scene load_steps=3 format=1] - -[ext_resource path="res://fire.png" type="Texture" id=1] - -[sub_resource type="ColorRamp" id=1] - -offsets = FloatArray( 0, 0.364725, 0.77494, 1 ) -colors = ColorArray( 1, 1, 1, 1, 1, 0, 0, 1, 0.184473, 0.181601, 0.181345, 1, 1, 1, 1, 0 ) - -[node name="explosion" type="Particles2D"] - -transform/pos = Vector2( 0.918983, -2.11041 ) -transform/rot = -91.1436 -config/amount = 32 -config/lifetime = 0.5 -config/emitting = false -config/explosiveness = 0.1 -config/texture = ExtResource( 1 ) -params/direction = 0.0 -params/spread = 180.0 -params/linear_velocity = 100.0 -params/spin_velocity = 0.0 -params/orbit_velocity = 0.0 -params/gravity_direction = 0.0 -params/gravity_strength = 9.8 -params/radial_accel = 0.0 -params/tangential_accel = 0.0 -params/damping = 0.0 -params/initial_angle = 0.0 -params/initial_size = 3.0 -params/final_size = 1.0 -params/hue_variation = 0.0 -params/anim_speed_scale = 1.0 -params/anim_initial_pos = 0.0 -color/color_ramp = SubResource( 1 ) - - diff --git a/demos/2d/space_shooter/fire.png b/demos/2d/space_shooter/fire.png deleted file mode 100644 index 1c68c36213..0000000000 Binary files a/demos/2d/space_shooter/fire.png and /dev/null differ diff --git a/demos/2d/space_shooter/game_state.gd b/demos/2d/space_shooter/game_state.gd deleted file mode 100644 index 0aa5e1f42b..0000000000 --- a/demos/2d/space_shooter/game_state.gd +++ /dev/null @@ -1,22 +0,0 @@ - -extends Node - -# Member variables -var points = 0 -var max_points = 0 - - -func _ready(): - var f = File.new() - # Load high score - if (f.open("user://highscore", File.READ) == OK): - max_points = f.get_var() - - -func game_over(): - if (points > max_points): - max_points = points - # Save high score - var f = File.new() - f.open("user://highscore", File.WRITE) - f.store_var(max_points) diff --git a/demos/2d/space_shooter/icon.png b/demos/2d/space_shooter/icon.png deleted file mode 100644 index 1df2bf5d9d..0000000000 Binary files a/demos/2d/space_shooter/icon.png and /dev/null differ diff --git a/demos/2d/space_shooter/level.tscn b/demos/2d/space_shooter/level.tscn deleted file mode 100644 index 840d66bd5a..0000000000 --- a/demos/2d/space_shooter/level.tscn +++ /dev/null @@ -1,354 +0,0 @@ -[gd_scene load_steps=7 format=1] - -[ext_resource path="res://tileset.tres" type="TileSet" id=1] -[ext_resource path="res://ship.tscn" type="PackedScene" id=2] -[ext_resource path="res://asteroid.tscn" type="PackedScene" id=3] -[ext_resource path="res://enemy1.tscn" type="PackedScene" id=4] -[ext_resource path="res://enemy2.tscn" type="PackedScene" id=5] -[ext_resource path="res://parallax.tscn" type="PackedScene" id=6] - -[node name="Node2D" type="Node2D"] - -[node name="TileMap" type="TileMap" parent="."] - -mode = 0 -tile_set = ExtResource( 1 ) -cell/size = Vector2( 32, 32 ) -cell/quadrant_size = 16 -cell/custom_transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -cell/half_offset = 2 -cell/tile_origin = 0 -cell/y_sort = false -collision/use_kinematic = false -collision/friction = 1.0 -collision/bounce = 0.0 -collision/layers = 1 -collision/mask = 1 -occluder/light_mask = 1 -tile_data = IntArray( 16, 0, 17, 0, 18, 0, 19, 0, 20, 0, 21, 0, 22, 0, 23, 0, 24, 0, 25, 0, 26, 0, 27, 0, 28, 0, 29, 0, 30, 0, 31, 0, 32, 0, 33, 0, 34, 0, 35, 0, 36, 0, 37, 0, 38, 0, 39, 0, 63, 0, 64, 0, 99, 0, 100, 0, 101, 0, 102, 0, 103, 0, 104, 0, 105, 0, 106, 0, 107, 0, 108, 0, 109, 0, 110, 0, 111, 0, 112, 0, 113, 0, 114, 0, 115, 0, 116, 0, 117, 0, 118, 0, 119, 0, 120, 0, 121, 0, 122, 0, 123, 0, 124, 0, 125, 0, 126, 0, 127, 0, 128, 0, 145, 0, 184, 0, 65556, 0, 65557, 0, 65558, 0, 65559, 0, 65560, 0, 65561, 0, 65562, 0, 65563, 0, 65564, 0, 65565, 0, 65566, 0, 65567, 0, 65568, 0, 65569, 0, 65570, 0, 65571, 0, 65572, 0, 65573, 0, 65574, 0, 65575, 0, 65599, 0, 65600, 0, 65637, 0, 65638, 0, 65639, 0, 65640, 0, 65641, 0, 65642, 0, 65643, 0, 65644, 0, 65645, 0, 65646, 0, 65647, 0, 65648, 0, 65649, 0, 65650, 0, 65651, 0, 65652, 0, 65653, 0, 65654, 0, 65655, 0, 65656, 0, 65657, 0, 65658, 0, 65659, 0, 65660, 0, 65661, 0, 65662, 0, 65663, 0, 65664, 0, 65681, 0, 65720, 0, 131094, 0, 131095, 0, 131096, 0, 131097, 0, 131098, 0, 131099, 0, 131100, 0, 131101, 0, 131102, 0, 131103, 0, 131104, 0, 131105, 0, 131106, 0, 131107, 0, 131108, 0, 131109, 0, 131135, 0, 131136, 0, 131137, 0, 131176, 0, 131177, 0, 131178, 0, 131179, 0, 131180, 0, 131181, 0, 131182, 0, 131183, 0, 131184, 0, 131185, 0, 131186, 0, 131187, 0, 131188, 0, 131189, 0, 131190, 0, 131191, 0, 131192, 0, 131193, 0, 131194, 0, 131195, 0, 131196, 0, 131197, 0, 131198, 0, 131199, 0, 131217, 0, 131256, 0, 196631, 0, 196632, 0, 196633, 0, 196634, 0, 196635, 0, 196636, 0, 196637, 0, 196638, 0, 196639, 0, 196640, 0, 196641, 0, 196642, 0, 196671, 0, 196672, 0, 196673, 0, 196716, 0, 196717, 0, 196718, 0, 196719, 0, 196720, 0, 196721, 0, 196722, 0, 196723, 0, 196724, 0, 196725, 0, 196726, 0, 196727, 0, 196728, 0, 196729, 0, 196730, 0, 196753, 0, 196792, 0, 262169, 0, 262170, 0, 262171, 0, 262172, 0, 262173, 0, 262174, 0, 262175, 0, 262207, 0, 262208, 0, 262209, 0, 262256, 0, 262257, 0, 262258, 0, 262259, 0, 262260, 0, 262261, 0, 262262, 0, 262263, 0, 262289, 0, 262328, 0, 327707, 0, 327708, 0, 327743, 0, 327744, 0, 327825, 0, 327826, 0, 327827, 0, 327828, 0, 327829, 0, 327830, 0, 327831, 0, 327832, 0, 327833, 0, 327834, 0, 327835, 0, 327836, 0, 327845, 0, 327846, 0, 327847, 0, 327848, 0, 327849, 0, 327850, 0, 327851, 0, 327852, 0, 327853, 0, 327854, 0, 327855, 0, 327856, 0, 327857, 0, 327864, 0, 327911, 0, 327912, 0, 328010, 0, 328011, 0, 328012, 0, 328013, 0, 328014, 0, 393372, 0, 393393, 0, 393400, 0, 393445, 0, 393446, 0, 393447, 0, 393448, 0, 393548, 0, 393549, 0, 393550, 0, 458908, 0, 458929, 0, 458936, 0, 458981, 0, 458982, 0, 458983, 0, 524444, 0, 524465, 0, 524472, 0, 524517, 0, 524518, 0, 589980, 0, 590001, 0, 590008, 0, 655516, 0, 655521, 0, 655522, 0, 655523, 0, 655524, 0, 655525, 0, 655526, 0, 655537, 0, 655544, 0, 655646, 0, 721041, 0, 721042, 0, 721043, 0, 721044, 0, 721045, 0, 721046, 0, 721052, 0, 721062, 0, 721073, 0, 721080, 0, 721181, 0, 721182, 0, 721183, 0, 721184, 0, 786577, 0, 786588, 0, 786598, 0, 786616, 0, 786717, 0, 786718, 0, 786719, 0, 786720, 0, 852113, 0, 852124, 0, 852134, 0, 852152, 0, 852253, 0, 852254, 0, 852255, 0, 917573, 0, 917574, 0, 917575, 0, 917576, 0, 917577, 0, 917578, 0, 917579, 0, 917580, 0, 917581, 0, 917582, 0, 917583, 0, 917584, 0, 917585, 0, 917649, 0, 917660, 0, 917670, 0, 917688, 0, 983106, 0, 983107, 0, 983108, 0, 983109, 0, 983110, 0, 983111, 0, 983112, 0, 983113, 0, 983114, 0, 983115, 0, 983116, 0, 983117, 0, 983118, 0, 983119, 0, 983120, 0, 983121, 0, 983122, 0, 983185, 0, 983206, 0, 983224, 0, 1048640, 0, 1048641, 0, 1048642, 0, 1048643, 0, 1048644, 0, 1048645, 0, 1048646, 0, 1048647, 0, 1048648, 0, 1048649, 0, 1048650, 0, 1048651, 0, 1048652, 0, 1048653, 0, 1048654, 0, 1048655, 0, 1048656, 0, 1048657, 0, 1048658, 0, 1048659, 0, 1048721, 0, 1048742, 0, 1048826, 0, 1048828, 0, 1114175, 0, 1114176, 0, 1114177, 0, 1114178, 0, 1114179, 0, 1114180, 0, 1114181, 0, 1114182, 0, 1114183, 0, 1114184, 0, 1114185, 0, 1114186, 0, 1114187, 0, 1114188, 0, 1114189, 0, 1114190, 0, 1114191, 0, 1114192, 0, 1114193, 0, 1114194, 0, 1114195, 0, 1114196, 0, 1114197, 0, 1114198, 0, 1114257, 0, 1114278, 0, 1114360, 0, 1114361, 0, 1114362, 0, 1114363, 0, 1114365, 0, 1114480, 0, 1114481, 0, 1179707, 0, 1179708, 0, 1179709, 0, 1179710, 0, 1179711, 0, 1179712, 0, 1179713, 0, 1179714, 0, 1179715, 0, 1179716, 0, 1179717, 0, 1179718, 0, 1179719, 0, 1179720, 0, 1179721, 0, 1179722, 0, 1179723, 0, 1179724, 0, 1179725, 0, 1179726, 0, 1179727, 0, 1179728, 0, 1179729, 0, 1179730, 0, 1179731, 0, 1179732, 0, 1179733, 0, 1179734, 0, 1179735, 0, 1179736, 0, 1179737, 0, 1179738, 0, 1179739, 0, 1179740, 0, 1179741, 0, 1179793, 0, 1179814, 0, 1179896, 0, 1179898, 0, 1179899, 0, 1179900, 0, 1179901, 0, 1180015, 0, 1180016, 0, 1180017, 0, 1180018, 0, 1180019, 0, 1245244, 0, 1245245, 0, 1245246, 0, 1245247, 0, 1245248, 0, 1245249, 0, 1245250, 0, 1245251, 0, 1245252, 0, 1245253, 0, 1245254, 0, 1245255, 0, 1245256, 0, 1245257, 0, 1245258, 0, 1245259, 0, 1245260, 0, 1245261, 0, 1245262, 0, 1245263, 0, 1245264, 0, 1245265, 0, 1245266, 0, 1245267, 0, 1245268, 0, 1245269, 0, 1245270, 0, 1245271, 0, 1245272, 0, 1245273, 0, 1245274, 0, 1245275, 0, 1245276, 0, 1245277, 0, 1245329, 0, 1245350, 0, 1245432, 0, 1245433, 0, 1245434, 0, 1245435, 0, 1245480, 0, 1245481, 0, 1245482, 0, 1245551, 0, 1245552, 0, 1245553, 0, 1245554, 0, 1310886, 0, 1310905, 0, 1311015, 0, 1311016, 0, 1311017, 0, 1311018, 0 ) - -[node name="rail" parent="." instance=ExtResource( 2 )] - -[node name="enemies" type="Node2D" parent="."] - -[node name="asteroid" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 1797.52, 105.736 ) -linear_damp = 0.1 - -[node name="asteroid1" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 1666.61, 304.621 ) -linear_damp = 0.1 - -[node name="asteroid2" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 1988.85, 443.086 ) -linear_damp = 0.1 - -[node name="asteroid3" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 2595.58, 103.219 ) -linear_damp = 0.1 - -[node name="asteroid4" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 3229.99, 299.586 ) -linear_damp = 0.1 - -[node name="asteroid5" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 3592.52, 541.269 ) -linear_damp = 0.1 - -[node name="asteroid6" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 4571.84, 216.508 ) -linear_damp = 0.1 - -[node name="asteroid7" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 4571.84, 284.481 ) -linear_damp = 0.1 - -[node name="asteroid8" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 4571.84, 360.007 ) -linear_damp = 0.1 - -[node name="asteroid9" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 5140.8, 108.254 ) -linear_damp = 0.1 - -[node name="asteroid10" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 5168.5, 475.814 ) -linear_damp = 0.1 - -[node name="asteroid11" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 5767.67, 113.289 ) -linear_damp = 0.1 - -[node name="asteroid12" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 6107.53, 480.849 ) -linear_damp = 0.1 - -[node name="asteroid13" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 6364.32, 105.736 ) -linear_damp = 0.1 - -[node name="asteroid14" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 6731.88, 573.997 ) -linear_damp = 0.1 - -[node name="asteroid15" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7033.99, 166.157 ) -linear_damp = 0.1 - -[node name="asteroid16" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 6424.74, 352.454 ) -linear_damp = 0.1 - -[node name="asteroid17" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7263.08, 80.5608 ) -linear_damp = 0.1 - -[node name="asteroid18" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7177.49, 541.269 ) -linear_damp = 0.1 - -[node name="asteroid19" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7066.71, 344.902 ) -linear_damp = 0.1 - -[node name="asteroid20" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7655.82, 118.324 ) -linear_damp = 0.1 - -[node name="asteroid21" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7540.01, 324.762 ) -linear_damp = 0.1 - -[node name="asteroid22" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7764.07, 566.445 ) -linear_damp = 0.1 - -[node name="asteroid23" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 7872.33, 216.508 ) -linear_damp = 0.1 - -[node name="asteroid24" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 8458.91, 95.666 ) -linear_damp = 0.1 - -[node name="asteroid25" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 8786.19, 231.613 ) -linear_damp = 0.1 - -[node name="asteroid26" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 8599.89, 551.339 ) -linear_damp = 0.1 - -[node name="asteroid27" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 8353.17, 289.516 ) -linear_damp = 0.1 - -[node name="asteroid28" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 8995.14, 95.6658 ) -linear_damp = 0.1 - -[node name="asteroid29" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 9294.73, 579.032 ) -linear_damp = 0.1 - -[node name="asteroid30" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 9392.91, 140.981 ) -linear_damp = 0.1 - -[node name="asteroid31" parent="enemies" instance=ExtResource( 3 )] - -transform/pos = Vector2( 9644.67, 281.963 ) -linear_damp = 0.1 - -[node name="enemy1" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 2920.34, 365.042 ) - -[node name="enemy2" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 3894.62, 506.024 ) - -[node name="enemy3" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 4325.12, 302.104 ) - -[node name="enemy4" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 4753.1, 506.024 ) - -[node name="enemy5" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 5158.43, 211.473 ) - -[node name="enemy6" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 5490.74, 349.937 ) - -[node name="enemy7" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 5765.15, 546.305 ) - -[node name="enemy8" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 6142.78, 244.201 ) - -[node name="enemy9" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 6701.67, 221.543 ) - -[node name="enemy10" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 6701.67, 352.455 ) - -[node name="enemy11" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 6706.71, 500.989 ) - -[node name="enemy12" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 6711.74, 566.445 ) - -[node name="enemy13" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 7157.35, 332.314 ) - -[node name="enemy14" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 7421.69, 511.059 ) - -[node name="enemy15" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 7887.43, 239.166 ) - -[node name="enemy16" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 8463.95, 382.665 ) - -[node name="enemy17" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 9065.64, 244.201 ) - -[node name="enemy18" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 8967.46, 566.445 ) - -[node name="enemy19" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 9483.55, 422.946 ) - -[node name="enemy20" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 9687.47, 234.131 ) - -[node name="enemy21" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 9815.86, 579.033 ) - -[node name="enemy22" parent="enemies" instance=ExtResource( 4 )] - -transform/pos = Vector2( 9815.86, 579.033 ) - -[node name="enemy2 2" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 4759.97, 278.527 ) -linear_damp = 0.1 - -[node name="enemy23" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 6277.15, 559.36 ) -linear_damp = 0.1 - -[node name="enemy24" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 7136.77, 100.438 ) -linear_damp = 0.1 - -[node name="enemy25" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 7766.93, 370.996 ) -linear_damp = 0.1 - -[node name="enemy26" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 7890.23, 309.35 ) -linear_damp = 0.1 - -[node name="enemy27" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 8006.67, 237.43 ) -linear_damp = 0.1 - -[node name="enemy28" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 8664.23, 257.978 ) -linear_damp = 0.1 - -[node name="enemy29" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 8660.8, 357.297 ) -linear_damp = 0.1 - -[node name="enemy30" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 8657.38, 453.191 ) -linear_damp = 0.1 - -[node name="enemy31" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 9475.9, 189.483 ) -linear_damp = 0.1 - -[node name="enemy32" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 9564.95, 234.005 ) -linear_damp = 0.1 - -[node name="enemy33" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 9674.54, 281.952 ) -linear_damp = 0.1 - -[node name="enemy34" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 9575.22, 391.545 ) -linear_damp = 0.1 - -[node name="enemy35" parent="enemies" instance=ExtResource( 5 )] - -transform/pos = Vector2( 9458.78, 446.342 ) -linear_damp = 0.1 - -[node name="parallax" parent="." instance=ExtResource( 6 )] - - diff --git a/demos/2d/space_shooter/main_menu.gd b/demos/2d/space_shooter/main_menu.gd deleted file mode 100644 index 0c7e0de542..0000000000 --- a/demos/2d/space_shooter/main_menu.gd +++ /dev/null @@ -1,11 +0,0 @@ - -extends Control - - -func _ready(): - get_node("score").set_text("HIGH SCORE: " + str(get_node("/root/game_state").max_points)) - - -func _on_play_pressed(): - get_node("/root/game_state").points = 0 - get_tree().change_scene("res://level.tscn") diff --git a/demos/2d/space_shooter/main_menu.tscn b/demos/2d/space_shooter/main_menu.tscn deleted file mode 100644 index e51791611d..0000000000 --- a/demos/2d/space_shooter/main_menu.tscn +++ /dev/null @@ -1,64 +0,0 @@ -[gd_scene load_steps=2 format=1] - -[ext_resource path="res://main_menu.gd" type="Script" id=1] - -[node name="main_screen" type="Control"] - -anchor/right = 1 -anchor/bottom = 1 -focus/ignore_mouse = false -focus/stop_mouse = true -size_flags/horizontal = 2 -size_flags/vertical = 2 -margin/left = 0.0 -margin/top = 0.0 -margin/right = 0.0 -margin/bottom = 0.0 -script/script = ExtResource( 1 ) - -[node name="title" type="Label" parent="."] - -focus/ignore_mouse = true -focus/stop_mouse = true -size_flags/horizontal = 2 -margin/left = 405.0 -margin/top = 86.0 -margin/right = 547.0 -margin/bottom = 99.0 -text = "S P A C E S H O O T E R" -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - -[node name="score" type="Label" parent="."] - -focus/ignore_mouse = true -focus/stop_mouse = true -size_flags/horizontal = 2 -margin/left = 349.0 -margin/top = 204.0 -margin/right = 585.0 -margin/bottom = 218.0 -text = "HIGH SCORE:" -align = 1 -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - -[node name="play" type="Button" parent="."] - -focus/ignore_mouse = false -focus/stop_mouse = true -size_flags/horizontal = 2 -size_flags/vertical = 2 -margin/left = 412.0 -margin/top = 390.0 -margin/right = 535.0 -margin/bottom = 442.0 -toggle_mode = false -text = "PLAY" -flat = false - -[connection signal="pressed" from="play" to="." method="_on_play_pressed"] - - diff --git a/demos/2d/space_shooter/meteorite.png b/demos/2d/space_shooter/meteorite.png deleted file mode 100644 index 92fb4387df..0000000000 Binary files a/demos/2d/space_shooter/meteorite.png and /dev/null differ diff --git a/demos/2d/space_shooter/parallax.tscn b/demos/2d/space_shooter/parallax.tscn deleted file mode 100644 index 0cbd0f5b19..0000000000 --- a/demos/2d/space_shooter/parallax.tscn +++ /dev/null @@ -1,201 +0,0 @@ -[gd_scene load_steps=4 format=1] - -[ext_resource path="res://bg_gradient.png" type="Texture" id=1] -[ext_resource path="res://small_star.png" type="Texture" id=2] -[ext_resource path="res://big_star.png" type="Texture" id=3] - -[node name="parallax" type="ParallaxBackground"] - -layer = -1 -offset = Vector2( 0, 0 ) -rotation = 0.0 -scale = Vector2( 1, 1 ) -scroll/offset = Vector2( 0, 0 ) -scroll/base_offset = Vector2( 0, 0 ) -scroll/base_scale = Vector2( 1, 1 ) -scroll/limit_begin = Vector2( 0, 0 ) -scroll/limit_end = Vector2( 0, 0 ) -scroll/ignore_camera_zoom = true - -[node name="bg_layer" type="ParallaxLayer" parent="."] - -motion/scale = Vector2( 0.2, 1 ) -motion/mirroring = Vector2( 1024, 0 ) - -[node name="gradient" type="Sprite" parent="bg_layer"] - -transform/scale = Vector2( 128, 1 ) -texture = ExtResource( 1 ) -centered = false - -[node name="Sprite" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 73.6643, 65.0701 ) -texture = ExtResource( 2 ) - -[node name="Sprite1" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 127.685, 206.26 ) -texture = ExtResource( 2 ) - -[node name="Sprite2" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 60.1591, 255.369 ) -texture = ExtResource( 2 ) - -[node name="Sprite3" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 252.914, 142.418 ) -texture = ExtResource( 2 ) - -[node name="Sprite4" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 241.864, 335.172 ) -texture = ExtResource( 2 ) - -[node name="Sprite5" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 127.685, 455.491 ) -texture = ExtResource( 2 ) - -[node name="Sprite6" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 289.746, 547.571 ) -texture = ExtResource( 2 ) - -[node name="Sprite7" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 56.4759, 559.848 ) -texture = ExtResource( 2 ) - -[node name="Sprite8" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 487.412, 166.972 ) -texture = ExtResource( 2 ) - -[node name="Sprite9" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 358.499, 77.3474 ) -texture = ExtResource( 2 ) - -[node name="Sprite10" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 647.018, 71.2088 ) -texture = ExtResource( 2 ) - -[node name="Sprite11" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 592.997, 270.102 ) -texture = ExtResource( 2 ) - -[node name="Sprite12" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 868.011, 252.914 ) -texture = ExtResource( 2 ) - -[node name="Sprite13" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 869.238, 93.308 ) -texture = ExtResource( 2 ) - -[node name="Sprite14" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 965.002, 95.7635 ) -texture = ExtResource( 2 ) - -[node name="Sprite15" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 968.685, 559.848 ) -texture = ExtResource( 2 ) - -[node name="Sprite16" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 815.218, 470.224 ) -texture = ExtResource( 2 ) - -[node name="Sprite17" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 475.134, 530.383 ) -texture = ExtResource( 2 ) - -[node name="Sprite18" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 550.026, 421.114 ) -texture = ExtResource( 2 ) - -[node name="Sprite19" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 696.127, 574.581 ) -texture = ExtResource( 2 ) - -[node name="Sprite20" type="Sprite" parent="bg_layer"] - -transform/pos = Vector2( 990.784, 423.569 ) -texture = ExtResource( 2 ) - -[node name="bg_layer2" type="ParallaxLayer" parent="."] - -motion/scale = Vector2( 0.5, 1 ) -motion/mirroring = Vector2( 1024, 0 ) - -[node name="Sprite" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 88, 114 ) -texture = ExtResource( 3 ) - -[node name="Sprite1" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 349, 254 ) -texture = ExtResource( 3 ) - -[node name="Sprite2" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 472, 80 ) -texture = ExtResource( 3 ) - -[node name="Sprite3" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 803, 107 ) -texture = ExtResource( 3 ) - -[node name="Sprite4" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 93, 363 ) -texture = ExtResource( 3 ) - -[node name="Sprite5" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 891, 519 ) -texture = ExtResource( 3 ) - -[node name="Sprite6" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 934, 338 ) -texture = ExtResource( 3 ) - -[node name="Sprite7" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 665, 332 ) -texture = ExtResource( 3 ) - -[node name="Sprite8" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 218, 423 ) -texture = ExtResource( 3 ) - -[node name="Sprite9" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 564, 568 ) -texture = ExtResource( 3 ) - -[node name="Sprite10" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 753, 466 ) -texture = ExtResource( 3 ) - -[node name="Sprite11" type="Sprite" parent="bg_layer2"] - -transform/pos = Vector2( 77.9999, 570 ) -texture = ExtResource( 3 ) - - diff --git a/demos/2d/space_shooter/rail.gd b/demos/2d/space_shooter/rail.gd deleted file mode 100644 index a9559806cb..0000000000 --- a/demos/2d/space_shooter/rail.gd +++ /dev/null @@ -1,19 +0,0 @@ - -extends Node2D - -# Member variables -const SPEED = 200 -var offset = 0 - - -func stop(): - set_fixed_process(false) - - -func _fixed_process(delta): - offset += delta*SPEED - set_pos(Vector2(offset, 0)) - - -func _ready(): - set_fixed_process(true) diff --git a/demos/2d/space_shooter/ship.gd b/demos/2d/space_shooter/ship.gd deleted file mode 100644 index d3a4cd335d..0000000000 --- a/demos/2d/space_shooter/ship.gd +++ /dev/null @@ -1,81 +0,0 @@ - -extends Area2D - -# Member variables -const SPEED = 200 - -var screen_size -var prev_shooting = false -var killed = false - - -func _fixed_process(delta): - var motion = Vector2() - if Input.is_action_pressed("move_up"): - motion += Vector2(0, -1) - if Input.is_action_pressed("move_down"): - motion += Vector2(0, 1) - if Input.is_action_pressed("move_left"): - motion += Vector2(-1, 0) - if Input.is_action_pressed("move_right"): - motion += Vector2(1, 0) - var shooting = Input.is_action_pressed("shoot") - - var pos = get_pos() - - pos += motion*delta*SPEED - if (pos.x < 0): - pos.x = 0 - if (pos.x > screen_size.x): - pos.x = screen_size.x - if (pos.y < 0): - pos.y = 0 - if (pos.y > screen_size.y): - pos.y = screen_size.y - - set_pos(pos) - - if (shooting and not prev_shooting): - # Just pressed - var shot = preload("res://shot.tscn").instance() - # Use the Position2D as reference - shot.set_pos(get_node("shootfrom").get_global_pos()) - # Put it two parents above, so it is not moved by us - get_node("../..").add_child(shot) - # Play sound - get_node("sfx").play("shoot") - - prev_shooting = shooting - - # Update points counter - get_node("../hud/score_points").set_text(str(get_node("/root/game_state").points)) - - -func _ready(): - screen_size = get_viewport().get_rect().size - set_fixed_process(true) - - -func _hit_something(): - if (killed): - return - killed = true - get_node("anim").play("explode") - get_node("sfx").play("sound_explode") - get_node("../hud/game_over").show() - get_node("/root/game_state").game_over() - get_parent().stop() - set_process(false) - - -func _on_ship_body_enter(body): - _hit_something() - - -func _on_ship_area_enter(area): - if (area.has_method("is_enemy") and area.is_enemy()): - _hit_something() - - -func _on_back_to_menu_pressed(): - get_tree().change_scene("res://main_menu.tscn") diff --git a/demos/2d/space_shooter/ship.png b/demos/2d/space_shooter/ship.png deleted file mode 100644 index a36b833903..0000000000 Binary files a/demos/2d/space_shooter/ship.png and /dev/null differ diff --git a/demos/2d/space_shooter/ship.tscn b/demos/2d/space_shooter/ship.tscn deleted file mode 100644 index be6bf6b82e..0000000000 --- a/demos/2d/space_shooter/ship.tscn +++ /dev/null @@ -1,229 +0,0 @@ -[gd_scene load_steps=12 format=1] - -[ext_resource path="res://rail.gd" type="Script" id=1] -[ext_resource path="res://ship.gd" type="Script" id=2] -[ext_resource path="res://ship.png" type="Texture" id=3] -[ext_resource path="res://fire.png" type="Texture" id=4] -[ext_resource path="res://explosion.tscn" type="PackedScene" id=5] -[ext_resource path="res://sound_shoot.wav" type="Sample" id=6] -[ext_resource path="res://sound_explode.wav" type="Sample" id=7] - -[sub_resource type="ConvexPolygonShape2D" id=1] - -custom_solver_bias = 0.0 -points = Vector2Array( 25.9104, 1.3603, -20.5637, 14.8656, -20.5637, -15.3227 ) - -[sub_resource type="ColorRamp" id=2] - -offsets = FloatArray( 0, 0.474062, 0.653631, 1 ) -colors = ColorArray( 0.154794, 0.413313, 0.991004, 1, 0.555474, 0.971578, 0, 1, 0.82934, 0.989088, 0.616085, 0.383915, 1, 1, 1, 0 ) - -[sub_resource type="Animation" id=3] - -length = 1.0 -loop = false -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath("sprite:visibility/visible") -tracks/0/interp = 1 -tracks/0/keys = { "cont":false, "times":FloatArray( 0, 0.1 ), "transitions":FloatArray( 1, 1 ), "values":[ true, false ] } -tracks/1/type = "value" -tracks/1/path = NodePath("thruster:config/emitting") -tracks/1/interp = 1 -tracks/1/keys = { "cont":false, "times":FloatArray( 0 ), "transitions":FloatArray( 1 ), "values":[ false ] } -tracks/2/type = "value" -tracks/2/path = NodePath("explosion:config/emitting") -tracks/2/interp = 1 -tracks/2/keys = { "cont":false, "times":FloatArray( 0, 0.1 ), "transitions":FloatArray( 1, 1 ), "values":[ true, false ] } - -[sub_resource type="SampleLibrary" id=4] - -samples/shoot = { "db":0.0, "pitch":1.0, "sample":ExtResource( 6 ) } -samples/sound_explode = { "db":0.0, "pitch":1.0, "sample":ExtResource( 7 ) } - -[node name="rail" type="Node2D"] - -script/script = ExtResource( 1 ) - -[node name="ship" type="Area2D" parent="."] - -transform/pos = Vector2( 253.607, 282.275 ) -input/pickable = true -shapes/0/shape = SubResource( 1 ) -shapes/0/transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -shapes/0/trigger = false -gravity_vec = Vector2( 0, 1 ) -gravity = 98.0 -linear_damp = 0.1 -angular_damp = 1.0 -script/script = ExtResource( 2 ) - -[node name="sprite" type="Sprite" parent="ship"] - -texture = ExtResource( 3 ) - -[node name="CollisionPolygon2D" type="CollisionPolygon2D" parent="ship"] - -build_mode = 0 -polygon = Vector2Array( -20.5637, -15.3227, 25.9104, 1.3603, -20.5637, 14.8656 ) -shape_range = Vector2( -1, -1 ) -trigger = false - -[node name="thruster" type="Particles2D" parent="ship"] - -visibility/blend_mode = 1 -transform/pos = Vector2( -26.528, -0.358481 ) -transform/rot = -91.1436 -config/amount = 32 -config/lifetime = 2.0 -config/time_scale = 5.0 -config/emitting = false -config/local_space = false -config/texture = ExtResource( 4 ) -params/direction = 0.0 -params/spread = 10.0 -params/linear_velocity = 20.0 -params/spin_velocity = 0.0 -params/orbit_velocity = 0.0 -params/gravity_direction = 0.0 -params/gravity_strength = 0.0 -params/radial_accel = 0.0 -params/tangential_accel = 0.0 -params/damping = 0.0 -params/initial_angle = 0.0 -params/initial_size = 1.0 -params/final_size = 1.0 -params/hue_variation = 0.0 -params/anim_speed_scale = 1.0 -params/anim_initial_pos = 0.0 -color/color_ramp = SubResource( 2 ) - -[node name="anim" type="AnimationPlayer" parent="ship"] - -playback/process_mode = 1 -playback/default_blend_time = 0.0 -root/root = NodePath("..") -anims/explode = SubResource( 3 ) -playback/active = true -playback/speed = 1.0 -blend_times = [ ] -autoplay = "" - -[node name="shootfrom" type="Position2D" parent="ship"] - -transform/pos = Vector2( 35.3307, 0.875969 ) - -[node name="explosion" parent="ship" instance=ExtResource( 5 )] - -transform/rot = -91.1436 -config/explosiveness = 0.1 -params/gravity_strength = 9.8 - -[node name="sfx" type="SamplePlayer" parent="ship"] - -config/polyphony = 1 -config/samples = SubResource( 4 ) -default/volume_db = 0.0 -default/pitch_scale = 1.0 -default/pan = 0.0 -default/depth = 0.0 -default/height = 0.0 -default/filter/type = 0 -default/filter/cutoff = 0.0 -default/filter/resonance = 0.0 -default/filter/gain = 0.0 -default/reverb_room = 2 -default/reverb_send = 0.0 -default/chorus_send = 0.0 - -[node name="camera" type="Camera2D" parent="."] - -anchor_mode = 0 -rotating = false -current = true -zoom = Vector2( 1, 1 ) -limit/left = -10000000 -limit/top = -10000000 -limit/right = 10000000 -limit/bottom = 10000000 -drag_margin/h_enabled = true -drag_margin/v_enabled = true -smoothing/enable = false -smoothing/speed = 5.0 -drag_margin/left = 0.2 -drag_margin/top = 0.2 -drag_margin/right = 0.2 -drag_margin/bottom = 0.2 - -[node name="hud" type="CanvasLayer" parent="."] - -layer = 1 -offset = Vector2( 0, 0 ) -rotation = 0.0 -scale = Vector2( 1, 1 ) - -[node name="score" type="Label" parent="hud"] - -focus/ignore_mouse = true -focus/stop_mouse = true -size_flags/horizontal = 2 -margin/left = 15.0 -margin/top = 13.0 -margin/right = 66.0 -margin/bottom = 26.0 -text = "SCORE:" -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - -[node name="score_points" type="Label" parent="hud"] - -focus/ignore_mouse = true -focus/stop_mouse = true -size_flags/horizontal = 2 -margin/left = 70.0 -margin/top = 13.0 -margin/right = 121.0 -margin/bottom = 26.0 -text = "0" -align = 1 -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - -[node name="back_to_menu" type="Button" parent="hud"] - -focus/ignore_mouse = false -focus/stop_mouse = true -size_flags/horizontal = 2 -size_flags/vertical = 2 -margin/left = 911.0 -margin/top = 10.0 -margin/right = 1006.0 -margin/bottom = 31.0 -toggle_mode = false -text = "Back to Menu" -flat = false - -[node name="game_over" type="Label" parent="hud"] - -visibility/visible = false -focus/ignore_mouse = true -focus/stop_mouse = true -size_flags/horizontal = 2 -margin/left = 482.0 -margin/top = 286.0 -margin/right = 564.0 -margin/bottom = 299.0 -text = "GAME_OVER" -percent_visible = 1.0 -lines_skipped = 0 -max_lines_visible = -1 - -[connection signal="body_enter" from="ship" to="ship" method="_on_ship_body_enter"] - -[connection signal="area_enter" from="ship" to="ship" method="_on_ship_area_enter"] - -[connection signal="pressed" from="hud/back_to_menu" to="ship" method="_on_back_to_menu_pressed"] - - diff --git a/demos/2d/space_shooter/shoot.png b/demos/2d/space_shooter/shoot.png deleted file mode 100644 index 6e80ddab93..0000000000 Binary files a/demos/2d/space_shooter/shoot.png and /dev/null differ diff --git a/demos/2d/space_shooter/shot.gd b/demos/2d/space_shooter/shot.gd deleted file mode 100644 index 936dde73d1..0000000000 --- a/demos/2d/space_shooter/shot.gd +++ /dev/null @@ -1,40 +0,0 @@ - -extends Area2D - -# Member variables -const SPEED = 800 - -var hit = false - - -func _process(delta): - translate(Vector2(delta*SPEED, 0)) - - -func _ready(): - set_process(true) - - -func _hit_something(): - if (hit): - return - hit = true - set_process(false) - get_node("anim").play("splash") - - -func _on_visibility_exit_screen(): - queue_free() - - -func _on_shot_area_enter(area): - # Hit an enemy or asteroid - if (area.has_method("destroy")): - # Duck typing at it's best - area.destroy() - _hit_something() - - -func _on_shot_body_enter(body): - # Hit the tilemap - _hit_something() diff --git a/demos/2d/space_shooter/shot.tscn b/demos/2d/space_shooter/shot.tscn deleted file mode 100644 index 2913eaf5b7..0000000000 --- a/demos/2d/space_shooter/shot.tscn +++ /dev/null @@ -1,103 +0,0 @@ -[gd_scene load_steps=6 format=1] - -[ext_resource path="res://shot.gd" type="Script" id=1] -[ext_resource path="res://shoot.png" type="Texture" id=2] - -[sub_resource type="RectangleShape2D" id=1] - -custom_solver_bias = 0.0 -extents = Vector2( 10, 4 ) - -[sub_resource type="ColorRamp" id=2] - -offsets = FloatArray( 0, 1 ) -colors = ColorArray( 0.238085, 0.881885, 0.983902, 1, 1, 1, 1, 0 ) - -[sub_resource type="Animation" id=3] - -length = 1.0 -loop = false -step = 0.1 -tracks/0/type = "value" -tracks/0/path = NodePath("hit_splash:config/emitting") -tracks/0/interp = 1 -tracks/0/keys = { "cont":false, "times":FloatArray( 0, 0.1 ), "transitions":FloatArray( 1, 1 ), "values":[ true, false ] } -tracks/1/type = "method" -tracks/1/path = NodePath(".") -tracks/1/interp = 1 -tracks/1/keys = { "times":FloatArray( 1 ), "transitions":FloatArray( 1 ), "values":[ { "args":[ ], "method":"queue_free" } ] } -tracks/2/type = "value" -tracks/2/path = NodePath("sprite:visibility/visible") -tracks/2/interp = 1 -tracks/2/keys = { "cont":false, "times":FloatArray( 0 ), "transitions":FloatArray( 1 ), "values":[ false ] } - -[node name="shot" type="Area2D"] - -input/pickable = true -shapes/0/shape = SubResource( 1 ) -shapes/0/transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -shapes/0/trigger = false -gravity_vec = Vector2( 0, 1 ) -gravity = 98.0 -linear_damp = 0.1 -angular_damp = 1.0 -script/script = ExtResource( 1 ) - -[node name="visibility" type="VisibilityNotifier2D" parent="."] - -transform/pos = Vector2( 1.8353, -0.0742126 ) -transform/scale = Vector2( 1.54149, 0.770745 ) -rect = Rect2( -10, -10, 20, 20 ) - -[node name="sprite" type="Sprite" parent="."] - -texture = ExtResource( 2 ) - -[node name="collision" type="CollisionShape2D" parent="."] - -shape = SubResource( 1 ) -trigger = false -_update_shape_index = -1 - -[node name="hit_splash" type="Particles2D" parent="."] - -config/amount = 32 -config/lifetime = 0.5 -config/emitting = false -config/explosiveness = 0.1 -params/direction = 0.0 -params/spread = 180.0 -params/linear_velocity = 50.0 -params/spin_velocity = 0.0 -params/orbit_velocity = 0.0 -params/gravity_direction = 0.0 -params/gravity_strength = 0.0 -params/radial_accel = 0.0 -params/tangential_accel = 0.0 -params/damping = 0.0 -params/initial_angle = 0.0 -params/initial_size = 3.0 -params/final_size = 3.0 -params/hue_variation = 0.0 -params/anim_speed_scale = 1.0 -params/anim_initial_pos = 0.0 -color/color_ramp = SubResource( 2 ) - -[node name="anim" type="AnimationPlayer" parent="."] - -playback/process_mode = 1 -playback/default_blend_time = 0.0 -root/root = NodePath("..") -anims/splash = SubResource( 3 ) -playback/active = true -playback/speed = 1.0 -blend_times = [ ] -autoplay = "" - -[connection signal="body_enter" from="." to="." method="_on_shot_body_enter"] - -[connection signal="area_enter" from="." to="." method="_on_shot_area_enter"] - -[connection signal="exit_screen" from="visibility" to="." method="_on_visibility_exit_screen"] - - diff --git a/demos/2d/space_shooter/small_star.png b/demos/2d/space_shooter/small_star.png deleted file mode 100644 index 71c3c531cd..0000000000 Binary files a/demos/2d/space_shooter/small_star.png and /dev/null differ diff --git a/demos/2d/space_shooter/sound_explode.wav b/demos/2d/space_shooter/sound_explode.wav deleted file mode 100644 index 229c85399c..0000000000 Binary files a/demos/2d/space_shooter/sound_explode.wav and /dev/null differ diff --git a/demos/2d/space_shooter/sound_shoot.wav b/demos/2d/space_shooter/sound_shoot.wav deleted file mode 100644 index ad74f328cb..0000000000 Binary files a/demos/2d/space_shooter/sound_shoot.wav and /dev/null differ diff --git a/demos/2d/space_shooter/tile.png b/demos/2d/space_shooter/tile.png deleted file mode 100644 index d8f41d16f6..0000000000 Binary files a/demos/2d/space_shooter/tile.png and /dev/null differ diff --git a/demos/2d/space_shooter/tileset.tres b/demos/2d/space_shooter/tileset.tres deleted file mode 100644 index 0a62a0048e..0000000000 --- a/demos/2d/space_shooter/tileset.tres +++ /dev/null @@ -1,20 +0,0 @@ -[gd_resource type="TileSet" load_steps=3 format=1] - -[ext_resource path="res://tile.png" type="Texture" id=1] - -[sub_resource type="RectangleShape2D" id=1] - -custom_solver_bias = 0.0 -extents = Vector2( 16, 16 ) - -[resource] - -0/name = "block" -0/texture = ExtResource( 1 ) -0/tex_offset = Vector2( 0, 0 ) -0/region = Rect2( 0, 0, 0, 0 ) -0/occluder_offset = Vector2( 16, 16 ) -0/navigation_offset = Vector2( 16, 16 ) -0/shape_offset = Vector2( 16, 16 ) -0/shapes = [ SubResource( 1 ) ] - diff --git a/demos/2d/space_shooter/tileset_edit.tscn b/demos/2d/space_shooter/tileset_edit.tscn deleted file mode 100644 index 87152a1818..0000000000 --- a/demos/2d/space_shooter/tileset_edit.tscn +++ /dev/null @@ -1,35 +0,0 @@ -[gd_scene load_steps=3 format=1] - -[ext_resource path="res://tile.png" type="Texture" id=1] - -[sub_resource type="RectangleShape2D" id=1] - -custom_solver_bias = 0.0 -extents = Vector2( 16, 16 ) - -[node name="Node2D" type="Node2D"] - -[node name="block" type="Sprite" parent="."] - -texture = ExtResource( 1 ) - -[node name="StaticBody2D" type="StaticBody2D" parent="block"] - -input/pickable = false -shapes/0/shape = SubResource( 1 ) -shapes/0/transform = Matrix32( 1, 0, 0, 1, 0, 0 ) -shapes/0/trigger = false -collision/layers = 1 -collision/mask = 1 -constant_linear_velocity = Vector2( 0, 0 ) -constant_angular_velocity = 0.0 -friction = 1.0 -bounce = 0.0 - -[node name="CollisionShape2D" type="CollisionShape2D" parent="block/StaticBody2D"] - -shape = SubResource( 1 ) -trigger = false -_update_shape_index = -1 - - -- cgit v1.2.3