Anri/AdBlockNot
Archived
1
0
Fork 0

anim starting computer

This commit is contained in:
Manal 2024-01-27 23:11:44 +01:00
parent f9c94c0da5
commit 3d46bb04d5
7 changed files with 114 additions and 0 deletions

BIN
models/menu/on_off.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 791 KiB

View file

@ -0,0 +1,19 @@
[remap]
importer="mp3"
type="AudioStreamMP3"
uid="uid://bnjm7gcfox6aj"
path="res://.godot/imported/Microsoft Windows 98 Shutdown Sound.mp3-5dbae7d9751993d8f3105001d30291fb.mp3str"
[deps]
source_file="res://ressources/sounds/menu/Microsoft Windows 98 Shutdown Sound.mp3"
dest_files=["res://.godot/imported/Microsoft Windows 98 Shutdown Sound.mp3-5dbae7d9751993d8f3105001d30291fb.mp3str"]
[params]
loop=false
loop_offset=0
bpm=0
beat_count=0
bar_beats=4

View file

@ -0,0 +1,19 @@
[remap]
importer="mp3"
type="AudioStreamMP3"
uid="uid://c5fgxh51yhon8"
path="res://.godot/imported/Microsoft Windows 98 Startup Sound .mp3-51335e6be6d692678355f0f41bf172b3.mp3str"
[deps]
source_file="res://ressources/sounds/menu/Microsoft Windows 98 Startup Sound .mp3"
dest_files=["res://.godot/imported/Microsoft Windows 98 Startup Sound .mp3-51335e6be6d692678355f0f41bf172b3.mp3str"]
[params]
loop=false
loop_offset=0
bpm=0
beat_count=0
bar_beats=4

21
scenes/menu/go_in.gd Normal file
View file

@ -0,0 +1,21 @@
extends Node2D
@onready var transition = $fade
# Called when the node enters the scene tree for the first time.
func _ready():
Input.set_mouse_mode(Input.MOUSE_MODE_CAPTURED)
transition.play("fade_in")
pass # Replace with function body.
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta):
pass
func _on_timer_timeout():
$on_sound.play()
func _on_on_sound_finished():
get_tree().change_scene_to_file("res://scenes/menu/menu.tscn")
pass # Replace with function body.

55
scenes/menu/go_in.tscn Normal file
View file

@ -0,0 +1,55 @@
[gd_scene load_steps=6 format=3 uid="uid://bd6hvyj4335ye"]
[ext_resource type="Script" path="res://scenes/menu/go_in.gd" id="1_fm2vx"]
[ext_resource type="Texture2D" uid="uid://dpthky7yki0m2" path="res://models/menu/on_off.png" id="2_hmhtg"]
[ext_resource type="AudioStream" uid="uid://c5fgxh51yhon8" path="res://ressources/sounds/menu/Microsoft Windows 98 Startup Sound .mp3" id="3_ekahx"]
[sub_resource type="Animation" id="Animation_ojx4i"]
resource_name = "fade_in"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("fade/ColorRect:self_modulate")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0.1, 1),
"transitions": PackedFloat32Array(1, 1),
"update": 0,
"values": [Color(0, 0, 0, 1), Color(1, 1, 1, 0)]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_afckh"]
_data = {
"fade_in": SubResource("Animation_ojx4i")
}
[node name="GoIn" type="Node2D"]
script = ExtResource("1_fm2vx")
[node name="TextureRect" type="TextureRect" parent="."]
offset_right = 1604.0
offset_bottom = 897.0
texture = ExtResource("2_hmhtg")
expand_mode = 1
[node name="on_sound" type="AudioStreamPlayer2D" parent="."]
stream = ExtResource("3_ekahx")
[node name="Timer" type="Timer" parent="."]
one_shot = true
autostart = true
[node name="fade" type="AnimationPlayer" parent="."]
libraries = {
"": SubResource("AnimationLibrary_afckh")
}
[node name="ColorRect" type="ColorRect" parent="fade"]
self_modulate = Color(1, 1, 1, 0)
offset_right = 1625.0
offset_bottom = 914.0
color = Color(0, 0, 0, 1)
[connection signal="finished" from="on_sound" to="." method="_on_on_sound_finished"]
[connection signal="timeout" from="Timer" to="." method="_on_timer_timeout"]