fix: activator area fix, static tut, background
This commit is contained in:
parent
005e08d8cb
commit
f7cfd471d6
Binary file not shown.
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 5.6 KiB After Width: | Height: | Size: 5.9 KiB |
Binary file not shown.
@ -1,4 +1,7 @@
|
||||
[gd_resource type="DynamicFont" format=2]
|
||||
[gd_resource type="DynamicFont" load_steps=2 format=2]
|
||||
|
||||
[ext_resource path="res://assets/ui/fonts/Kenney Space.ttf" type="DynamicFontData" id=1]
|
||||
|
||||
[resource]
|
||||
size = 20
|
||||
size = 9
|
||||
font_data = ExtResource( 1 )
|
||||
|
||||
@ -169,6 +169,7 @@ func calculate_grounded_velocity(
|
||||
# Jumping when grounded or jump is buffered
|
||||
if Input.is_action_just_pressed("jump") || (jump_buffer_filled && is_on_floor()) || stomping:
|
||||
snap_possible = false
|
||||
#velocity += get_floor_velocity() * 0.5
|
||||
return calculate_jump_velocity(velocity, delta, direction)
|
||||
|
||||
elif player_state_machine.coyote_hanging:
|
||||
|
||||
@ -4385,7 +4385,7 @@ texture = SubResource( 62 )
|
||||
offset = Vector2( 1, 0 )
|
||||
hframes = 6
|
||||
vframes = 6
|
||||
frame = 6
|
||||
frame = 8
|
||||
__meta__ = {
|
||||
"_editor_description_": "YXNlcHJpdGVfd2l6YXJkX2NvbmZpZwpwbGF5ZXJ8PUJsb2JieVNwcml0ZS9CbG9iYnltYXRpb25QbGF5ZXIKc291cmNlfD1yZXM6Ly9hc3NldHMvYmxvYmJ5L2Jsb2JieS1zcHJpdGVzaGVldHQuYXNlcHJpdGUKbGF5ZXJ8PUJsb2JieQpvcF9leHB8PUZhbHNlCm9fZm9sZGVyfD0Kb19uYW1lfD0Kb25seV92aXNpYmxlfD1GYWxzZQpvX2V4X3B8PQo="
|
||||
}
|
||||
@ -4572,5 +4572,5 @@ one_shot = true
|
||||
[connection signal="got_grounded" from="BlobbyStateMachine" to="." method="_on_Blobby_got_grounded"]
|
||||
[connection signal="timeout" from="BlobbyStateMachine/JumpBufferTimer" to="BlobbyStateMachine" method="_on_JumpBufferTimer_timeout"]
|
||||
[connection signal="timeout" from="InvincibilityTimer" to="." method="_on_InvincibilityTimer_timeout"]
|
||||
[connection signal="timeout" from="PitfallTimer" to="." method="_on_PitfallTimer_timeout"]
|
||||
[connection signal="timeout" from="PitfallTimer" to="." method="die_for_real"]
|
||||
[connection signal="timeout" from="PitfallTimer" to="." method="_on_PitfallTimer_timeout"]
|
||||
|
||||
File diff suppressed because one or more lines are too long
@ -1,21 +1,21 @@
|
||||
[gd_scene load_steps=14 format=2]
|
||||
|
||||
[ext_resource path="res://src/Actors/Friendlies/WhatAreFrog.tscn" type="PackedScene" id=1]
|
||||
[ext_resource path="res://assets/ui/sci-fi-godot-theme/sci-fi-pixel.tres" type="DynamicFont" id=2]
|
||||
[ext_resource path="res://src/Levels/Templates/LevelTemplate.gd" type="Script" id=5]
|
||||
[ext_resource path="res://src/Utilities/SignalManager.tscn" type="PackedScene" id=8]
|
||||
[ext_resource path="res://src/Actors/BlobbyCam.tscn" type="PackedScene" id=9]
|
||||
[ext_resource path="res://src/UserInterface/UserInterface.tscn" type="PackedScene" id=11]
|
||||
[ext_resource path="res://src/Utilities/LevelState.tscn" type="PackedScene" id=12]
|
||||
[ext_resource path="res://src/Utilities/SceneAudio.tscn" type="PackedScene" id=13]
|
||||
[ext_resource path="res://src/Environment/DropThroughPlatforms.tres" type="TileSet" id=14]
|
||||
[ext_resource path="res://src/Environment/GreenHouseTiles.tres" type="TileSet" id=15]
|
||||
[ext_resource path="res://assets/sounds/AMBIENCE_SciFi_Large_Space_Hangar_Deep_Smooth_loop_stereo.wav" type="AudioStream" id=16]
|
||||
[ext_resource path="res://assets/environment/decor/platform-plants.png" type="Texture" id=17]
|
||||
[ext_resource path="res://src/Environment/GreenHouseTiles.tres" type="TileSet" id=1]
|
||||
[ext_resource path="res://src/Environment/DropThroughPlatforms.tres" type="TileSet" id=2]
|
||||
[ext_resource path="res://assets/environment/decor/platform-plants.png" type="Texture" id=3]
|
||||
[ext_resource path="res://src/Actors/Friendlies/WhatAreFrog.tscn" type="PackedScene" id=4]
|
||||
[ext_resource path="res://src/Actors/BlobbyCam.tscn" type="PackedScene" id=5]
|
||||
[ext_resource path="res://src/Utilities/SceneAudio.tscn" type="PackedScene" id=6]
|
||||
[ext_resource path="res://src/Utilities/SignalManager.tscn" type="PackedScene" id=7]
|
||||
[ext_resource path="res://src/UserInterface/UserInterface.tscn" type="PackedScene" id=8]
|
||||
[ext_resource path="res://src/Utilities/LevelState.tscn" type="PackedScene" id=9]
|
||||
[ext_resource path="res://src/Levels/Templates/LevelTemplate.gd" type="Script" id=10]
|
||||
[ext_resource path="res://assets/sounds/AMBIENCE_SciFi_Large_Space_Hangar_Deep_Smooth_loop_stereo.wav" type="AudioStream" id=11]
|
||||
[ext_resource path="res://assets/ui/fonts/kenny_space.tres" type="DynamicFont" id=12]
|
||||
|
||||
[sub_resource type="TileSet" id=5]
|
||||
0/name = "platform-plants.png 0"
|
||||
0/texture = ExtResource( 17 )
|
||||
0/texture = ExtResource( 3 )
|
||||
0/tex_offset = Vector2( 0, 0 )
|
||||
0/modulate = Color( 1, 1, 1, 1 )
|
||||
0/region = Rect2( 16, 0, 256, 16 )
|
||||
@ -37,54 +37,47 @@
|
||||
0/z_index = 0
|
||||
|
||||
[node name="LevelTemplate" type="Node2D"]
|
||||
script = ExtResource( 5 )
|
||||
script = ExtResource( 10 )
|
||||
__meta__ = {
|
||||
"_edit_horizontal_guides_": [ 464.0 ],
|
||||
"_edit_vertical_guides_": [ 2880.0 ]
|
||||
}
|
||||
|
||||
[node name="SignalManager" parent="." instance=ExtResource( 8 )]
|
||||
[node name="SignalManager" parent="." instance=ExtResource( 7 )]
|
||||
|
||||
[node name="SceneAudio" parent="." instance=ExtResource( 13 )]
|
||||
[node name="SceneAudio" parent="." instance=ExtResource( 6 )]
|
||||
|
||||
[node name="LevelState" parent="." instance=ExtResource( 12 )]
|
||||
[node name="LevelState" parent="." instance=ExtResource( 9 )]
|
||||
unique_name_in_owner = true
|
||||
|
||||
[node name="UserInterface" parent="." instance=ExtResource( 11 )]
|
||||
[node name="Label" type="Label" parent="."]
|
||||
margin_left = -100.0
|
||||
margin_top = 21.0
|
||||
margin_right = 109.0
|
||||
margin_bottom = 62.0
|
||||
custom_fonts/font = ExtResource( 12 )
|
||||
text = "< = Rescue Pod
|
||||
0/10 sests occupied"
|
||||
align = 1
|
||||
|
||||
[node name="UserInterface" parent="." instance=ExtResource( 8 )]
|
||||
unique_name_in_owner = true
|
||||
visible = false
|
||||
|
||||
[node name="Timer" parent="UserInterface/HUD/HUDOverlay/GetBackTimer" index="0"]
|
||||
wait_time = 20.0
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
margin_left = -61.0
|
||||
margin_top = 20.0
|
||||
margin_right = 62.0
|
||||
margin_bottom = 53.0
|
||||
custom_fonts/font = ExtResource( 2 )
|
||||
text = "<= Escape Pods
|
||||
0/10 Seats occupied
|
||||
"
|
||||
align = 1
|
||||
valign = 1
|
||||
|
||||
[node name="WhatAreFrog" parent="." instance=ExtResource( 1 )]
|
||||
[node name="WhatAreFrog" parent="." instance=ExtResource( 4 )]
|
||||
position = Vector2( 121, 103 )
|
||||
|
||||
[node name="BlobbyCam" parent="." instance=ExtResource( 9 )]
|
||||
[node name="BlobbyCam" parent="." instance=ExtResource( 5 )]
|
||||
unique_name_in_owner = true
|
||||
drag_margin_bottom = 0.3
|
||||
fixed_position = true
|
||||
|
||||
[node name="AnimatedSprite" parent="BlobbyCam/ParallaxBackground/ParallaxLayer5" index="4"]
|
||||
frame = 1
|
||||
|
||||
[node name="AnimatedSprite2" parent="BlobbyCam/ParallaxBackground/ParallaxLayer5" index="5"]
|
||||
frame = 0
|
||||
|
||||
[node name="TileMap" type="TileMap" parent="."]
|
||||
unique_name_in_owner = true
|
||||
tile_set = ExtResource( 15 )
|
||||
tile_set = ExtResource( 1 )
|
||||
cell_size = Vector2( 16, 16 )
|
||||
cell_quadrant_size = 3
|
||||
cell_custom_transform = Transform2D( 24, 0, 0, 24, 0, 0 )
|
||||
@ -95,7 +88,7 @@ format = 1
|
||||
tile_data = PoolIntArray( 65522, 5, 65540, 65523, 5, 10, 65524, 5, 10, 65525, 5, 10, 65526, 5, 10, 65527, 5, 10, 65528, 5, 10, 65529, 5, 10, 65530, 5, 10, 65531, 5, 10, 65532, 5, 10, 65533, 5, 10, 65534, 5, 10, 65535, 5, 10, 0, 5, 10, 1, 5, 10, 2, 5, 10, 3, 5, 10, 4, 5, 10, 5, 5, 10, 6, 5, 10, 7, 5, 10, 8, 5, 10, 9, 5, 10, 10, 5, 10, 11, 5, 10, 12, 5, 10, 13, 5, 10, 14, 5, 10, 15, 5, 10, 16, 5, 10, 17, 5, 10, 18, 5, 10, 19, 5, 10, 131058, 5, 7, 196594, 5, 7, 262130, 5, 7, 327666, 5, 7, 393202, 5, 7, 458738, 5, 7, 524274, 5, 65538, 524275, 5, 2, 524276, 5, 2, 524277, 5, 2, 524278, 5, 2, 524279, 5, 2, 524280, 5, 2, 524281, 5, 2, 524282, 5, 2, 524283, 5, 2, 524284, 5, 2, 524285, 5, 2, 524286, 5, 2, 524287, 5, 2, 458752, 5, 2, 458753, 5, 2, 458754, 5, 2, 458755, 5, 2, 458756, 5, 2, 458757, 5, 2, 458758, 5, 2, 458759, 5, 2, 458760, 5, 2, 458761, 5, 2, 458762, 5, 2, 458763, 5, 2, 458764, 5, 2, 458765, 5, 2, 458766, 5, 2, 458767, 5, 2, 458768, 5, 2, 458769, 5, 2, 458770, 5, 2, 458771, 5, 3 )
|
||||
|
||||
[node name="DropThroughPlatforms" type="TileMap" parent="."]
|
||||
tile_set = ExtResource( 14 )
|
||||
tile_set = ExtResource( 2 )
|
||||
cell_size = Vector2( 16, 16 )
|
||||
format = 1
|
||||
|
||||
@ -106,7 +99,7 @@ format = 1
|
||||
|
||||
[node name="LevelAmbiance" type="AudioStreamPlayer" parent="."]
|
||||
unique_name_in_owner = true
|
||||
stream = ExtResource( 16 )
|
||||
stream = ExtResource( 11 )
|
||||
volume_db = -14.994
|
||||
autoplay = true
|
||||
bus = "Music"
|
||||
@ -16,7 +16,7 @@ func _ready() -> void:
|
||||
elevator.get_node("./portal").frame = 1
|
||||
elevator.monitoring = false
|
||||
|
||||
func _process(delta):
|
||||
func _input(event: InputEvent) -> void:
|
||||
if activatable && Input.is_action_just_released("interact"):
|
||||
selfActivate()
|
||||
signal_manager.emit_signal("terminal_activated", elevator_time)
|
||||
@ -42,7 +42,10 @@ func _on_ActivatorArea_area_entered(area:Area2D) -> void:
|
||||
func _on_ActivatorArea_area_exited(area:Area2D) -> void:
|
||||
unactivatable_timer.start()
|
||||
|
||||
func _on_Timer_timeout():
|
||||
func _on_Timer_timeout() -> void:
|
||||
for body in activatorArea.get_overlapping_bodies():
|
||||
if body.is_in_group("player"):
|
||||
return
|
||||
$Label.visible = false
|
||||
$Highlight.visible = false
|
||||
activatable = false
|
||||
|
||||
@ -13,7 +13,7 @@ var activatable = false
|
||||
func _ready() -> void:
|
||||
$Digit.frame = frog_number
|
||||
|
||||
func _process(delta):
|
||||
func _input(event: InputEvent) -> void:
|
||||
if activatable && Input.is_action_just_released("interact"):
|
||||
selfActivate()
|
||||
self.emit_signal("button_pushed")
|
||||
@ -34,6 +34,9 @@ func _on_ActivatorArea_area_exited(area:Area2D) -> void:
|
||||
unactivatable_timer.start()
|
||||
|
||||
func _on_Timer_timeout():
|
||||
for body in activatorArea.get_overlapping_bodies():
|
||||
if body.is_in_group("player"):
|
||||
return
|
||||
$Label.visible = false
|
||||
$Highlight.visible = false
|
||||
activatable = false
|
||||
|
||||
@ -7,7 +7,7 @@ onready var unactivatable_timer := $Timer
|
||||
|
||||
var activatable = false
|
||||
|
||||
func _process(delta):
|
||||
func _input(event: InputEvent) -> void:
|
||||
if activatable && Input.is_action_just_released("interact"):
|
||||
selfActivate()
|
||||
|
||||
@ -32,6 +32,9 @@ func _on_ActivatorArea_area_exited(area:Area2D) -> void:
|
||||
unactivatable_timer.start()
|
||||
|
||||
func _on_Timer_timeout():
|
||||
for body in activatorArea.get_overlapping_bodies():
|
||||
if body.is_in_group("player"):
|
||||
return
|
||||
$Label.visible = false
|
||||
$Highlight.visible = false
|
||||
activatable = false
|
||||
|
||||
@ -165,20 +165,20 @@ wait_time = 20.0
|
||||
position = Vector2( 0, -2.27374e-13 )
|
||||
|
||||
[node name="JumpTut" parent="Tutorials" instance=ExtResource( 15 )]
|
||||
position = Vector2( 1, 0 )
|
||||
position = Vector2( 659, -76 )
|
||||
tutorial_text = "Press to jump:"
|
||||
|
||||
[node name="Button" parent="Tutorials/JumpTut" index="0"]
|
||||
material = SubResource( 11 )
|
||||
|
||||
[node name="StartTutorialArea" parent="Tutorials/JumpTut" index="5"]
|
||||
position = Vector2( 562, -19 )
|
||||
position = Vector2( -55, 74 )
|
||||
|
||||
[node name="CollisionShape2D" parent="Tutorials/JumpTut/StartTutorialArea" index="0"]
|
||||
position = Vector2( -24.5, 0 )
|
||||
|
||||
[node name="LeftTut" parent="Tutorials" instance=ExtResource( 15 )]
|
||||
position = Vector2( -40, -14 )
|
||||
position = Vector2( -91, -80 )
|
||||
action = "move_left"
|
||||
tutorial_text = "Press to move left:"
|
||||
initial_wait_time = 4.0
|
||||
@ -190,11 +190,14 @@ material = SubResource( 12 )
|
||||
anims/RESET = SubResource( 7 )
|
||||
anims/cease_4_exist = SubResource( 8 )
|
||||
|
||||
[node name="StartTutorialArea" parent="Tutorials/LeftTut" index="5"]
|
||||
position = Vector2( 25, 39 )
|
||||
|
||||
[node name="CollisionShape2D" parent="Tutorials/LeftTut/StartTutorialArea" index="0"]
|
||||
position = Vector2( -24.5, 0 )
|
||||
|
||||
[node name="RightTut" parent="Tutorials" instance=ExtResource( 15 )]
|
||||
position = Vector2( -40, -56 )
|
||||
position = Vector2( 82, -78 )
|
||||
action = "move_right"
|
||||
tutorial_text = "Press to move right:"
|
||||
initial_wait_time = 2.0
|
||||
@ -206,6 +209,9 @@ material = SubResource( 13 )
|
||||
anims/RESET = SubResource( 9 )
|
||||
anims/cease_4_exist = SubResource( 10 )
|
||||
|
||||
[node name="StartTutorialArea" parent="Tutorials/RightTut" index="5"]
|
||||
position = Vector2( -114, 43 )
|
||||
|
||||
[node name="CollisionShape2D" parent="Tutorials/RightTut/StartTutorialArea" index="0"]
|
||||
position = Vector2( -24.5, 0 )
|
||||
|
||||
@ -219,7 +225,7 @@ position = Vector2( -70, 1 )
|
||||
scale = Vector2( 0.878906, 0.936025 )
|
||||
|
||||
[node name="BlobbySprite" parent="Blobby" index="5"]
|
||||
frame = 7
|
||||
frame = 5
|
||||
|
||||
[node name="BlobbymationTree" parent="Blobby/BlobbySprite" index="0"]
|
||||
parameters/playback = SubResource( 14 )
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=59 format=2]
|
||||
[gd_scene load_steps=61 format=2]
|
||||
|
||||
[ext_resource path="res://src/Levels/Templates/LevelTemplate.gd" type="Script" id=1]
|
||||
[ext_resource path="res://assets/environment/decor/platform-plants.png" type="Texture" id=2]
|
||||
@ -47,7 +47,63 @@
|
||||
0/shapes = [ ]
|
||||
0/z_index = 0
|
||||
|
||||
[sub_resource type="Shader" id=13]
|
||||
[sub_resource type="Shader" id=15]
|
||||
code = "shader_type canvas_item;
|
||||
|
||||
uniform sampler2D noise_tex_normal;
|
||||
uniform sampler2D noise_tex;
|
||||
uniform float progress : hint_range(0.0, 1.0);
|
||||
uniform float scale : hint_range(0.0, 100.0);
|
||||
uniform float strength = 1.0;
|
||||
|
||||
// If your sprite doesn't have enough space and the explosion gets clipped,
|
||||
// you can uncomment this and adjust the scale
|
||||
void vertex() {
|
||||
VERTEX *= scale;
|
||||
|
||||
UV *= scale;
|
||||
UV -= (scale - 1.0) / 2.0;
|
||||
}
|
||||
|
||||
void fragment() {
|
||||
vec2 direction = texture(noise_tex_normal, UV).xy; // We're using normal map as direction
|
||||
direction -= 0.5; // Since our normal map is a texture, it ranges from 0.0 to 1.0...
|
||||
direction *= 2.0; // ...so we're going to make it range from -1.0 to 1.0.
|
||||
direction = direction * strength * progress;
|
||||
|
||||
// UV for exploded texture
|
||||
vec2 tex_size = 1.0 / TEXTURE_PIXEL_SIZE; // Real texture size in pixels
|
||||
vec2 uv = floor(UV * tex_size) / (tex_size - 1.0); // Pixelate UV to snap pixels
|
||||
uv = uv - direction; // Distort UV
|
||||
|
||||
// Texture with exploded UV
|
||||
vec4 tex = texture(TEXTURE, uv);
|
||||
|
||||
// Dissolve alpha
|
||||
float dissolve = texture(noise_tex, UV).x;
|
||||
dissolve = step(progress, dissolve);
|
||||
tex.a *= dissolve;
|
||||
|
||||
// Border (in case the edge of your sprite stretches, otherwise you can remove this block)
|
||||
vec2 border_uv = uv * 2.0 - 1.0;
|
||||
border_uv = clamp(abs(border_uv), 0.0, 1.0);
|
||||
float border = max(border_uv.x, border_uv.y);
|
||||
border = ceil(1.0 - border);
|
||||
tex.a *= border;
|
||||
|
||||
COLOR = tex;
|
||||
}"
|
||||
|
||||
[sub_resource type="ShaderMaterial" id=48]
|
||||
resource_local_to_scene = true
|
||||
shader = SubResource( 15 )
|
||||
shader_param/progress = 0.0
|
||||
shader_param/scale = 1.0
|
||||
shader_param/strength = 0.1
|
||||
shader_param/noise_tex_normal = ExtResource( 17 )
|
||||
shader_param/noise_tex = ExtResource( 17 )
|
||||
|
||||
[sub_resource type="Shader" id=49]
|
||||
code = "shader_type canvas_item;
|
||||
|
||||
uniform sampler2D noise_tex_normal;
|
||||
@ -96,14 +152,14 @@ void fragment() {
|
||||
|
||||
[sub_resource type="ShaderMaterial" id=14]
|
||||
resource_local_to_scene = true
|
||||
shader = SubResource( 13 )
|
||||
shader = SubResource( 49 )
|
||||
shader_param/progress = 0.0
|
||||
shader_param/scale = 1.0
|
||||
shader_param/strength = 0.1
|
||||
shader_param/noise_tex_normal = ExtResource( 17 )
|
||||
shader_param/noise_tex = ExtResource( 17 )
|
||||
|
||||
[sub_resource type="Animation" id=15]
|
||||
[sub_resource type="Animation" id=50]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/path = NodePath(".:frame")
|
||||
@ -1043,7 +1099,7 @@ position = Vector2( -156, -51 )
|
||||
scale = Vector2( 0.878906, 0.936025 )
|
||||
|
||||
[node name="BlobbySprite" parent="Blobby" index="5"]
|
||||
frame = 5
|
||||
frame = 8
|
||||
|
||||
[node name="BlobbymationTree" parent="Blobby/BlobbySprite" index="0"]
|
||||
parameters/playback = SubResource( 6 )
|
||||
@ -1128,19 +1184,34 @@ position = Vector2( 6, -6 )
|
||||
|
||||
[node name="TutorialComboThingy" parent="." instance=ExtResource( 15 )]
|
||||
visible = false
|
||||
position = Vector2( 1104, -86 )
|
||||
position = Vector2( 1115, 4 )
|
||||
action1 = "boost_move"
|
||||
action2 = "move_right"
|
||||
press_limit = 2
|
||||
|
||||
[node name="Button1" parent="TutorialComboThingy" index="1"]
|
||||
material = SubResource( 48 )
|
||||
|
||||
[node name="Button2" parent="TutorialComboThingy" index="2"]
|
||||
material = SubResource( 48 )
|
||||
|
||||
[node name="StartTutorialArea" parent="TutorialComboThingy" index="9"]
|
||||
position = Vector2( -44, -83 )
|
||||
|
||||
[node name="TutorialThingy" parent="." instance=ExtResource( 16 )]
|
||||
position = Vector2( 1440, -90 )
|
||||
position = Vector2( 1441, -4 )
|
||||
action = "interact"
|
||||
tutorial_text = "Press to interact:"
|
||||
|
||||
[node name="Button" parent="TutorialThingy" index="0"]
|
||||
material = SubResource( 14 )
|
||||
|
||||
[node name="StartTutorialArea" parent="TutorialThingy" index="5"]
|
||||
position = Vector2( -2, -87 )
|
||||
|
||||
[node name="CollisionShape2D" parent="TutorialThingy/StartTutorialArea" index="0"]
|
||||
position = Vector2( 0, 9 )
|
||||
|
||||
[node name="SavePoint" parent="." instance=ExtResource( 18 )]
|
||||
position = Vector2( 1168, -88 )
|
||||
|
||||
@ -1169,7 +1240,7 @@ hframes = 30
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="Mine13/Sprite"]
|
||||
autoplay = "armed"
|
||||
anims/RESET = SubResource( 15 )
|
||||
anims/RESET = SubResource( 50 )
|
||||
anims/armed = SubResource( 16 )
|
||||
anims/arming = SubResource( 17 )
|
||||
anims/unarmed = SubResource( 18 )
|
||||
@ -1397,4 +1468,5 @@ position = Vector2( 360, 24 )
|
||||
[editable path="UserInterface/HUD"]
|
||||
[editable path="BlobbyCam"]
|
||||
[editable path="Blobby"]
|
||||
[editable path="TutorialComboThingy"]
|
||||
[editable path="TutorialThingy"]
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=24 format=2]
|
||||
[gd_scene load_steps=26 format=2]
|
||||
|
||||
[ext_resource path="res://assets/environment/decor/platform-plants.png" type="Texture" id=1]
|
||||
[ext_resource path="res://src/Contraptions/Triggers/ElevatorButton.tscn" type="PackedScene" id=2]
|
||||
@ -101,6 +101,62 @@ shader_param/strength = 0.1
|
||||
shader_param/noise_tex_normal = ExtResource( 19 )
|
||||
shader_param/noise_tex = ExtResource( 19 )
|
||||
|
||||
[sub_resource type="Shader" id=15]
|
||||
code = "shader_type canvas_item;
|
||||
|
||||
uniform sampler2D noise_tex_normal;
|
||||
uniform sampler2D noise_tex;
|
||||
uniform float progress : hint_range(0.0, 1.0);
|
||||
uniform float scale : hint_range(0.0, 100.0);
|
||||
uniform float strength = 1.0;
|
||||
|
||||
// If your sprite doesn't have enough space and the explosion gets clipped,
|
||||
// you can uncomment this and adjust the scale
|
||||
void vertex() {
|
||||
VERTEX *= scale;
|
||||
|
||||
UV *= scale;
|
||||
UV -= (scale - 1.0) / 2.0;
|
||||
}
|
||||
|
||||
void fragment() {
|
||||
vec2 direction = texture(noise_tex_normal, UV).xy; // We're using normal map as direction
|
||||
direction -= 0.5; // Since our normal map is a texture, it ranges from 0.0 to 1.0...
|
||||
direction *= 2.0; // ...so we're going to make it range from -1.0 to 1.0.
|
||||
direction = direction * strength * progress;
|
||||
|
||||
// UV for exploded texture
|
||||
vec2 tex_size = 1.0 / TEXTURE_PIXEL_SIZE; // Real texture size in pixels
|
||||
vec2 uv = floor(UV * tex_size) / (tex_size - 1.0); // Pixelate UV to snap pixels
|
||||
uv = uv - direction; // Distort UV
|
||||
|
||||
// Texture with exploded UV
|
||||
vec4 tex = texture(TEXTURE, uv);
|
||||
|
||||
// Dissolve alpha
|
||||
float dissolve = texture(noise_tex, UV).x;
|
||||
dissolve = step(progress, dissolve);
|
||||
tex.a *= dissolve;
|
||||
|
||||
// Border (in case the edge of your sprite stretches, otherwise you can remove this block)
|
||||
vec2 border_uv = uv * 2.0 - 1.0;
|
||||
border_uv = clamp(abs(border_uv), 0.0, 1.0);
|
||||
float border = max(border_uv.x, border_uv.y);
|
||||
border = ceil(1.0 - border);
|
||||
tex.a *= border;
|
||||
|
||||
COLOR = tex;
|
||||
}"
|
||||
|
||||
[sub_resource type="ShaderMaterial" id=16]
|
||||
resource_local_to_scene = true
|
||||
shader = SubResource( 15 )
|
||||
shader_param/progress = 0.0
|
||||
shader_param/scale = 1.0
|
||||
shader_param/strength = 0.1
|
||||
shader_param/noise_tex_normal = ExtResource( 19 )
|
||||
shader_param/noise_tex = ExtResource( 19 )
|
||||
|
||||
[node name="LevelTemplate" type="Node2D"]
|
||||
script = ExtResource( 11 )
|
||||
__meta__ = {
|
||||
@ -132,7 +188,7 @@ position = Vector2( -180, 113 )
|
||||
scale = Vector2( 0.878906, 0.936025 )
|
||||
|
||||
[node name="BlobbySprite" parent="Blobby" index="5"]
|
||||
frame = 7
|
||||
frame = 10
|
||||
|
||||
[node name="BlobbymationTree" parent="Blobby/BlobbySprite" index="0"]
|
||||
parameters/playback = SubResource( 6 )
|
||||
@ -197,7 +253,7 @@ y_target = 112
|
||||
|
||||
[node name="TutorialComboThingy" parent="." instance=ExtResource( 18 )]
|
||||
visible = false
|
||||
position = Vector2( 177, 8 )
|
||||
position = Vector2( 276, -35 )
|
||||
action1 = "boost_move"
|
||||
action2 = "jump"
|
||||
goal_state = "runToJump"
|
||||
@ -211,17 +267,26 @@ material = SubResource( 14 )
|
||||
material = SubResource( 14 )
|
||||
|
||||
[node name="CollisionShape2D" parent="TutorialComboThingy/StartTutorialArea" index="0"]
|
||||
position = Vector2( 118, 31 )
|
||||
position = Vector2( -10, 75 )
|
||||
|
||||
[node name="TutorialComboThingy2" parent="." instance=ExtResource( 18 )]
|
||||
visible = false
|
||||
position = Vector2( 518, -187 )
|
||||
position = Vector2( 381, -230 )
|
||||
action1 = "boost_move"
|
||||
action2 = "jump"
|
||||
goal_state = "runToJump"
|
||||
tutorial_text = "Move and press to runjump:"
|
||||
press_limit = 1
|
||||
|
||||
[node name="Button1" parent="TutorialComboThingy2" index="1"]
|
||||
material = SubResource( 16 )
|
||||
|
||||
[node name="Button2" parent="TutorialComboThingy2" index="2"]
|
||||
material = SubResource( 16 )
|
||||
|
||||
[node name="StartTutorialArea" parent="TutorialComboThingy2" index="9"]
|
||||
position = Vector2( 111, 76 )
|
||||
|
||||
[node name="Decor" type="Node2D" parent="."]
|
||||
|
||||
[node name="ShaderGrass" parent="Decor" instance=ExtResource( 3 )]
|
||||
@ -597,3 +662,4 @@ position = Vector2( 110, 100 )
|
||||
[editable path="Blobby"]
|
||||
[editable path="FlyingPlatform2"]
|
||||
[editable path="TutorialComboThingy"]
|
||||
[editable path="TutorialComboThingy2"]
|
||||
|
||||
@ -74,6 +74,9 @@ unique_name_in_owner = true
|
||||
position = Vector2( -186, 113 )
|
||||
scale = Vector2( 0.878906, 0.936025 )
|
||||
|
||||
[node name="BlobbySprite" parent="Blobby" index="5"]
|
||||
frame = 7
|
||||
|
||||
[node name="BlobbymationTree" parent="Blobby/BlobbySprite" index="0"]
|
||||
parameters/playback = SubResource( 7 )
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=23 format=2]
|
||||
[gd_scene load_steps=26 format=2]
|
||||
|
||||
[ext_resource path="res://src/Actors/Enemies/DartingEnemy.tscn" type="PackedScene" id=1]
|
||||
[ext_resource path="res://src/Utilities/SignalManager.tscn" type="PackedScene" id=2]
|
||||
@ -21,9 +21,66 @@
|
||||
[ext_resource path="res://src/Levels/Templates/LevelTemplate.gd" type="Script" id=19]
|
||||
[ext_resource path="res://src/Environment/Grass/ShaderGrass.tscn" type="PackedScene" id=20]
|
||||
[ext_resource path="res://src/Environment/Legacy/Greenhouse.tscn" type="PackedScene" id=21]
|
||||
[ext_resource path="res://assets/effects/noise.png" type="Texture" id=22]
|
||||
|
||||
[sub_resource type="AnimationNodeStateMachinePlayback" id=1]
|
||||
|
||||
[sub_resource type="Shader" id=15]
|
||||
code = "shader_type canvas_item;
|
||||
|
||||
uniform sampler2D noise_tex_normal;
|
||||
uniform sampler2D noise_tex;
|
||||
uniform float progress : hint_range(0.0, 1.0);
|
||||
uniform float scale : hint_range(0.0, 100.0);
|
||||
uniform float strength = 1.0;
|
||||
|
||||
// If your sprite doesn't have enough space and the explosion gets clipped,
|
||||
// you can uncomment this and adjust the scale
|
||||
void vertex() {
|
||||
VERTEX *= scale;
|
||||
|
||||
UV *= scale;
|
||||
UV -= (scale - 1.0) / 2.0;
|
||||
}
|
||||
|
||||
void fragment() {
|
||||
vec2 direction = texture(noise_tex_normal, UV).xy; // We're using normal map as direction
|
||||
direction -= 0.5; // Since our normal map is a texture, it ranges from 0.0 to 1.0...
|
||||
direction *= 2.0; // ...so we're going to make it range from -1.0 to 1.0.
|
||||
direction = direction * strength * progress;
|
||||
|
||||
// UV for exploded texture
|
||||
vec2 tex_size = 1.0 / TEXTURE_PIXEL_SIZE; // Real texture size in pixels
|
||||
vec2 uv = floor(UV * tex_size) / (tex_size - 1.0); // Pixelate UV to snap pixels
|
||||
uv = uv - direction; // Distort UV
|
||||
|
||||
// Texture with exploded UV
|
||||
vec4 tex = texture(TEXTURE, uv);
|
||||
|
||||
// Dissolve alpha
|
||||
float dissolve = texture(noise_tex, UV).x;
|
||||
dissolve = step(progress, dissolve);
|
||||
tex.a *= dissolve;
|
||||
|
||||
// Border (in case the edge of your sprite stretches, otherwise you can remove this block)
|
||||
vec2 border_uv = uv * 2.0 - 1.0;
|
||||
border_uv = clamp(abs(border_uv), 0.0, 1.0);
|
||||
float border = max(border_uv.x, border_uv.y);
|
||||
border = ceil(1.0 - border);
|
||||
tex.a *= border;
|
||||
|
||||
COLOR = tex;
|
||||
}"
|
||||
|
||||
[sub_resource type="ShaderMaterial" id=16]
|
||||
resource_local_to_scene = true
|
||||
shader = SubResource( 15 )
|
||||
shader_param/progress = 0.0
|
||||
shader_param/scale = 1.0
|
||||
shader_param/strength = 0.1
|
||||
shader_param/noise_tex_normal = ExtResource( 22 )
|
||||
shader_param/noise_tex = ExtResource( 22 )
|
||||
|
||||
[node name="LevelTemplate" type="Node2D"]
|
||||
script = ExtResource( 19 )
|
||||
__meta__ = {
|
||||
@ -55,7 +112,7 @@ position = Vector2( 251, -24 )
|
||||
scale = Vector2( 0.878906, 0.936025 )
|
||||
|
||||
[node name="BlobbySprite" parent="Blobby" index="5"]
|
||||
frame = 5
|
||||
frame = 10
|
||||
|
||||
[node name="BlobbymationTree" parent="Blobby/BlobbySprite" index="0"]
|
||||
parameters/playback = SubResource( 1 )
|
||||
@ -85,12 +142,21 @@ max_speed = 110
|
||||
|
||||
[node name="TutorialComboThingy" parent="." instance=ExtResource( 16 )]
|
||||
visible = false
|
||||
position = Vector2( 432, 135 )
|
||||
position = Vector2( 429, 87 )
|
||||
action1 = "duck"
|
||||
action2 = "jump"
|
||||
goal_state = "ducking"
|
||||
tutorial_text = "duck and jump to fall through"
|
||||
|
||||
[node name="Button1" parent="TutorialComboThingy" index="1"]
|
||||
material = SubResource( 16 )
|
||||
|
||||
[node name="Button2" parent="TutorialComboThingy" index="2"]
|
||||
material = SubResource( 16 )
|
||||
|
||||
[node name="StartTutorialArea" parent="TutorialComboThingy" index="9"]
|
||||
position = Vector2( 6, 48 )
|
||||
|
||||
[node name="DropThroughPlatform" parent="." instance=ExtResource( 7 )]
|
||||
tile_data = PoolIntArray( 786466, 1, 0, 786467, 0, 0, 786469, 2, 0 )
|
||||
|
||||
@ -475,6 +541,7 @@ scale = Vector2( 1, 1.5 )
|
||||
[editable path="UserInterface/PauseScreen"]
|
||||
[editable path="BlobbyCam"]
|
||||
[editable path="Blobby"]
|
||||
[editable path="TutorialComboThingy"]
|
||||
[editable path="DartingEnemy"]
|
||||
[editable path="TileMap"]
|
||||
[editable path="BoundFrog"]
|
||||
|
||||
@ -15,7 +15,7 @@ func _ready() -> void:
|
||||
signal_manager.connect("terminal_activated", self, "stop_level_music")
|
||||
signal_manager.emit_signal("level_loaded")
|
||||
get_tree().paused = false
|
||||
$SceneAudio.play_parallel_sound(level_music, level_music_attenuation)
|
||||
$SceneAudio.play_parallel_sound(level_music, level_music_attenuation, false, 1.0, 0, "Music")
|
||||
$SceneAudio.play_parallel_sound(level_ambiance, level_ambiance_attenuation)
|
||||
|
||||
|
||||
|
||||
@ -58,9 +58,9 @@ script = ExtResource( 1 )
|
||||
|
||||
[node name="PlatformBody" type="KinematicBody2D" parent="."]
|
||||
collision_layer = 16
|
||||
collision_mask = 0
|
||||
collision/safe_margin = 0.001
|
||||
collision_mask = 3
|
||||
motion/sync_to_physics = true
|
||||
moving_platform_apply_velocity_on_leave = 2
|
||||
|
||||
[node name="FlyingSound" type="AudioStreamPlayer2D" parent="PlatformBody"]
|
||||
stream = ExtResource( 3 )
|
||||
|
||||
@ -70,9 +70,9 @@ script = ExtResource( 1 )
|
||||
|
||||
[node name="PlatformBody" type="KinematicBody2D" parent="."]
|
||||
collision_layer = 16
|
||||
collision_mask = 0
|
||||
collision/safe_margin = 0.001
|
||||
collision_mask = 3
|
||||
motion/sync_to_physics = true
|
||||
moving_platform_apply_velocity_on_leave = 2
|
||||
|
||||
[node name="Sprite" type="Sprite" parent="PlatformBody"]
|
||||
position = Vector2( 0, 8 )
|
||||
|
||||
@ -41,12 +41,12 @@ resource_name = "LowPassFilter"
|
||||
cutoff_hz = 3000.0
|
||||
|
||||
[resource]
|
||||
bus/0/volume_db = -13.9794
|
||||
bus/0/volume_db = -14.4249
|
||||
bus/1/name = "Music"
|
||||
bus/1/solo = false
|
||||
bus/1/mute = false
|
||||
bus/1/bypass_fx = false
|
||||
bus/1/volume_db = -16.4782
|
||||
bus/1/volume_db = -7.9588
|
||||
bus/1/send = "Master"
|
||||
bus/1/effect/0/effect = SubResource( 1 )
|
||||
bus/1/effect/0/enabled = false
|
||||
@ -56,7 +56,7 @@ bus/2/name = "Effects"
|
||||
bus/2/solo = false
|
||||
bus/2/mute = false
|
||||
bus/2/bypass_fx = false
|
||||
bus/2/volume_db = -6.0206
|
||||
bus/2/volume_db = -1.9382
|
||||
bus/2/send = "Master"
|
||||
bus/2/effect/0/effect = SubResource( 3 )
|
||||
bus/2/effect/0/enabled = false
|
||||
|
||||
@ -6,6 +6,7 @@ export var tutorial_text = ""
|
||||
export var velocity = Vector2(0.309,0.309)
|
||||
export var press_limit = 3
|
||||
export var initial_wait_time:float = 0.0
|
||||
export var start_moving_time: float = 30.0
|
||||
|
||||
onready var level_state := get_tree().root.get_child(4).get_node("%LevelState")
|
||||
onready var cam = null
|
||||
@ -62,6 +63,7 @@ func _ready() -> void:
|
||||
button2.scale.y = 0.5
|
||||
tex_size = Vector2(button1.texture.get_width(), button1.texture.get_height()/2) * button1.scale * 0.75
|
||||
$Area/CollisionShape2D.shape.extents = tex_size
|
||||
$Area.monitorable = false
|
||||
set_physics_process(true)
|
||||
|
||||
func finished_waiting() -> void:
|
||||
@ -112,8 +114,8 @@ func _lesson_learned(animation_name: String) -> void:
|
||||
|
||||
func start_tutorial():
|
||||
rng.randomize()
|
||||
position.x += rng.randf_range(-100, 100)
|
||||
position.y += rng.randf_range(-100, 100)
|
||||
#position.x += rng.randf_range(-100, 100)
|
||||
#position.y += rng.randf_range(-100, 100)
|
||||
velocity.x = velocity.x * sign(rng.randf_range(-1,1))
|
||||
velocity.y = velocity.y * sign(rng.randf_range(-1,1))
|
||||
tutorial_begun = true
|
||||
@ -123,6 +125,17 @@ func start_tutorial():
|
||||
timer.one_shot = true
|
||||
timer.connect("timeout", self, "enable_visibility")
|
||||
timer.start()
|
||||
|
||||
var start_moving_timer = Timer.new()
|
||||
add_child(start_moving_timer)
|
||||
start_moving_timer.wait_time = start_moving_time
|
||||
start_moving_timer.one_shot = true
|
||||
start_moving_timer.connect("timeout", self, "start_moving")
|
||||
start_moving_timer.start()
|
||||
|
||||
|
||||
func start_moving() -> void:
|
||||
$Area.monitorable = true
|
||||
moving = true
|
||||
|
||||
func enable_visibility() -> void:
|
||||
|
||||
@ -9,7 +9,7 @@
|
||||
[ext_resource path="res://assets/sounds/vibing.wav" type="AudioStream" id=7]
|
||||
[ext_resource path="res://assets/effects/noise.png" type="Texture" id=8]
|
||||
|
||||
[sub_resource type="Shader" id=13]
|
||||
[sub_resource type="Shader" id=15]
|
||||
code = "shader_type canvas_item;
|
||||
|
||||
uniform sampler2D noise_tex_normal;
|
||||
@ -58,7 +58,7 @@ void fragment() {
|
||||
|
||||
[sub_resource type="ShaderMaterial" id=12]
|
||||
resource_local_to_scene = true
|
||||
shader = SubResource( 13 )
|
||||
shader = SubResource( 15 )
|
||||
shader_param/progress = 0.0
|
||||
shader_param/scale = 1.0
|
||||
shader_param/strength = 0.1
|
||||
@ -81,12 +81,12 @@ fill_to = Vector2( 0.155994, 0.791965 )
|
||||
size = 14
|
||||
font_data = ExtResource( 2 )
|
||||
|
||||
[sub_resource type="Gradient" id=15]
|
||||
[sub_resource type="Gradient" id=16]
|
||||
interpolation_mode = 2
|
||||
colors = PoolColorArray( 1, 1, 1, 1, 0, 0, 0, 0 )
|
||||
|
||||
[sub_resource type="GradientTexture2D" id=11]
|
||||
gradient = SubResource( 15 )
|
||||
gradient = SubResource( 16 )
|
||||
width = 100
|
||||
height = 100
|
||||
use_hdr = true
|
||||
|
||||
@ -4,6 +4,7 @@ export var tutorial_text = ""
|
||||
export var velocity = Vector2(0.309, 0.309)
|
||||
export var press_limit = 3
|
||||
export var initial_wait_time: float = 0.0
|
||||
export var start_moving_time: float = 30.0
|
||||
|
||||
var screen_size: Vector2
|
||||
var tex_size: Vector2
|
||||
@ -53,6 +54,7 @@ func _ready() -> void:
|
||||
* 0.75
|
||||
)
|
||||
$Area/CollisionShape2D.shape.extents = tex_size
|
||||
$Area.monitorable = false
|
||||
|
||||
|
||||
func finished_waiting() -> void:
|
||||
@ -115,10 +117,10 @@ func _lesson_learned(animation_name: String) -> void:
|
||||
func start_tutorial() -> void:
|
||||
var rng = RandomNumberGenerator.new()
|
||||
rng.randomize()
|
||||
position = cam.get_global_transform() * position
|
||||
position.x += rng.randf_range(-50, 50)
|
||||
position.y += rng.randf_range(-50, 50)
|
||||
print(position)
|
||||
#position = cam.get_global_transform() * position
|
||||
#position.x += prev_spawn_position.x + rng.randf_range(-40, 40)
|
||||
#position.y += prev_spawn_position.y + rng.randf_range(-40, 40)
|
||||
#prev_spawn_position = position
|
||||
velocity.x = velocity.x * sign(rng.randf_range(-1, 1))
|
||||
velocity.y = velocity.y * sign(rng.randf_range(-1, 1))
|
||||
tutorial_begun = true
|
||||
@ -128,6 +130,16 @@ func start_tutorial() -> void:
|
||||
timer.one_shot = true
|
||||
timer.connect("timeout", self, "enable_visibility")
|
||||
timer.start()
|
||||
|
||||
var start_moving_timer = Timer.new()
|
||||
add_child(start_moving_timer)
|
||||
start_moving_timer.wait_time = start_moving_time
|
||||
start_moving_timer.one_shot = true
|
||||
start_moving_timer.connect("timeout", self, "start_moving")
|
||||
start_moving_timer.start()
|
||||
|
||||
func start_moving() -> void:
|
||||
$Area.monitorable = true
|
||||
moving = true
|
||||
|
||||
func enable_visibility() -> void:
|
||||
|
||||
@ -136,7 +136,7 @@ tracks/1/keys = {
|
||||
}
|
||||
|
||||
[sub_resource type="RectangleShape2D" id=6]
|
||||
extents = Vector2( 62, 71 )
|
||||
extents = Vector2( 29, 39 )
|
||||
|
||||
[node name="TutorialThingy" type="Node2D"]
|
||||
physics_interpolation_mode = 1
|
||||
|
||||
Loading…
Reference in New Issue
Block a user