KONO DIO DA !!!!!!!

This commit is contained in:
E213872U 2025-01-24 22:52:53 +01:00
parent 5926327e4f
commit 1da26cb9ac
2 changed files with 36 additions and 1 deletions

View file

@ -1,10 +1,12 @@
[gd_scene load_steps=10 format=3 uid="uid://durhes43gex7a"]
[gd_scene load_steps=12 format=3 uid="uid://durhes43gex7a"]
[ext_resource type="PackedScene" uid="uid://c7bfiw54rvaq2" path="res://scenes/player_melodie.tscn" id="1_cl1wt"]
[ext_resource type="Script" path="res://scenes/room.gd" id="1_jh83c"]
[ext_resource type="Texture2D" uid="uid://ky4e7158gqf6" path="res://ressources/images/cgj_default_tile.svg" id="2_torsx"]
[ext_resource type="PackedScene" uid="uid://cyvqa6g64cw37" path="res://scenes/enemies/slime.tscn" id="3_04ip2"]
[ext_resource type="Texture2D" uid="uid://bge3nllk1bq5r" path="res://ressources/images/mur.svg" id="3_oi2tl"]
[ext_resource type="Texture2D" uid="uid://dhva3tivsvknl" path="res://ressources/images/mur_coin.svg" id="4_6a3f6"]
[ext_resource type="PackedScene" uid="uid://di4chlep1t1or" path="res://parametres/menu_parametres.tscn" id="6_6ubhx"]
[sub_resource type="WorldBoundaryShape2D" id="WorldBoundaryShape2D_1c4te"]
normal = Vector2(0, 1)
@ -22,6 +24,7 @@ normal = Vector2(1, 0)
distance = -596.0
[node name="Room" type="Node2D"]
script = ExtResource("1_jh83c")
[node name="TextureRect" type="TextureRect" parent="."]
offset_left = -638.0
@ -122,3 +125,11 @@ texture = ExtResource("4_6a3f6")
[node name="Slime" parent="." groups=["Enemies"] instance=ExtResource("3_04ip2")]
position = Vector2(-448, 205)
[node name="Menu_parametres" parent="." instance=ExtResource("6_6ubhx")]
process_mode = 3
visible = false
offset_left = -640.0
offset_top = -360.0
offset_right = 640.0
offset_bottom = 360.0

24
scenes/room.gd Normal file
View file

@ -0,0 +1,24 @@
extends Node2D
@onready var menu_parametres = $Menu_parametres
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
menu_parametres.exit_parametres.connect(on_exit_parametres)
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
if Input.is_action_just_pressed("PAUSE") :
on_param_button_pressed()
func on_param_button_pressed():
get_tree().paused = true
menu_parametres.set_process(true)
menu_parametres.visible = true
func on_exit_parametres() -> void :
get_tree().paused = false
menu_parametres.visible = false
menu_parametres.set_process(false)