diff --git a/graphics/turniwood/turning_platform_mountain.png b/graphics/turniwood/turning_platform_mountain.png new file mode 100644 index 0000000..ef12729 Binary files /dev/null and b/graphics/turniwood/turning_platform_mountain.png differ diff --git a/graphics/turniwood/turning_platform_mountain.png.import b/graphics/turniwood/turning_platform_mountain.png.import new file mode 100644 index 0000000..02a4aa4 --- /dev/null +++ b/graphics/turniwood/turning_platform_mountain.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/turning_platform_mountain.png-99234754fafbece81d44f113a3eb84f8.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://graphics/turniwood/turning_platform_mountain.png" +dest_files=[ "res://.import/turning_platform_mountain.png-99234754fafbece81d44f113a3eb84f8.stex" ] + +[params] + +compress/mode=0 +compress/lossy_quality=0.7 +compress/hdr_mode=0 +compress/bptc_ldr=0 +compress/normal_map=0 +flags/repeat=0 +flags/filter=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=true +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=true +svg/scale=1.0 diff --git a/graphics/turniwood/turning_platform_rust.png b/graphics/turniwood/turning_platform_rust.png new file mode 100644 index 0000000..594da05 Binary files /dev/null and b/graphics/turniwood/turning_platform_rust.png differ diff --git a/graphics/turniwood/turning_platform_rust.png.import b/graphics/turniwood/turning_platform_rust.png.import new file mode 100644 index 0000000..2f1583e --- /dev/null +++ b/graphics/turniwood/turning_platform_rust.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/turning_platform_rust.png-1716c004acdfe5c8b6f578edbffcb9d8.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://graphics/turniwood/turning_platform_rust.png" +dest_files=[ "res://.import/turning_platform_rust.png-1716c004acdfe5c8b6f578edbffcb9d8.stex" ] + +[params] + +compress/mode=0 +compress/lossy_quality=0.7 +compress/hdr_mode=0 +compress/bptc_ldr=0 +compress/normal_map=0 +flags/repeat=0 +flags/filter=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=true +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=true +svg/scale=1.0 diff --git a/graphics/turniwood/turning_platform_wood.png b/graphics/turniwood/turning_platform_wood.png new file mode 100644 index 0000000..a5bb338 Binary files /dev/null and b/graphics/turniwood/turning_platform_wood.png differ diff --git a/graphics/turniwood/turning_platform_wood.png.import b/graphics/turniwood/turning_platform_wood.png.import new file mode 100644 index 0000000..b69152b --- /dev/null +++ b/graphics/turniwood/turning_platform_wood.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/turning_platform_wood.png-3793ee416806618b38cf4a3017bfbd0e.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://graphics/turniwood/turning_platform_wood.png" +dest_files=[ "res://.import/turning_platform_wood.png-3793ee416806618b38cf4a3017bfbd0e.stex" ] + +[params] + +compress/mode=0 +compress/lossy_quality=0.7 +compress/hdr_mode=0 +compress/bptc_ldr=0 +compress/normal_map=0 +flags/repeat=0 +flags/filter=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=true +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=true +svg/scale=1.0 diff --git a/graphics/turniwood/turning_platform_wood_dark.png b/graphics/turniwood/turning_platform_wood_dark.png new file mode 100644 index 0000000..e1c2ab8 Binary files /dev/null and b/graphics/turniwood/turning_platform_wood_dark.png differ diff --git a/graphics/turniwood/turning_platform_wood_dark.png.import b/graphics/turniwood/turning_platform_wood_dark.png.import new file mode 100644 index 0000000..678972c --- /dev/null +++ b/graphics/turniwood/turning_platform_wood_dark.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/turning_platform_wood_dark.png-46a12d83de18f7a7acdb06d2e86d282c.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://graphics/turniwood/turning_platform_wood_dark.png" +dest_files=[ "res://.import/turning_platform_wood_dark.png-46a12d83de18f7a7acdb06d2e86d282c.stex" ] + +[params] + +compress/mode=0 +compress/lossy_quality=0.7 +compress/hdr_mode=0 +compress/bptc_ldr=0 +compress/normal_map=0 +flags/repeat=0 +flags/filter=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=true +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=true +svg/scale=1.0 diff --git a/graphics/turniwood/turning_platform_yellow.png b/graphics/turniwood/turning_platform_yellow.png index bc5ce12..5ccee02 100644 Binary files a/graphics/turniwood/turning_platform_yellow.png and b/graphics/turniwood/turning_platform_yellow.png differ diff --git a/graphics/turniwood/turning_platoform_lab.png b/graphics/turniwood/turning_platoform_lab.png new file mode 100644 index 0000000..c9b4c75 Binary files /dev/null and b/graphics/turniwood/turning_platoform_lab.png differ diff --git a/graphics/turniwood/turning_platoform_lab.png.import b/graphics/turniwood/turning_platoform_lab.png.import new file mode 100644 index 0000000..2e53082 --- /dev/null +++ b/graphics/turniwood/turning_platoform_lab.png.import @@ -0,0 +1,35 @@ +[remap] + +importer="texture" +type="StreamTexture" +path="res://.import/turning_platoform_lab.png-73e519d3a9eb265b437745a0ee008e01.stex" +metadata={ +"vram_texture": false +} + +[deps] + +source_file="res://graphics/turniwood/turning_platoform_lab.png" +dest_files=[ "res://.import/turning_platoform_lab.png-73e519d3a9eb265b437745a0ee008e01.stex" ] + +[params] + +compress/mode=0 +compress/lossy_quality=0.7 +compress/hdr_mode=0 +compress/bptc_ldr=0 +compress/normal_map=0 +flags/repeat=0 +flags/filter=false +flags/mipmaps=false +flags/anisotropic=false +flags/srgb=2 +process/fix_alpha_border=true +process/premult_alpha=false +process/HDR_as_SRGB=false +process/invert_color=false +process/normal_map_invert_y=false +stream=false +size_limit=0 +detect_3d=true +svg/scale=1.0 diff --git a/maps/boss/boss1_arena.tscn b/maps/boss/boss1_arena.tscn index 7b7b042..3527825 100644 --- a/maps/boss/boss1_arena.tscn +++ b/maps/boss/boss1_arena.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=17 format=2] +[gd_scene load_steps=18 format=2] [ext_resource path="res://objects/enemy/boss/scrump.tscn" type="PackedScene" id=1] [ext_resource path="res://objects/player/player.tscn" type="PackedScene" id=2] @@ -16,6 +16,7 @@ [ext_resource path="res://tilesets/t_ladders.tres" type="TileSet" id=14] [ext_resource path="res://shaders/can_stain.tres" type="Material" id=15] [ext_resource path="res://objects/lore/boss/the_scrump.tscn" type="PackedScene" id=16] +[ext_resource path="res://graphics/turniwood/turning_platform_wood_dark.png" type="Texture" id=17] [node name="Map" type="Node2D" groups=["map"]] pause_mode = 1 @@ -67,9 +68,11 @@ right_down_boundary = 2.0 [node name="TurningPlatform" parent="." instance=ExtResource( 9 )] position = Vector2( 72, 144 ) +texture = ExtResource( 17 ) [node name="TurningPlatform2" parent="." instance=ExtResource( 9 )] position = Vector2( 120, 144 ) +texture = ExtResource( 17 ) [node name="Ladder2" parent="." instance=ExtResource( 10 )] position = Vector2( 64, 96 ) diff --git a/maps/canopy.tscn b/maps/canopy.tscn index 9e1a50c..bbb9863 100644 --- a/maps/canopy.tscn +++ b/maps/canopy.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=34 format=2] +[gd_scene load_steps=35 format=2] [ext_resource path="res://objects/Camera2D.tscn" type="PackedScene" id=1] [ext_resource path="res://maps/map.gd" type="Script" id=2] @@ -29,6 +29,7 @@ [ext_resource path="res://shaders/can_stain.tres" type="Material" id=27] [ext_resource path="res://scripts/has_splash.gd" type="Script" id=28] [ext_resource path="res://maps/bug_teleporter.gd" type="Script" id=29] +[ext_resource path="res://graphics/turniwood/turning_platform_wood.png" type="Texture" id=30] [sub_resource type="RectangleShape2D" id=2] extents = Vector2( 7.5, 20 ) @@ -124,123 +125,153 @@ scale = Vector2( 1, 14 ) [node name="Turniwood" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 0, 96 ) +texture = ExtResource( 30 ) [node name="Turniwood2" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 72, 104 ) +texture = ExtResource( 30 ) [node name="Turniwood30" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 216, 72 ) time = 20.0 +texture = ExtResource( 30 ) [node name="Turniwood5" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 352, 80 ) +texture = ExtResource( 30 ) [node name="Turniwood12" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 464, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood24" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 456, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood25" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 448, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood13" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 472, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood14" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 480, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood15" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 488, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood16" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 496, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood17" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 504, 24 ) time = 30.0 +texture = ExtResource( 30 ) [node name="Turniwood20" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 736, 160 ) +texture = ExtResource( 30 ) [node name="Turniwood21" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 752, 144 ) delay = 0.5 +texture = ExtResource( 30 ) [node name="Turniwood22" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 736, 128 ) delay = 1.0 +texture = ExtResource( 30 ) [node name="Turniwood23" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 752, 120 ) delay = 1.5 +texture = ExtResource( 30 ) [node name="Turniwood26" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 736, 104 ) delay = 2.0 +texture = ExtResource( 30 ) [node name="Turniwood27" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 752, 88 ) delay = 2.5 +texture = ExtResource( 30 ) [node name="Turniwood10" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 448, 128 ) +texture = ExtResource( 30 ) [node name="Turniwood6" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 560, 64 ) +texture = ExtResource( 30 ) [node name="Turniwood3" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 96, 160 ) +texture = ExtResource( 30 ) [node name="Turniwood28" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 176, 152 ) +texture = ExtResource( 30 ) [node name="Turniwood9" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 120, 48 ) +texture = ExtResource( 30 ) [node name="Turniwood4" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 136, 80 ) +texture = ExtResource( 30 ) [node name="Turniwood11" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 336, 136 ) +texture = ExtResource( 30 ) [node name="Turniwood19" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 400, 144 ) +texture = ExtResource( 30 ) [node name="Turniwood29" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 328, 40 ) +texture = ExtResource( 30 ) [node name="Turniwood18" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 312, 136 ) delay = 1.0 +texture = ExtResource( 30 ) [node name="Turniwood7" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 456, 152 ) time = 90.0 +texture = ExtResource( 30 ) [node name="Turniwood8" parent="Platforms" instance=ExtResource( 13 )] position = Vector2( 464, 152 ) time = 90.0 +texture = ExtResource( 30 ) [node name="Barrier" parent="Platforms" instance=ExtResource( 15 )] -position = Vector2( 162, 152 ) +position = Vector2( 164, 152 ) scale = Vector2( 1, 24 ) cost = 30 [node name="Barrier4" parent="Platforms" instance=ExtResource( 15 )] -position = Vector2( 490, 104 ) +position = Vector2( 488, 104 ) scale = Vector2( 1, 24 ) cost = 35 [node name="Barrier2" parent="Platforms" instance=ExtResource( 15 )] -position = Vector2( 114, 152 ) +position = Vector2( 112, 152 ) scale = Vector2( 1, 24 ) cost = 30 diff --git a/maps/hills_scholar.tscn b/maps/hills_scholar.tscn index 6d76db3..b4c8ca1 100644 --- a/maps/hills_scholar.tscn +++ b/maps/hills_scholar.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=31 format=2] +[gd_scene load_steps=32 format=2] [ext_resource path="res://objects/environment/ladder/ladder.tscn" type="PackedScene" id=1] [ext_resource path="res://objects/hud/hud.tscn" type="PackedScene" id=2] @@ -30,6 +30,7 @@ [ext_resource path="res://scripts/has_splash.gd" type="Script" id=28] [ext_resource path="res://objects/lore/hills/speccy.tscn" type="PackedScene" id=29] [ext_resource path="res://objects/lore/hills/sg.tscn" type="PackedScene" id=30] +[ext_resource path="res://graphics/turniwood/turning_platform_wood_dark.png" type="Texture" id=31] [node name="Map" type="Node2D" groups=["map"]] pause_mode = 1 @@ -116,20 +117,25 @@ scale = Vector2( 1, 4 ) [node name="TurningPlatform" parent="Environment/TurningPlatforms" instance=ExtResource( 16 )] position = Vector2( 136, 64 ) +texture = ExtResource( 31 ) [node name="TurningPlatform3" parent="Environment/TurningPlatforms" instance=ExtResource( 16 )] position = Vector2( 368, 152 ) time = 80.0 +texture = ExtResource( 31 ) [node name="TurningPlatform6" parent="Environment/TurningPlatforms" instance=ExtResource( 16 )] position = Vector2( 384, 32 ) +texture = ExtResource( 31 ) [node name="TurningPlatform5" parent="Environment/TurningPlatforms" instance=ExtResource( 16 )] position = Vector2( 616, 160 ) +texture = ExtResource( 31 ) [node name="TurningPlatform4" parent="Environment/TurningPlatforms" instance=ExtResource( 16 )] position = Vector2( 408, 152 ) time = 80.0 +texture = ExtResource( 31 ) [node name="MovingPlatform" parent="Environment" instance=ExtResource( 11 )] position = Vector2( 624, 40 ) diff --git a/maps/mountain.tscn b/maps/mountain.tscn index 08cc2b6..9052be9 100644 --- a/maps/mountain.tscn +++ b/maps/mountain.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=43 format=2] +[gd_scene load_steps=44 format=2] [ext_resource path="res://objects/Camera2D.tscn" type="PackedScene" id=1] [ext_resource path="res://maps/map.gd" type="Script" id=2] @@ -31,6 +31,7 @@ [ext_resource path="res://objects/lore/hills/catbat.tscn" type="PackedScene" id=29] [ext_resource path="res://objects/lore/mountain/echo_mountain.tscn" type="PackedScene" id=30] [ext_resource path="res://objects/lore/mountain/rolling_fiend.tscn" type="PackedScene" id=31] +[ext_resource path="res://graphics/turniwood/turning_platform_wood_dark.png" type="Texture" id=32] [sub_resource type="RectangleShape2D" id=2] extents = Vector2( 24, 20 ) @@ -246,12 +247,15 @@ scale = Vector2( 1, 3 ) [node name="TurningPlatform" parent="Environment" instance=ExtResource( 15 )] position = Vector2( 168, 168 ) +texture = ExtResource( 32 ) [node name="TurningPlatform2" parent="Environment" instance=ExtResource( 15 )] position = Vector2( 80, 144 ) +texture = ExtResource( 32 ) [node name="TurningPlatform4" parent="Environment" instance=ExtResource( 15 )] position = Vector2( 168, -280 ) +texture = ExtResource( 32 ) [node name="Rock2" parent="Environment" instance=ExtResource( 19 )] position = Vector2( 112, 56 ) diff --git a/maps/rust.tscn b/maps/rust.tscn index d73cc71..8683d39 100644 --- a/maps/rust.tscn +++ b/maps/rust.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=33 format=2] +[gd_scene load_steps=34 format=2] [ext_resource path="res://maps/map.gd" type="Script" id=1] [ext_resource path="res://objects/Camera2D.tscn" type="PackedScene" id=2] @@ -31,6 +31,7 @@ [ext_resource path="res://objects/lore/rust/tin.tscn" type="PackedScene" id=29] [ext_resource path="res://objects/lore/rust/rolling_saw.tscn" type="PackedScene" id=30] [ext_resource path="res://objects/lore/rust/rust_inc.tscn" type="PackedScene" id=31] +[ext_resource path="res://graphics/turniwood/turning_platform_rust.png" type="Texture" id=32] [sub_resource type="RectangleShape2D" id=1] extents = Vector2( 4, 112 ) @@ -101,14 +102,17 @@ tile_data = PoolIntArray( 196618, 0, 196608, 262154, 0, 196608, 327690, 0, 19660 position = Vector2( 336, 40 ) time = 15.0 delay = 1.0 +texture = ExtResource( 32 ) [node name="TurningPlatform7" parent="Environment" instance=ExtResource( 9 )] position = Vector2( 656, 168 ) time = 15.0 +texture = ExtResource( 32 ) [node name="TurningPlatform4" parent="Environment" instance=ExtResource( 9 )] position = Vector2( 312, 40 ) time = 30.0 +texture = ExtResource( 32 ) [node name="Ladder" parent="Environment" instance=ExtResource( 14 )] position = Vector2( 352, 96 ) diff --git a/maps/station.tscn b/maps/station.tscn index 775b92d..649f58a 100644 --- a/maps/station.tscn +++ b/maps/station.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=36 format=2] +[gd_scene load_steps=37 format=2] [ext_resource path="res://maps/station.gd" type="Script" id=1] [ext_resource path="res://objects/player/player.tscn" type="PackedScene" id=2] @@ -33,6 +33,7 @@ [ext_resource path="res://ui/2ndpuberty_outline.tres" type="Material" id=31] [ext_resource path="res://ui/theme.tres" type="Theme" id=32] [ext_resource path="res://graphics/hatch/hatch.png" type="Texture" id=33] +[ext_resource path="res://graphics/turniwood/turning_platoform_lab.png" type="Texture" id=34] [sub_resource type="Animation" id=2] resource_name = "open" @@ -271,23 +272,28 @@ scale = Vector2( 1, 4 ) [node name="TurningPlatform" parent="Environment" instance=ExtResource( 17 )] position = Vector2( 696, 144 ) time = 20.0 +texture = ExtResource( 34 ) [node name="TurningPlatform3" parent="Environment" instance=ExtResource( 17 )] position = Vector2( 40, 72 ) time = 20.0 +texture = ExtResource( 34 ) [node name="TurningPlatform6" parent="Environment" instance=ExtResource( 17 )] position = Vector2( 520, 112 ) time = 40.0 +texture = ExtResource( 34 ) [node name="TurningPlatform8" parent="Environment" instance=ExtResource( 17 )] position = Vector2( 488, 32 ) time = 50.0 +texture = ExtResource( 34 ) [node name="TurningPlatform4" parent="Environment" instance=ExtResource( 17 )] position = Vector2( 16, 56 ) time = 20.0 delay = 1.0 +texture = ExtResource( 34 ) [node name="JailBars" parent="Environment" groups=["cell"] instance=ExtResource( 21 )] position = Vector2( 712, 152 ) diff --git a/objects/environment/turniwood/turning_platform.gd b/objects/environment/turniwood/turning_platform.gd index 8c8989b..5bc03d0 100644 --- a/objects/environment/turniwood/turning_platform.gd +++ b/objects/environment/turniwood/turning_platform.gd @@ -1,15 +1,20 @@ +tool extends Node2D + onready var anims = $AnimationPlayer onready var flip_timer = $FlipTimer onready var delay_timer = $DelayTimer onready var static_body = $StaticBody2D export var time:float = 60 export var delay = 0.0 -export(int, "Wood", "Yellow") var color +export var texture: Texture setget _set_texture onready var time_ms = time / 60.0 # Time is converted from frames @ 60fps to ms onready var collision_layer = static_body.collision_layer func _ready(): + if Engine.editor_hint: + return + _set_texture(texture) #Auto start if delay variable is zero if delay == 0.0: anims.play("idle") @@ -19,6 +24,11 @@ func _ready(): #Easy mode time_ms /= Game.enemy_speed_factor +func _set_texture(new_texture: Texture) -> void: + texture = new_texture + if is_inside_tree(): + $Sprite.texture = new_texture + func _on_AnimationPlayer_animation_finished(anim_name): #Return to idle after turn animation if anim_name == "turn": diff --git a/objects/environment/turniwood/turning_platform.tscn b/objects/environment/turniwood/turning_platform.tscn index 55b66c8..6e0e46f 100644 --- a/objects/environment/turniwood/turning_platform.tscn +++ b/objects/environment/turniwood/turning_platform.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=7 format=2] +[gd_scene load_steps=8 format=2] [ext_resource path="res://objects/environment/turniwood/turning_platform.gd" type="Script" id=1] [ext_resource path="res://graphics/turniwood/turning_platform_yellow.png" type="Texture" id=2] @@ -9,12 +9,27 @@ extents = Vector2( 4, 1 ) [sub_resource type="RectangleShape2D" id=4] extents = Vector2( 3.5, 0.5 ) +[sub_resource type="Animation" id=5] +length = 0.001 +tracks/0/type = "value" +tracks/0/path = NodePath("Sprite:frame") +tracks/0/interp = 1 +tracks/0/loop_wrap = true +tracks/0/imported = false +tracks/0/enabled = true +tracks/0/keys = { +"times": PoolRealArray( 0 ), +"transitions": PoolRealArray( 1 ), +"update": 0, +"values": [ 0 ] +} + [sub_resource type="Animation" id=2] resource_name = "idle" loop = true step = 0.125 tracks/0/type = "value" -tracks/0/path = NodePath("Sprite:region_rect") +tracks/0/path = NodePath("StaticBody2D/CollisionShape2D:disabled") tracks/0/interp = 1 tracks/0/loop_wrap = true tracks/0/imported = false @@ -23,10 +38,10 @@ tracks/0/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, -"values": [ Rect2( 0, 0, 8, 8 ) ] +"values": [ false ] } tracks/1/type = "value" -tracks/1/path = NodePath("Sprite:rotation_degrees") +tracks/1/path = NodePath("Sprite:frame") tracks/1/interp = 1 tracks/1/loop_wrap = true tracks/1/imported = false @@ -35,19 +50,7 @@ tracks/1/keys = { "times": PoolRealArray( 0 ), "transitions": PoolRealArray( 1 ), "update": 1, -"values": [ 0.0 ] -} -tracks/2/type = "value" -tracks/2/path = NodePath("StaticBody2D/CollisionShape2D:disabled") -tracks/2/interp = 1 -tracks/2/loop_wrap = true -tracks/2/imported = false -tracks/2/enabled = true -tracks/2/keys = { -"times": PoolRealArray( 0 ), -"transitions": PoolRealArray( 1 ), -"update": 1, -"values": [ false ] +"values": [ 0 ] } [sub_resource type="Animation" id=3] @@ -79,37 +82,38 @@ tracks/1/keys = { "values": [ Rect2( 0, 0, 8, 8 ), Rect2( 8, 0, 8, 8 ), Rect2( 0, 0, 8, 8 ), Rect2( 8, 0, 8, 8 ), Rect2( 0, 0, 8, 8 ) ] } tracks/2/type = "value" -tracks/2/path = NodePath("Sprite:rotation_degrees") +tracks/2/path = NodePath("Sprite:position") tracks/2/interp = 1 tracks/2/loop_wrap = true tracks/2/imported = false tracks/2/enabled = true tracks/2/keys = { -"times": PoolRealArray( 0.4, 0.55, 0.65, 0.8, 0.9 ), -"transitions": PoolRealArray( 1, 1, 1, 1, 1 ), -"update": 1, -"values": [ 0.0, 90.0, 90.0, 0.0, 0.0 ] -} -tracks/3/type = "value" -tracks/3/path = NodePath("Sprite:position") -tracks/3/interp = 1 -tracks/3/loop_wrap = true -tracks/3/imported = false -tracks/3/enabled = true -tracks/3/keys = { "times": PoolRealArray( 0.15, 0.2, 0.35, 0.4 ), "transitions": PoolRealArray( 1, 1, 1, 1 ), "update": 0, "values": [ Vector2( 4, 4 ), Vector2( 5, 4 ), Vector2( 3, 4 ), Vector2( 4, 4 ) ] } +tracks/3/type = "value" +tracks/3/path = NodePath("Sprite:frame") +tracks/3/interp = 1 +tracks/3/loop_wrap = true +tracks/3/imported = false +tracks/3/enabled = true +tracks/3/keys = { +"times": PoolRealArray( 0, 0.55, 0.65, 0.8, 0.9 ), +"transitions": PoolRealArray( 1, 1, 1, 1, 1 ), +"update": 1, +"values": [ 0, 1, 2, 3, 0 ] +} [node name="TurningPlatform" type="Node2D"] script = ExtResource( 1 ) +texture = ExtResource( 2 ) [node name="Sprite" type="Sprite" parent="."] position = Vector2( 4, 4 ) texture = ExtResource( 2 ) -region_enabled = true +hframes = 4 region_rect = Rect2( 0, 0, 8, 8 ) [node name="StaticBody2D" type="StaticBody2D" parent="."] @@ -132,6 +136,7 @@ position = Vector2( 4, 4 ) shape = SubResource( 4 ) [node name="AnimationPlayer" type="AnimationPlayer" parent="."] +anims/RESET = SubResource( 5 ) anims/idle = SubResource( 2 ) anims/turn = SubResource( 3 )