Compare commits
4 commits
9c6af1c034
...
508799552b
| Author | SHA1 | Date | |
|---|---|---|---|
| 508799552b | |||
| 0bab4c62cb | |||
| 2587882f0f | |||
| 2a4919dbeb |
20 changed files with 269 additions and 25 deletions
|
|
@ -103,6 +103,7 @@ pause={
|
|||
|
||||
2d_physics/layer_1="player"
|
||||
2d_physics/layer_2="walls"
|
||||
2d_physics/layer_3="objects"
|
||||
|
||||
[rendering]
|
||||
|
||||
|
|
|
|||
BIN
scenes/bed/assets/bed.aseprite
Normal file
BIN
scenes/bed/assets/bed.aseprite
Normal file
Binary file not shown.
20
scenes/bed/assets/bed.aseprite.import
Normal file
20
scenes/bed/assets/bed.aseprite.import
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
[remap]
|
||||
|
||||
importer="aseprite_wizard.plugin.static-texture"
|
||||
type="PortableCompressedTexture2D"
|
||||
uid="uid://b6kqx81h1kpql"
|
||||
path="res://.godot/imported/bed.aseprite-41496986a4e64ed96c5c25382ceb0d93.res"
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://scenes/bed/assets/bed.aseprite"
|
||||
dest_files=["res://.godot/imported/bed.aseprite-41496986a4e64ed96c5c25382ceb0d93.res"]
|
||||
|
||||
[params]
|
||||
|
||||
layer/exclude_layers_pattern=""
|
||||
layer/only_visible_layers=false
|
||||
first_frame_only=true
|
||||
sheet/sheet_type="packed"
|
||||
sheet/sheet_columns=12
|
||||
sheet/scale=1
|
||||
BIN
scenes/bed/assets/bed.pixelover
Normal file
BIN
scenes/bed/assets/bed.pixelover
Normal file
Binary file not shown.
BIN
scenes/bed/assets/bed_export.png
Normal file
BIN
scenes/bed/assets/bed_export.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 12 KiB |
40
scenes/bed/assets/bed_export.png.import
Normal file
40
scenes/bed/assets/bed_export.png.import
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://ca63jngtw3jka"
|
||||
path="res://.godot/imported/bed_export.png-ed75e67ebe92e964a41aae297ea4d98a.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://scenes/bed/assets/bed_export.png"
|
||||
dest_files=["res://.godot/imported/bed_export.png-ed75e67ebe92e964a41aae297ea4d98a.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
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/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
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=1
|
||||
BIN
scenes/bed/assets/bed_n.png
Normal file
BIN
scenes/bed/assets/bed_n.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 9.7 KiB |
40
scenes/bed/assets/bed_n.png.import
Normal file
40
scenes/bed/assets/bed_n.png.import
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://dv6eeiat64s4r"
|
||||
path="res://.godot/imported/bed_n.png-5065a14368e2ca7e64e84e9a43785cc2.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://scenes/bed/assets/bed_n.png"
|
||||
dest_files=["res://.godot/imported/bed_n.png-5065a14368e2ca7e64e84e9a43785cc2.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
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/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
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=1
|
||||
BIN
scenes/bed/assets/bed_normal.laigter
Normal file
BIN
scenes/bed/assets/bed_normal.laigter
Normal file
Binary file not shown.
BIN
scenes/bed/assets/bed_o.png
Normal file
BIN
scenes/bed/assets/bed_o.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.4 KiB |
40
scenes/bed/assets/bed_o.png.import
Normal file
40
scenes/bed/assets/bed_o.png.import
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://c7aqn7cwyn8lk"
|
||||
path="res://.godot/imported/bed_o.png-880a287f3d9c078b89996373122dac81.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://scenes/bed/assets/bed_o.png"
|
||||
dest_files=["res://.godot/imported/bed_o.png-880a287f3d9c078b89996373122dac81.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
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/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
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=1
|
||||
BIN
scenes/bed/assets/bed_s.png
Normal file
BIN
scenes/bed/assets/bed_s.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.3 KiB |
40
scenes/bed/assets/bed_s.png.import
Normal file
40
scenes/bed/assets/bed_s.png.import
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://bahmkvceso40p"
|
||||
path="res://.godot/imported/bed_s.png-f510bf4866bf64f3d4d893e61b5a21a9.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://scenes/bed/assets/bed_s.png"
|
||||
dest_files=["res://.godot/imported/bed_s.png-f510bf4866bf64f3d4d893e61b5a21a9.ctex"]
|
||||
|
||||
[params]
|
||||
|
||||
compress/mode=0
|
||||
compress/high_quality=false
|
||||
compress/lossy_quality=0.7
|
||||
compress/uastc_level=0
|
||||
compress/rdo_quality_loss=0.0
|
||||
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/channel_remap/red=0
|
||||
process/channel_remap/green=1
|
||||
process/channel_remap/blue=2
|
||||
process/channel_remap/alpha=3
|
||||
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=1
|
||||
53
scenes/bed/bed.tscn
Normal file
53
scenes/bed/bed.tscn
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
[gd_scene load_steps=6 format=3 uid="uid://brkv032w3gyfo"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://ccawks66thcw2" path="res://classes/room_object/room_object.gd" id="1_5prx0"]
|
||||
[ext_resource type="Texture2D" uid="uid://b6kqx81h1kpql" path="res://scenes/bed/assets/bed.aseprite" id="2_w6piv"]
|
||||
[ext_resource type="Texture2D" uid="uid://dv6eeiat64s4r" path="res://scenes/bed/assets/bed_n.png" id="3_ayy0y"]
|
||||
|
||||
[sub_resource type="CanvasTexture" id="CanvasTexture_opn68"]
|
||||
diffuse_texture = ExtResource("2_w6piv")
|
||||
normal_texture = ExtResource("3_ayy0y")
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_ayy0y"]
|
||||
radius = 32.0
|
||||
|
||||
[node name="Bed" type="Node2D"]
|
||||
z_index = 1
|
||||
script = ExtResource("1_5prx0")
|
||||
metadata/_custom_type_script = "uid://ccawks66thcw2"
|
||||
|
||||
[node name="StaticBody2D" type="StaticBody2D" parent="."]
|
||||
collision_layer = 4
|
||||
collision_mask = 0
|
||||
|
||||
[node name="Sprite2D" type="Sprite2D" parent="StaticBody2D"]
|
||||
position = Vector2(0, -24)
|
||||
texture = SubResource("CanvasTexture_opn68")
|
||||
metadata/_aseprite_wizard_interface_config_ = {
|
||||
"animation_section": true,
|
||||
"layer_section": true,
|
||||
"output_section": true,
|
||||
"pending_changes": {
|
||||
"convert_fps_field": 60.0,
|
||||
"convert_ms_field": 16.0,
|
||||
"convert_to_fps": false,
|
||||
"embed_tex": true,
|
||||
"i_mode": 0,
|
||||
"keep_anim_length": false,
|
||||
"layers": [],
|
||||
"o_ex_p": "",
|
||||
"o_folder": "",
|
||||
"o_name": "",
|
||||
"only_visible": false,
|
||||
"player": "",
|
||||
"scale": "1.0",
|
||||
"slice": "",
|
||||
"source": "res://scenes/bed/assets/bed.aseprite",
|
||||
"source_uid": 4583932932945451959
|
||||
},
|
||||
"slice_section": true
|
||||
}
|
||||
|
||||
[node name="CollisionShape2D" type="CollisionShape2D" parent="StaticBody2D"]
|
||||
position = Vector2(0, -24)
|
||||
shape = SubResource("CircleShape2D_ayy0y")
|
||||
|
|
@ -9,6 +9,21 @@
|
|||
[ext_resource type="Texture2D" uid="uid://5mm8pi5i0yal" path="res://scenes/player/assets/pointlight_texture.aseprite" id="5_75vfm"]
|
||||
[ext_resource type="Script" uid="uid://cgiphcl4t75v8" path="res://scenes/player/states/player_paused.gd" id="6_qek5x"]
|
||||
|
||||
[sub_resource type="Animation" id="Animation_0owmy"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("PointLight2D:offset:y")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [-15.0]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_75vfm"]
|
||||
resource_name = "default"
|
||||
loop_mode = 1
|
||||
|
|
@ -25,21 +40,6 @@ tracks/0/keys = {
|
|||
"values": [-14.0, -15.0]
|
||||
}
|
||||
|
||||
[sub_resource type="Animation" id="Animation_0owmy"]
|
||||
length = 0.001
|
||||
tracks/0/type = "value"
|
||||
tracks/0/imported = false
|
||||
tracks/0/enabled = true
|
||||
tracks/0/path = NodePath("PointLight2D:offset:y")
|
||||
tracks/0/interp = 1
|
||||
tracks/0/loop_wrap = true
|
||||
tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0),
|
||||
"transitions": PackedFloat32Array(1),
|
||||
"update": 1,
|
||||
"values": [-15.0]
|
||||
}
|
||||
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_qek5x"]
|
||||
_data = {
|
||||
&"RESET": SubResource("Animation_0owmy"),
|
||||
|
|
@ -52,7 +52,7 @@ height = 14.0
|
|||
|
||||
[node name="Player" type="CharacterBody2D"]
|
||||
z_index = 1
|
||||
collision_mask = 2
|
||||
collision_mask = 6
|
||||
motion_mode = 1
|
||||
script = ExtResource("1_dovo2")
|
||||
max_speed = 85.0
|
||||
|
|
|
|||
|
|
@ -32,6 +32,10 @@ grow_vertical = 2
|
|||
[node name="CanvasModulate" type="CanvasModulate" parent="."]
|
||||
visible = false
|
||||
|
||||
[node name="RoomCamera" type="Camera2D" parent="."]
|
||||
editor_draw_screen = false
|
||||
script = ExtResource("3_y1kpu")
|
||||
|
||||
[node name="RoomDirector" type="Node" parent="." node_paths=PackedStringArray("initial_state")]
|
||||
process_mode = 3
|
||||
script = ExtResource("4_vaubn")
|
||||
|
|
@ -53,7 +57,3 @@ metadata/_custom_type_script = "uid://hjm43hb4os07"
|
|||
[node name="Exiting" type="Node" parent="RoomDirector"]
|
||||
script = ExtResource("6_7jj40")
|
||||
metadata/_custom_type_script = "uid://hjm43hb4os07"
|
||||
|
||||
[node name="RoomCamera" type="Camera2D" parent="."]
|
||||
editor_draw_screen = false
|
||||
script = ExtResource("3_y1kpu")
|
||||
|
|
|
|||
|
|
@ -20,6 +20,8 @@ class_name RoomConfig extends Resource
|
|||
@export var enable_canvas_modulate: bool = false
|
||||
## Color of the canvas modulate.
|
||||
@export var modulate_color: Color
|
||||
## Color palette for the room.
|
||||
@export var room_palette: Texture2D
|
||||
|
||||
@export_group('Room Loop')
|
||||
## Whether the room loops itself or not.
|
||||
|
|
|
|||
|
|
@ -12,6 +12,10 @@ func _enter(_previous_state_path: String, _data: Dictionary = {}) -> void:
|
|||
assert(room.player != null, "player is null")
|
||||
room.camera.global_position = room.config.camera_position
|
||||
|
||||
var ps_material: ShaderMaterial = room.palette_shader.material as ShaderMaterial
|
||||
assert(ps_material != null, "palette shader is null")
|
||||
ps_material.set_shader_parameter("palette", room.config.room_palette)
|
||||
|
||||
room.player.enable_point_light(true, 0.4)
|
||||
room.player.point_light.texture_scale = 0
|
||||
|
||||
|
|
@ -31,7 +35,7 @@ func _enter(_previous_state_path: String, _data: Dictionary = {}) -> void:
|
|||
|
||||
player_light_tween = create_tween()
|
||||
|
||||
player_light_tween.tween_property(room.player.point_light, "texture_scale", 1.0, room.config.transition_in_duration).set_trans(Tween.TRANS_BOUNCE).set_ease(Tween.EASE_OUT)
|
||||
player_light_tween.tween_property(room.player.point_light, "texture_scale", 1.0, room.config.transition_in_duration).set_trans(Tween.TRANS_CIRC).set_ease(Tween.EASE_OUT)
|
||||
|
||||
await player_light_tween.finished
|
||||
|
||||
|
|
|
|||
|
|
@ -1,9 +1,10 @@
|
|||
[gd_scene load_steps=5 format=4 uid="uid://04d4byo43t4b"]
|
||||
[gd_scene load_steps=6 format=4 uid="uid://04d4byo43t4b"]
|
||||
|
||||
[ext_resource type="PackedScene" uid="uid://bxhyxox662buj" path="res://scenes/room/room.tscn" id="1_1k8b4"]
|
||||
[ext_resource type="Resource" uid="uid://h54yiuv2bup1" path="res://scenes/worlds/yukotsukis_room/yukotsukis_room_config.tres" id="2_vqekq"]
|
||||
[ext_resource type="TileSet" uid="uid://chb3vsmojvo8q" path="res://scenes/worlds/yukotsukis_room/assets/curtains/curtains_godot4.tres" id="3_od2gb"]
|
||||
[ext_resource type="TileSet" uid="uid://diqyujsetlsp6" path="res://scenes/worlds/yukotsukis_room/assets/floorboards/floorboards_godot4.tres" id="4_od2gb"]
|
||||
[ext_resource type="PackedScene" uid="uid://brkv032w3gyfo" path="res://scenes/bed/bed.tscn" id="5_vqekq"]
|
||||
|
||||
[node name="Yukotsuki\'s Room" instance=ExtResource("1_1k8b4")]
|
||||
config = ExtResource("2_vqekq")
|
||||
|
|
@ -22,3 +23,6 @@ tile_set = ExtResource("4_od2gb")
|
|||
|
||||
[node name="CurtainLayer" type="TileMapLayer" parent="." index="6"]
|
||||
tile_set = ExtResource("3_od2gb")
|
||||
|
||||
[node name="Bed" parent="." index="8" instance=ExtResource("5_vqekq")]
|
||||
position = Vector2(216, 208)
|
||||
|
|
|
|||
|
|
@ -1,14 +1,14 @@
|
|||
[gd_resource type="Resource" script_class="RoomConfig" load_steps=2 format=3 uid="uid://h54yiuv2bup1"]
|
||||
[gd_resource type="Resource" script_class="RoomConfig" load_steps=3 format=3 uid="uid://h54yiuv2bup1"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://bamoq5wi0lkdy" path="res://scenes/room/room_config.gd" id="1_vlksg"]
|
||||
[ext_resource type="Texture2D" uid="uid://bos6f0a87dyno" path="res://assets/palettes/lospec500-42.png" id="1_yx5vs"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_vlksg")
|
||||
initial_spawn = Vector2i(85, 225)
|
||||
enable_point_light = true
|
||||
point_light_energy = 0.4
|
||||
follow_player = false
|
||||
camera_position = Vector2i(160, 120)
|
||||
enable_canvas_modulate = true
|
||||
modulate_color = Color(0.35156274, 0.35156295, 0.35156283, 1)
|
||||
room_palette = ExtResource("1_yx5vs")
|
||||
metadata/_custom_type_script = "uid://bamoq5wi0lkdy"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue