generated from krampus/template-godot4
Save icon is displayed while saving
This commit is contained in:
parent
7957a47243
commit
22a22a6409
BIN
asset_dev/ui/corpo_logo.xcf
Normal file
BIN
asset_dev/ui/corpo_logo.xcf
Normal file
Binary file not shown.
BIN
assets/ui/corpo_logo/corpo_logo_128.png
(Stored with Git LFS)
Normal file
BIN
assets/ui/corpo_logo/corpo_logo_128.png
(Stored with Git LFS)
Normal file
Binary file not shown.
34
assets/ui/corpo_logo/corpo_logo_128.png.import
Normal file
34
assets/ui/corpo_logo/corpo_logo_128.png.import
Normal file
@ -0,0 +1,34 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dixpjnlaj86x2"
|
||||
path="res://.godot/imported/corpo_logo_128.png-3de86c663523882d9e0ebffd7de5c43c.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://assets/ui/corpo_logo/corpo_logo_128.png"
|
||||
dest_files=["res://.godot/imported/corpo_logo_128.png-3de86c663523882d9e0ebffd7de5c43c.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=0
|
BIN
assets/ui/corpo_logo/corpo_logo_128_bg.png
(Stored with Git LFS)
Normal file
BIN
assets/ui/corpo_logo/corpo_logo_128_bg.png
(Stored with Git LFS)
Normal file
Binary file not shown.
34
assets/ui/corpo_logo/corpo_logo_128_bg.png.import
Normal file
34
assets/ui/corpo_logo/corpo_logo_128_bg.png.import
Normal file
@ -0,0 +1,34 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://b7ds08rj0yk7j"
|
||||
path="res://.godot/imported/corpo_logo_128_bg.png-89eb09aa3ea1cb5cb304d1d6904ce810.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://assets/ui/corpo_logo/corpo_logo_128_bg.png"
|
||||
dest_files=["res://.godot/imported/corpo_logo_128_bg.png-89eb09aa3ea1cb5cb304d1d6904ce810.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=0
|
BIN
assets/ui/corpo_logo/corpo_logo_256.png
(Stored with Git LFS)
Normal file
BIN
assets/ui/corpo_logo/corpo_logo_256.png
(Stored with Git LFS)
Normal file
Binary file not shown.
34
assets/ui/corpo_logo/corpo_logo_256.png.import
Normal file
34
assets/ui/corpo_logo/corpo_logo_256.png.import
Normal file
@ -0,0 +1,34 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dbr66ubeql7gi"
|
||||
path="res://.godot/imported/corpo_logo_256.png-58bfe662ab369a650f7147768bd46884.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://assets/ui/corpo_logo/corpo_logo_256.png"
|
||||
dest_files=["res://.godot/imported/corpo_logo_256.png-58bfe662ab369a650f7147768bd46884.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=0
|
BIN
assets/ui/corpo_logo/corpo_logo_512.png
(Stored with Git LFS)
Normal file
BIN
assets/ui/corpo_logo/corpo_logo_512.png
(Stored with Git LFS)
Normal file
Binary file not shown.
34
assets/ui/corpo_logo/corpo_logo_512.png.import
Normal file
34
assets/ui/corpo_logo/corpo_logo_512.png.import
Normal file
@ -0,0 +1,34 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://cbosbnfdmhu27"
|
||||
path="res://.godot/imported/corpo_logo_512.png-b05524db051b0e137f14c9416740afff.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://assets/ui/corpo_logo/corpo_logo_512.png"
|
||||
dest_files=["res://.godot/imported/corpo_logo_512.png-b05524db051b0e137f14c9416740afff.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/hdr_compression=1
|
||||
compress/normal_map=0
|
||||
compress/channel_pack=0
|
||||
mipmaps/generate=false
|
||||
mipmaps/limit=-1
|
||||
roughness/mode=0
|
||||
roughness/src_normal=""
|
||||
process/fix_alpha_border=true
|
||||
process/premult_alpha=false
|
||||
process/normal_map_invert_y=false
|
||||
process/hdr_as_srgb=false
|
||||
process/hdr_clamp_exposure=false
|
||||
process/size_limit=0
|
||||
detect_3d/compress_to=0
|
12
src/effects/grunk_2d/grunk_2d.gd
Normal file
12
src/effects/grunk_2d/grunk_2d.gd
Normal file
@ -0,0 +1,12 @@
|
||||
@tool
|
||||
extends ColorRect
|
||||
|
||||
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
func _ready() -> void:
|
||||
_update_aspect_ratio()
|
||||
|
||||
|
||||
func _update_aspect_ratio() -> void:
|
||||
var aspect_ratio := size.y / size.x
|
||||
(material as ShaderMaterial).set_shader_parameter("aspect_ratio", aspect_ratio)
|
1
src/effects/grunk_2d/grunk_2d.gd.uid
Normal file
1
src/effects/grunk_2d/grunk_2d.gd.uid
Normal file
@ -0,0 +1 @@
|
||||
uid://06n7qs3l4tf6
|
58
src/effects/grunk_2d/grunk_2d.tscn
Normal file
58
src/effects/grunk_2d/grunk_2d.tscn
Normal file
@ -0,0 +1,58 @@
|
||||
[gd_scene load_steps=9 format=3 uid="uid://b6dx0ovy15g5o"]
|
||||
|
||||
[ext_resource type="Shader" uid="uid://dnytoirugot2e" path="res://src/shaders/canvas_grunk.gdshader" id="1_pgbvb"]
|
||||
[ext_resource type="FastNoiseLite" uid="uid://cnlvdtx68giv6" path="res://assets/materials/gunk_noise.tres" id="2_g1nf5"]
|
||||
[ext_resource type="Script" uid="uid://06n7qs3l4tf6" path="res://src/effects/grunk_2d/grunk_2d.gd" id="3_g1nf5"]
|
||||
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_7v5ka"]
|
||||
width = 256
|
||||
height = 256
|
||||
seamless = true
|
||||
seamless_blend_skirt = 0.5
|
||||
noise = ExtResource("2_g1nf5")
|
||||
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_d72jk"]
|
||||
width = 256
|
||||
height = 256
|
||||
seamless = true
|
||||
seamless_blend_skirt = 0.5
|
||||
noise = ExtResource("2_g1nf5")
|
||||
|
||||
[sub_resource type="FastNoiseLite" id="FastNoiseLite_qsvii"]
|
||||
frequency = 0.0006
|
||||
fractal_type = 2
|
||||
fractal_octaves = 4
|
||||
fractal_gain = 0.667
|
||||
domain_warp_type = 2
|
||||
|
||||
[sub_resource type="NoiseTexture2D" id="NoiseTexture2D_pgbvb"]
|
||||
width = 1024
|
||||
height = 1024
|
||||
noise = SubResource("FastNoiseLite_qsvii")
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_rq45f"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("1_pgbvb")
|
||||
shader_parameter/color_1 = Color(0, 0.03, 0.1, 1)
|
||||
shader_parameter/color_2 = Color(0, 0.1, 0.3, 1)
|
||||
shader_parameter/emission_color = Color(0.25, 0.88, 1, 1)
|
||||
shader_parameter/pixellation = 30.0
|
||||
shader_parameter/time_pixellation = 30.0
|
||||
shader_parameter/emission_strength = 0.05
|
||||
shader_parameter/aspect_ratio = 0.5625
|
||||
shader_parameter/time_scale = 0.01
|
||||
shader_parameter/gunk_noise = SubResource("NoiseTexture3D_7v5ka")
|
||||
shader_parameter/gunk_normal_map = SubResource("NoiseTexture3D_d72jk")
|
||||
shader_parameter/mask_progress = 1.0
|
||||
shader_parameter/mask_noise = SubResource("NoiseTexture2D_pgbvb")
|
||||
|
||||
[node name="Grunk2D" type="ColorRect"]
|
||||
material = SubResource("ShaderMaterial_rq45f")
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
script = ExtResource("3_g1nf5")
|
||||
|
||||
[connection signal="item_rect_changed" from="." to="." method="_update_aspect_ratio"]
|
@ -11,8 +11,7 @@ uniform float time_pixellation = 30.0;
|
||||
|
||||
uniform float emission_strength = 0.05;
|
||||
|
||||
// Used ONLY by the gunk, does not affect the gunk mask.
|
||||
uniform vec2 uv_scale = vec2(1.0);
|
||||
uniform float aspect_ratio = 1.0;
|
||||
|
||||
uniform float time_scale = 1.0;
|
||||
|
||||
@ -29,9 +28,8 @@ float hardstep(float value) {
|
||||
}
|
||||
|
||||
void fragment() {
|
||||
vec2 aspect_ratio = vec2(SCREEN_PIXEL_SIZE.y / SCREEN_PIXEL_SIZE.x, 1.0);
|
||||
vec2 scaled_pixellation = pixellation * aspect_ratio;
|
||||
vec2 local_uv = floor(UV * uv_scale * scaled_pixellation) / scaled_pixellation;
|
||||
vec2 scaled_pixellation = pixellation * vec2(1.0, aspect_ratio);
|
||||
vec2 local_uv = floor(UV * scaled_pixellation) / scaled_pixellation;
|
||||
float local_time = floor(TIME * time_scale * time_pixellation) / time_pixellation;
|
||||
|
||||
// swirl
|
||||
|
76
src/ui/elements/save_icon/save_icon.tscn
Normal file
76
src/ui/elements/save_icon/save_icon.tscn
Normal file
@ -0,0 +1,76 @@
|
||||
[gd_scene load_steps=12 format=3 uid="uid://brknr57xc2cp0"]
|
||||
|
||||
[ext_resource type="Texture2D" uid="uid://b7ds08rj0yk7j" path="res://assets/ui/corpo_logo/corpo_logo_128_bg.png" id="1_1oh6t"]
|
||||
[ext_resource type="Texture2D" uid="uid://dixpjnlaj86x2" path="res://assets/ui/corpo_logo/corpo_logo_128.png" id="1_p2l3a"]
|
||||
[ext_resource type="Shader" uid="uid://dnytoirugot2e" path="res://src/shaders/canvas_grunk.gdshader" id="2_q367f"]
|
||||
[ext_resource type="FastNoiseLite" uid="uid://cnlvdtx68giv6" path="res://assets/materials/gunk_noise.tres" id="3_8o5hc"]
|
||||
[ext_resource type="PackedScene" uid="uid://b6dx0ovy15g5o" path="res://src/effects/grunk_2d/grunk_2d.tscn" id="5_xrtbx"]
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_8o5hc"]
|
||||
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_7v5ka"]
|
||||
width = 256
|
||||
height = 256
|
||||
seamless = true
|
||||
seamless_blend_skirt = 0.5
|
||||
noise = ExtResource("3_8o5hc")
|
||||
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_d72jk"]
|
||||
width = 256
|
||||
height = 256
|
||||
seamless = true
|
||||
seamless_blend_skirt = 0.5
|
||||
noise = ExtResource("3_8o5hc")
|
||||
|
||||
[sub_resource type="FastNoiseLite" id="FastNoiseLite_qsvii"]
|
||||
frequency = 0.0006
|
||||
fractal_type = 2
|
||||
fractal_octaves = 4
|
||||
fractal_gain = 0.667
|
||||
domain_warp_type = 2
|
||||
|
||||
[sub_resource type="NoiseTexture2D" id="NoiseTexture2D_pgbvb"]
|
||||
width = 1024
|
||||
height = 1024
|
||||
noise = SubResource("FastNoiseLite_qsvii")
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_t8g1i"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("2_q367f")
|
||||
shader_parameter/color_1 = Color(0, 0, 0, 1)
|
||||
shader_parameter/color_2 = Color(0.137255, 0.984314, 0.34902, 1)
|
||||
shader_parameter/emission_color = Color(0.486275, 1, 0.25098, 1)
|
||||
shader_parameter/pixellation = 32.0
|
||||
shader_parameter/time_pixellation = 60.0
|
||||
shader_parameter/emission_strength = 0.05
|
||||
shader_parameter/aspect_ratio = 1.0
|
||||
shader_parameter/time_scale = 1.0
|
||||
shader_parameter/gunk_noise = SubResource("NoiseTexture3D_7v5ka")
|
||||
shader_parameter/gunk_normal_map = SubResource("NoiseTexture3D_d72jk")
|
||||
shader_parameter/mask_progress = 1.0
|
||||
shader_parameter/mask_noise = SubResource("NoiseTexture2D_pgbvb")
|
||||
|
||||
[node name="SaveIcon" type="MarginContainer"]
|
||||
offset_right = 40.0
|
||||
offset_bottom = 40.0
|
||||
|
||||
[node name="IconBG" type="TextureRect" parent="."]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 4
|
||||
size_flags_vertical = 4
|
||||
texture = ExtResource("1_1oh6t")
|
||||
stretch_mode = 2
|
||||
|
||||
[node name="SaveIcon" type="TextureRect" parent="."]
|
||||
clip_children = 2
|
||||
texture_filter = 3
|
||||
material = SubResource("ShaderMaterial_8o5hc")
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 4
|
||||
size_flags_vertical = 4
|
||||
texture = ExtResource("1_p2l3a")
|
||||
stretch_mode = 2
|
||||
|
||||
[node name="Grunk2D" parent="SaveIcon" instance=ExtResource("5_xrtbx")]
|
||||
material = SubResource("ShaderMaterial_t8g1i")
|
||||
layout_mode = 1
|
@ -1,18 +1,19 @@
|
||||
[gd_scene load_steps=13 format=3 uid="uid://c0uitm5cg88h1"]
|
||||
[gd_scene load_steps=14 format=3 uid="uid://c0uitm5cg88h1"]
|
||||
|
||||
[ext_resource type="Shader" uid="uid://dnytoirugot2e" path="res://src/shaders/canvas_grunk.gdshader" id="1_28vyc"]
|
||||
[ext_resource type="PackedScene" uid="uid://b6dx0ovy15g5o" path="res://src/effects/grunk_2d/grunk_2d.tscn" id="1_sv5d8"]
|
||||
[ext_resource type="FastNoiseLite" uid="uid://cnlvdtx68giv6" path="res://assets/materials/gunk_noise.tres" id="2_qsvii"]
|
||||
[ext_resource type="Theme" uid="uid://b07fevr214mmr" path="res://src/ui/hud/hud_theme.tres" id="3_a6m17"]
|
||||
[ext_resource type="Script" uid="uid://cjs2fen6jo0g0" path="res://src/ui/rumbler.gd" id="4_sv5d8"]
|
||||
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_et0xc"]
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_7v5ka"]
|
||||
width = 256
|
||||
height = 256
|
||||
seamless = true
|
||||
seamless_blend_skirt = 0.5
|
||||
noise = ExtResource("2_qsvii")
|
||||
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_a6m17"]
|
||||
[sub_resource type="NoiseTexture3D" id="NoiseTexture3D_d72jk"]
|
||||
width = 256
|
||||
height = 256
|
||||
seamless = true
|
||||
@ -26,12 +27,13 @@ fractal_octaves = 4
|
||||
fractal_gain = 0.667
|
||||
domain_warp_type = 2
|
||||
|
||||
[sub_resource type="NoiseTexture2D" id="NoiseTexture2D_et0xc"]
|
||||
[sub_resource type="NoiseTexture2D" id="NoiseTexture2D_pgbvb"]
|
||||
width = 1024
|
||||
height = 1024
|
||||
noise = SubResource("FastNoiseLite_qsvii")
|
||||
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_qsvii"]
|
||||
[sub_resource type="ShaderMaterial" id="ShaderMaterial_3jt4s"]
|
||||
resource_local_to_scene = true
|
||||
shader = ExtResource("1_28vyc")
|
||||
shader_parameter/color_1 = Color(0, 0.03, 0.1, 1)
|
||||
shader_parameter/color_2 = Color(0, 0.1, 0.3, 1)
|
||||
@ -39,12 +41,51 @@ shader_parameter/emission_color = Color(0.25, 0.88, 1, 1)
|
||||
shader_parameter/pixellation = 50.0
|
||||
shader_parameter/time_pixellation = 30.0
|
||||
shader_parameter/emission_strength = 0.0
|
||||
shader_parameter/uv_scale = Vector2(1, 1)
|
||||
shader_parameter/aspect_ratio = 0.5625
|
||||
shader_parameter/time_scale = 0.2
|
||||
shader_parameter/gunk_noise = SubResource("NoiseTexture3D_et0xc")
|
||||
shader_parameter/gunk_normal_map = SubResource("NoiseTexture3D_a6m17")
|
||||
shader_parameter/gunk_noise = SubResource("NoiseTexture3D_7v5ka")
|
||||
shader_parameter/gunk_normal_map = SubResource("NoiseTexture3D_d72jk")
|
||||
shader_parameter/mask_progress = 0.0
|
||||
shader_parameter/mask_noise = SubResource("NoiseTexture2D_et0xc")
|
||||
shader_parameter/mask_noise = SubResource("NoiseTexture2D_pgbvb")
|
||||
|
||||
[sub_resource type="Animation" id="Animation_et0xc"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("Grunk2D:material:shader_parameter/mask_progress")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [0.0]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Grunk2D/Rumbler:visible")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [false]
|
||||
}
|
||||
tracks/2/type = "value"
|
||||
tracks/2/imported = false
|
||||
tracks/2/enabled = true
|
||||
tracks/2/path = NodePath("Blackout:visible")
|
||||
tracks/2/interp = 1
|
||||
tracks/2/loop_wrap = true
|
||||
tracks/2/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [false]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_qsvii"]
|
||||
resource_name = "transition_in"
|
||||
@ -52,7 +93,7 @@ length = 14.0
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("Grunk:material:shader_parameter/mask_progress")
|
||||
tracks/0/path = NodePath("Grunk2D:material:shader_parameter/mask_progress")
|
||||
tracks/0/interp = 2
|
||||
tracks/0/loop_wrap = false
|
||||
tracks/0/keys = {
|
||||
@ -64,7 +105,7 @@ tracks/0/keys = {
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Grunk/Rumbler:visible")
|
||||
tracks/1/path = NodePath("Grunk2D/Rumbler:visible")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
@ -100,45 +141,6 @@ tracks/3/keys = {
|
||||
}]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_et0xc"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("Grunk:material:shader_parameter/mask_progress")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 0,
|
||||
"values": [0.0]
|
||||
}
|
||||
tracks/1/type = "value"
|
||||
tracks/1/imported = false
|
||||
tracks/1/enabled = true
|
||||
tracks/1/path = NodePath("Grunk/Rumbler:visible")
|
||||
tracks/1/interp = 1
|
||||
tracks/1/loop_wrap = true
|
||||
tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [false]
|
||||
}
|
||||
tracks/2/type = "value"
|
||||
tracks/2/imported = false
|
||||
tracks/2/enabled = true
|
||||
tracks/2/path = NodePath("Blackout:visible")
|
||||
tracks/2/interp = 1
|
||||
tracks/2/loop_wrap = true
|
||||
tracks/2/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [false]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_a6m17"]
|
||||
_data = {
|
||||
&"RESET": SubResource("Animation_et0xc"),
|
||||
@ -153,27 +155,20 @@ anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
|
||||
[node name="Grunk" type="ColorRect" parent="."]
|
||||
clip_children = 2
|
||||
material = SubResource("ShaderMaterial_qsvii")
|
||||
[node name="Grunk2D" parent="." instance=ExtResource("1_sv5d8")]
|
||||
material = SubResource("ShaderMaterial_3jt4s")
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
|
||||
[node name="Rumbler" type="Control" parent="Grunk"]
|
||||
[node name="Rumbler" type="Control" parent="Grunk2D"]
|
||||
visible = false
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 3.04544
|
||||
offset_top = -0.292352
|
||||
offset_right = 3.04541
|
||||
offset_bottom = -0.292358
|
||||
offset_left = -7.49218
|
||||
offset_top = -3.99316
|
||||
offset_right = -7.49219
|
||||
offset_bottom = -3.99316
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
@ -181,7 +176,7 @@ script = ExtResource("4_sv5d8")
|
||||
intensity = 6.0
|
||||
metadata/_custom_type_script = "uid://cjs2fen6jo0g0"
|
||||
|
||||
[node name="DeathMessage" type="Label" parent="Grunk/Rumbler"]
|
||||
[node name="DeathMessage" type="Label" parent="Grunk2D/Rumbler"]
|
||||
layout_mode = 1
|
||||
anchors_preset = 8
|
||||
anchor_left = 0.5
|
||||
|
@ -18,6 +18,7 @@ var current_level: PackedScene
|
||||
|
||||
@onready var level_root: Node3D = %LevelRoot
|
||||
@onready var ui_root: Control = %UIRoot
|
||||
@onready var save_icon: MarginContainer = %SaveIcon
|
||||
|
||||
static var instance: World
|
||||
|
||||
@ -53,8 +54,6 @@ func load_level(level: PackedScene, save: SaveState = null) -> void:
|
||||
current_level = level
|
||||
print("Instantiating level from ", level.resource_path)
|
||||
var level_instance := level.instantiate()
|
||||
#if save:
|
||||
#level_instance.ready.connect(func() -> void: save.load_to_world(self), CONNECT_ONE_SHOT)
|
||||
level_root.add_child(level_instance)
|
||||
if save:
|
||||
save.load_to_world(self)
|
||||
@ -81,7 +80,9 @@ func on_game_over() -> void:
|
||||
|
||||
func save_progress() -> void:
|
||||
print("Preparing save state...")
|
||||
save_icon.show()
|
||||
var save := SaveState.serialize(self)
|
||||
print("Writing save to ", save_path)
|
||||
ResourceSaver.save(save, save_path)
|
||||
save_icon.hide()
|
||||
print("Done!")
|
||||
|
@ -1,17 +1,18 @@
|
||||
[gd_scene load_steps=7 format=3 uid="uid://884jqafhtrv0"]
|
||||
[gd_scene load_steps=8 format=3 uid="uid://884jqafhtrv0"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://cgqmhtemibxc5" path="res://src/world/world.gd" id="1_1k4gi"]
|
||||
[ext_resource type="Resource" uid="uid://tgac5tnfx56r" path="res://src/world/world_manager.tres" id="2_5kmgb"]
|
||||
[ext_resource type="PackedScene" uid="uid://byvjsvavbg5xe" path="res://src/ui/menus/pause_menu/pause_menu.tscn" id="2_6fy3g"]
|
||||
[ext_resource type="Resource" uid="uid://0i72bf8ip1lx" path="res://src/world/spook_manager.tres" id="3_l0av5"]
|
||||
[ext_resource type="PackedScene" uid="uid://b8rv6dg4tgaeb" path="res://src/world/gunk_node/mechanic_test.tscn" id="4_l0av5"]
|
||||
[ext_resource type="PackedScene" uid="uid://bov4ok76woyc" path="res://levels/ghost_ship/ghost_ship.tscn" id="4_5kmgb"]
|
||||
[ext_resource type="PackedScene" uid="uid://c0uitm5cg88h1" path="res://src/ui/menus/kill_screen/kill_screen.tscn" id="6_l0av5"]
|
||||
[ext_resource type="PackedScene" uid="uid://brknr57xc2cp0" path="res://src/ui/elements/save_icon/save_icon.tscn" id="7_5kmgb"]
|
||||
|
||||
[node name="World" type="Node"]
|
||||
script = ExtResource("1_1k4gi")
|
||||
manager = ExtResource("2_5kmgb")
|
||||
spook_manager = ExtResource("3_l0av5")
|
||||
initial_level = ExtResource("4_l0av5")
|
||||
initial_level = ExtResource("4_5kmgb")
|
||||
pause_scene = ExtResource("2_6fy3g")
|
||||
kill_screen_scene = ExtResource("6_l0av5")
|
||||
|
||||
@ -27,3 +28,17 @@ anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
mouse_filter = 2
|
||||
|
||||
[node name="SaveIcon" parent="UIRoot" instance=ExtResource("7_5kmgb")]
|
||||
unique_name_in_owner = true
|
||||
visible = false
|
||||
layout_mode = 1
|
||||
anchors_preset = 2
|
||||
anchor_top = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_top = -140.0
|
||||
offset_right = 140.0
|
||||
offset_bottom = 0.0
|
||||
grow_vertical = 0
|
||||
theme_override_constants/margin_left = 32
|
||||
theme_override_constants/margin_bottom = 32
|
||||
|
@ -87,6 +87,8 @@ func deposit_tank() -> void:
|
||||
if alert_level >= CLEAR_LEVEL:
|
||||
clear_alert()
|
||||
|
||||
World.instance.save_progress()
|
||||
|
||||
|
||||
func is_tank_full() -> bool:
|
||||
return grunk_tank >= grunk_tank_limit
|
||||
|
Loading…
x
Reference in New Issue
Block a user