tweaks, added rain, added intro cutscene

This commit is contained in:
IMK 2024-01-05 23:10:13 +01:00
parent d44b4cc724
commit c69de793ed
37 changed files with 1755 additions and 26 deletions

BIN
ambience.ogg Normal file

Binary file not shown.

19
ambience.ogg.import Normal file
View File

@ -0,0 +1,19 @@
[remap]
importer="oggvorbisstr"
type="AudioStreamOggVorbis"
uid="uid://biikhg58yulbq"
path="res://.godot/imported/ambience.ogg-2cdaa06031e02d0a90704fe4b8c620e3.oggvorbisstr"
[deps]
source_file="res://ambience.ogg"
dest_files=["res://.godot/imported/ambience.ogg-2cdaa06031e02d0a90704fe4b8c620e3.oggvorbisstr"]
[params]
loop=true
loop_offset=0.0
bpm=0.0
beat_count=0
bar_beats=4

12
blah bvla blah.tres Normal file
View File

@ -0,0 +1,12 @@
[gd_resource type="VisualShader" format=3 uid="uid://cri3capigj3ap"]
[resource]
code = "shader_type canvas_item;
render_mode blend_mix;
"
graph_offset = Vector2(-162.383, 75.0981)
mode = 1
flags/light_only = false

BIN
chair.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 607 B

34
chair.png.import Normal file
View File

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://c675vir3aj8lb"
path="res://.godot/imported/chair.png-e75ea7af3c0c332052214ee68a682d23.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://chair.png"
dest_files=["res://.godot/imported/chair.png-e75ea7af3c0c332052214ee68a682d23.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=1

24
circle.gdshader Normal file
View File

@ -0,0 +1,24 @@
shader_type canvas_item;
uniform float r = 0.5;
uniform float visibility = 1.0;
void fragment()
{
vec2 uv = UV - 0.5;
int div = 127;
vec2 st = (vec2(ivec2( uv * float(div) ))+0.5)/float(div);
float d = length(st);
float c = 1.0;
float alpha = visibility;
if (d<r){
c = 0.0;
}
else{
alpha = 0.0;
}
c = smoothstep(r,r,1);
COLOR = vec4(vec3(c),alpha);
}

14
default_bus_layout.tres Normal file
View File

@ -0,0 +1,14 @@
[gd_resource type="AudioBusLayout" load_steps=2 format=3 uid="uid://beyfprvoxr0ex"]
[sub_resource type="AudioEffectReverb" id="AudioEffectReverb_is3lo"]
resource_name = "Reverb"
[resource]
bus/1/name = &"reverb"
bus/1/solo = false
bus/1/mute = false
bus/1/bypass_fx = false
bus/1/volume_db = 0.0
bus/1/send = &"Master"
bus/1/effect/0/effect = SubResource("AudioEffectReverb_is3lo")
bus/1/effect/0/enabled = true

BIN
door.wav Normal file

Binary file not shown.

24
door.wav.import Normal file
View File

@ -0,0 +1,24 @@
[remap]
importer="wav"
type="AudioStreamWAV"
uid="uid://ddyuh5cfs06ev"
path="res://.godot/imported/door.wav-bb46974a4ab955eadebfb39e81a4250c.sample"
[deps]
source_file="res://door.wav"
dest_files=["res://.godot/imported/door.wav-bb46974a4ab955eadebfb39e81a4250c.sample"]
[params]
force/8_bit=false
force/mono=false
force/max_rate=false
force/max_rate_hz=44100
edit/trim=false
edit/normalize=false
edit/loop_mode=0
edit/loop_begin=0
edit/loop_end=-1
compress/mode=0

BIN
front-back.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 277 B

34
front-back.png.import Normal file
View File

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bcoix7313nhtq"
path="res://.godot/imported/front-back.png-33576a0cb90c486b9ba72c702a0af180.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://front-back.png"
dest_files=["res://.godot/imported/front-back.png-33576a0cb90c486b9ba72c702a0af180.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=1

BIN
home.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

34
home.png.import Normal file
View File

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://ckaav44qlymqw"
path="res://.godot/imported/home.png-f886f05be881282b7fb9db947f3a5150.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://home.png"
dest_files=["res://.godot/imported/home.png-f886f05be881282b7fb9db947f3a5150.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=1

15
intro.gd Normal file
View File

@ -0,0 +1,15 @@
extends Node2D
# Called when the node enters the scene tree for the first time.
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta):
$plr/AnimatedSprite2D.visible = false
var tweener = get_tree().create_tween()
tweener.set_ease(Tween.EASE_OUT)
tweener.set_trans(Tween.TRANS_BOUNCE)
tweener.tween_property($plr/CanvasLayer/fadeout,"modulate",Color("ffffff7a"),0.5)
await tweener.finished
await get_tree().create_timer(1).timeout

BIN
intro.ogg Normal file

Binary file not shown.

19
intro.ogg.import Normal file
View File

@ -0,0 +1,19 @@
[remap]
importer="oggvorbisstr"
type="AudioStreamOggVorbis"
uid="uid://clv4sfy75ubb4"
path="res://.godot/imported/intro.ogg-1d62de117bc3dfff5a5c4d897f88468e.oggvorbisstr"
[deps]
source_file="res://intro.ogg"
dest_files=["res://.godot/imported/intro.ogg-1d62de117bc3dfff5a5c4d897f88468e.oggvorbisstr"]
[params]
loop=false
loop_offset=0
bpm=0
beat_count=0
bar_beats=4

1107
intro.tscn Normal file

File diff suppressed because it is too large Load Diff

BIN
jump.wav Normal file

Binary file not shown.

24
jump.wav.import Normal file
View File

@ -0,0 +1,24 @@
[remap]
importer="wav"
type="AudioStreamWAV"
uid="uid://dfxfh261rode0"
path="res://.godot/imported/jump.wav-14683e0efd5a66adca0a851c79ecec1c.sample"
[deps]
source_file="res://jump.wav"
dest_files=["res://.godot/imported/jump.wav-14683e0efd5a66adca0a851c79ecec1c.sample"]
[params]
force/8_bit=false
force/mono=false
force/max_rate=false
force/max_rate_hz=44100
edit/trim=false
edit/normalize=false
edit/loop_mode=0
edit/loop_begin=0
edit/loop_end=-1
compress/mode=0

24
lightsphere.gdshader Normal file
View File

@ -0,0 +1,24 @@
shader_type canvas_item;
uniform float r = 0.5;
uniform float visibility = 1.0;
void fragment()
{
vec2 uv = UV - 0.5;
int div = 127;
vec2 st = (vec2(ivec2( uv * float(div) ))+0.5)/float(div);
float d = length(st);
float c = 1.0;
float alpha = visibility;
if (d<r){
c = 0.0;
}
else{
alpha = 0.0;
}
c = smoothstep(r,r,1);
COLOR = vec4(vec3(c),alpha);
}

View File

@ -40,3 +40,7 @@ region_rect = Rect2(352, 299, 32, 5)
[node name="CollisionShape2D" type="CollisionShape2D" parent="Platform"]
position = Vector2(0, 2.5)
shape = SubResource("RectangleShape2D_l8va0")
[node name="Timer" type="Timer" parent="."]
wait_time = 0.001
one_shot = true

BIN
news sheet.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

34
news sheet.png.import Normal file
View File

@ -0,0 +1,34 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://dr17uw1wdwl48"
path="res://.godot/imported/news sheet.png-7ca0dcdfe650a4a09c41874c6227d1e2.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://news sheet.png"
dest_files=["res://.godot/imported/news sheet.png-7ca0dcdfe650a4a09c41874c6227d1e2.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=1

18
news_scroll.gd Normal file
View File

@ -0,0 +1,18 @@
extends Node2D
var texter = preload("res://newstext.tscn")
# Called when the node enters the scene tree for the first time.
func _ready():
pass # Replace with function body.
# Called every frame. 'delta' is the elapsed time since the previous frame.
func scroll():
while get_parent().get_parent().visible:
var cloner = texter.instantiate()
cloner.global_position = get_parent().get_node("RichTextLabel").global_position
add_child(cloner)
var tweener = get_tree().create_tween()
tweener.tween_property(cloner,"global_position",Vector2(500,28),10)
await get_tree().create_timer(4).timeout

20
newstext.tscn Normal file
View File

@ -0,0 +1,20 @@
[gd_scene load_steps=3 format=3 uid="uid://pqq4ypdd0wlg"]
[ext_resource type="Theme" uid="uid://doj6uvro8nygh" path="res://plr.tres" id="1_qilna"]
[ext_resource type="Script" path="res://selfkilltext.gd" id="2_tbd1m"]
[node name="RichTextLabel" type="RichTextLabel"]
offset_left = -263.0
offset_top = 21.0
offset_right = 1.0
offset_bottom = 61.0
theme = ExtResource("1_qilna")
text = "Giant hole in park. Curious investigator gone missing."
scroll_active = false
autowrap_mode = 0
script = ExtResource("2_tbd1m")
[node name="VisibleOnScreenNotifier2D" type="VisibleOnScreenNotifier2D" parent="."]
position = Vector2(9, 9)
[connection signal="screen_exited" from="VisibleOnScreenNotifier2D" to="." method="_on_visible_on_screen_notifier_2d_screen_exited"]

View File

@ -5,24 +5,27 @@ var dialogue
signal proceed
# Called when the node enters the scene tree for the first time.
func _ready():
$plr.can_move = false
$plr/AnimatedSprite2D.visible = false
var plr = $plr
var fadeout = plr.get_node("CanvasLayer/fadeout")
var anim = plr.get_node("AnimatedSprite2D")
plr.can_move = false
anim.visible = false
if SaveHandler.settings["LoadSave"]:
$CheckPoints.current = get_node(str("CheckPoints/")+SaveHandler.settings["checkpoint"])
if not typeof($CheckPoints.current) == TYPE_NIL:
$plr.position = $CheckPoints.current.position
plr.position = $CheckPoints.current.position
$cloud.enabled = true
$plr.can_move = true
$plr/AnimatedSprite2D.visible = true
plr.can_move = true
anim.visible = true
var tweener2 = get_tree().create_tween()
tweener2.set_trans(Tween.TRANS_SINE)
tweener2.tween_property($plr/CanvasLayer/fadeout,"size",Vector2(1152,0),3)
tweener2.tween_property(fadeout, "size",Vector2(1152,0),3)
$the_hole.play()
await tweener2.finished
return
var tweener2 = get_tree().create_tween()
tweener2.set_trans(Tween.TRANS_SINE)
tweener2.tween_property($plr/CanvasLayer/fadeout,"size",Vector2(1152,0),3)
tweener2.tween_property(fadeout,"size",Vector2(1152,0),3)
$AudioStreamPlayer.play()
await tweener2.finished
@ -33,20 +36,20 @@ func _ready():
await get_tree().create_timer(0.2).timeout
var tweener = get_tree().create_tween()
$fakeplr.play("move")
tweener.tween_property($fakeplr,"position",$plr/AnimatedSprite2D.global_position,5)
tweener.tween_property($fakeplr,"position",anim.global_position,5)
await tweener.finished
$plr/AnimatedSprite2D.visible = true
$plr/AnimatedSprite2D.play("idle")
anim.visible = true
anim.play("idle")
$fakeplr.visible = false
$plr/Camera2D/dialogue.dialogue("The hole should be near me.","nervous",0.5)
$plr/Camera2D/dialogue.visible = true
dialogue.dialogue("The hole should be near me.","nervous",0.5)
dialogue.visible = true
await proceed
$plr/Camera2D/dialogue.dialogue("I hope what I read wasn't fake news.","upsidedown",0.5)
dialogue.dialogue("I hope what I read wasn't fake news.","upsidedown",0.5)
await proceed
$plr/Camera2D/dialogue.dialogue("I haven't got the chance to climb in a hole for a long time.","nervous",0.5)
dialogue.dialogue("I haven't got the chance to climb in a hole for a long time.","nervous",0.5)
await proceed
$plr/Camera2D/dialogue.visible = false
$plr.can_move = true
dialogue.visible = false
plr.can_move = true
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta):

File diff suppressed because one or more lines are too long

BIN
orchestra chord.ogg Normal file

Binary file not shown.

View File

@ -0,0 +1,19 @@
[remap]
importer="oggvorbisstr"
type="AudioStreamOggVorbis"
uid="uid://b4tbur0euoof5"
path="res://.godot/imported/orchestra chord.ogg-88c87c8f3ad3fad539d844d955a5ff61.oggvorbisstr"
[deps]
source_file="res://orchestra chord.ogg"
dest_files=["res://.godot/imported/orchestra chord.ogg-88c87c8f3ad3fad539d844d955a5ff61.oggvorbisstr"]
[params]
loop=false
loop_offset=0
bpm=0
beat_count=0
bar_beats=4

3
plr.gd
View File

@ -25,7 +25,7 @@ var defspeed = 100
var sprintspeed = 150
var SPEED = defspeed
var can_move = true
@export var can_move = true
@export var on_ladder = false
@export var ladder : CharacterBody2D
@ -109,6 +109,7 @@ func _physics_process(delta):
# Handle Jump.
if Input.is_action_just_pressed("ui_accept") and can_jump or airjump and Input.is_action_just_pressed("ui_accept"):
can_jump = false
$jumpsfx.play()
velocity.y = JUMP_VELOCITY
$AnimatedSprite2D.play("jump")
if airjump:

View File

@ -1,4 +1,4 @@
[gd_scene load_steps=33 format=3 uid="uid://bdncoo2t66e58"]
[gd_scene load_steps=34 format=3 uid="uid://bdncoo2t66e58"]
[ext_resource type="Script" path="res://plr.gd" id="1_ub5ic"]
[ext_resource type="Texture2D" uid="uid://dvrxgvepbbhl7" path="res://silly_fella.png" id="2_hijeb"]
@ -10,6 +10,7 @@
[ext_resource type="Texture2D" uid="uid://btw7cy3q5fxng" path="res://explorer.png" id="7_d3k28"]
[ext_resource type="AudioStream" uid="uid://bdpql7v8x0ajy" path="res://beep.wav" id="7_d3xbw"]
[ext_resource type="Shader" path="res://blur.gdshader" id="9_axrdm"]
[ext_resource type="AudioStream" uid="uid://dfxfh261rode0" path="res://jump.wav" id="11_i6arn"]
[sub_resource type="RectangleShape2D" id="RectangleShape2D_xil0x"]
size = Vector2(6, 15)
@ -244,7 +245,7 @@ wait_time = 0.05
one_shot = true
[node name="LedgeAssistWall" type="Timer" parent="."]
wait_time = 0.02
wait_time = 0.04
one_shot = true
[node name="Camera2D" type="Camera2D" parent="."]
@ -322,7 +323,6 @@ max_polyphony = 7
[node name="CanvasLayer" type="CanvasLayer" parent="."]
layer = 20
visible = false
[node name="blur" type="ColorRect" parent="CanvasLayer"]
z_index = 40
@ -349,6 +349,9 @@ libraries = {
"": SubResource("AnimationLibrary_a2qok")
}
[node name="jumpsfx" type="AudioStreamPlayer" parent="."]
stream = ExtResource("11_i6arn")
[connection signal="timeout" from="rightt" to="." method="_on_rightt_timeout"]
[connection signal="timeout" from="leftt" to="." method="_on_leftt_timeout"]
[connection signal="timeout" from="LedgeAssist" to="." method="_on_ledge_assist_timeout"]

View File

@ -25,6 +25,10 @@ window/size/resizable=false
window/stretch/mode="canvas_items"
window/stretch/aspect="expand"
[editor]
movie_writer/movie_file="/home/imk/cutscene.avi"
[input]
ui_accept={
@ -85,3 +89,4 @@ lookdown={
textures/canvas_textures/default_texture_filter=0
renderer/rendering_method.mobile="gl_compatibility"
environment/defaults/default_clear_color=Color(0, 0, 0, 1)

5
selfkilltext.gd Normal file
View File

@ -0,0 +1,5 @@
extends RichTextLabel
func _on_visible_on_screen_notifier_2d_screen_exited():
queue_free()

BIN
spin.wav Normal file

Binary file not shown.

24
spin.wav.import Normal file
View File

@ -0,0 +1,24 @@
[remap]
importer="wav"
type="AudioStreamWAV"
uid="uid://bykxl2lqmwqto"
path="res://.godot/imported/spin.wav-297e428071125cf95f7d3b6ab2367846.sample"
[deps]
source_file="res://spin.wav"
dest_files=["res://.godot/imported/spin.wav-297e428071125cf95f7d3b6ab2367846.sample"]
[params]
force/8_bit=false
force/mono=false
force/max_rate=false
force/max_rate_hz=44100
edit/trim=false
edit/normalize=false
edit/loop_mode=0
edit/loop_begin=0
edit/loop_end=-1
compress/mode=0

13
text_scroll.gd Normal file
View File

@ -0,0 +1,13 @@
class_name scrolling
extends RichTextEffect
var bbcode = "scrolling"
# Called when the node enters the scene tree for the first time.
func _ready():
pass # Replace with function body.
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process_custom_fx(char_fx):
char_fx.offset.x += 50

Binary file not shown.