Compare commits
3 Commits
60d9f614ee
...
d61a0ffcb0
| Author | SHA1 | Date | |
|---|---|---|---|
| d61a0ffcb0 | |||
| 6146d84b87 | |||
| c17769246f |
Vendored
+9
-20
@@ -1,28 +1,17 @@
|
||||
[gd_resource type="Environment" load_steps=3 format=2]
|
||||
[gd_resource type="Environment" format=3 uid="uid://cosbxx1qhfx35"]
|
||||
|
||||
[ext_resource path="res://assets/hdri/tx_night_place.hdr" type="Texture2D" id=1]
|
||||
|
||||
[sub_resource type="Sky" id=2]
|
||||
panorama = ExtResource( 1 )
|
||||
[sub_resource type="Sky" id="2"]
|
||||
|
||||
[resource]
|
||||
background_mode = 3
|
||||
background_sky = SubResource( 2 )
|
||||
background_color = Color( 0.188235, 0.133333, 0.133333, 1 )
|
||||
background_energy = 0.6
|
||||
ambient_light_color = Color( 0.694118, 0.168627, 0.67451, 1 )
|
||||
ambient_light_energy = 1.55
|
||||
background_color = Color(0.188235, 0.133333, 0.133333, 1)
|
||||
sky = SubResource("2")
|
||||
ambient_light_color = Color(0.694118, 0.168627, 0.67451, 1)
|
||||
ambient_light_sky_contribution = 0.5
|
||||
ambient_light_energy = 1.55
|
||||
tonemap_mode = 2
|
||||
glow_enabled = true
|
||||
fog_enabled = true
|
||||
fog_color = Color( 0.562167, 0.29, 1, 0.941176 )
|
||||
fog_depth_curve = 1.10957
|
||||
fog_depth_begin = 0.0
|
||||
fog_depth_end = 60.0
|
||||
fog_depth_curve = 1.10957
|
||||
fog_height_enabled = true
|
||||
fog_height_min = 2.0
|
||||
fog_height_max = -20.0
|
||||
fog_height_curve = 0.965936
|
||||
tonemap_mode = 2
|
||||
ss_reflections_enabled = true
|
||||
dof_blur_far_distance = 2.0
|
||||
glow_enabled = true
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_resource type="FontVariation" load_steps=2 format=3]
|
||||
[gd_resource type="FontVariation" format=3 uid="uid://ehvxks08bpr"]
|
||||
|
||||
[ext_resource type="FontFile" path="res://assets/fonts/MKX Title.ttf" id="1"]
|
||||
[ext_resource type="FontFile" uid="uid://c7ps8q01ej5du" path="res://assets/fonts/MKX Title.ttf" id="1"]
|
||||
|
||||
[resource]
|
||||
base_font = ExtResource("1")
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_resource type="FontVariation" load_steps=2 format=3]
|
||||
[gd_resource type="FontVariation" format=3 uid="uid://inv1rofq17xy"]
|
||||
|
||||
[ext_resource type="FontFile" path="res://assets/fonts/kirsty/kirsty rg.otf" id="1"]
|
||||
[ext_resource type="FontFile" uid="uid://c0gq63h6u1c0f" path="res://assets/fonts/kirsty/kirsty rg.otf" id="1"]
|
||||
|
||||
[resource]
|
||||
base_font = ExtResource("1")
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_resource type="FontVariation" load_steps=2 format=3]
|
||||
[gd_resource type="FontVariation" format=3 uid="uid://dxs8032ya4bwr"]
|
||||
|
||||
[ext_resource type="FontFile" path="res://assets/fonts/kirsty/kirsty rg.otf" id="1"]
|
||||
[ext_resource type="FontFile" uid="uid://c0gq63h6u1c0f" path="res://assets/fonts/kirsty/kirsty rg.otf" id="1"]
|
||||
|
||||
[resource]
|
||||
base_font = ExtResource("1")
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_resource type="FontVariation" load_steps=2 format=3]
|
||||
[gd_resource type="FontVariation" format=3 uid="uid://bqx3uv23bwjul"]
|
||||
|
||||
[ext_resource type="FontFile" path="res://assets/fonts/kirsty/kirsty bd.otf" id="1"]
|
||||
[ext_resource type="FontFile" uid="uid://bgrwp4g3d0ywx" path="res://assets/fonts/kirsty/kirsty bd.otf" id="1"]
|
||||
|
||||
[resource]
|
||||
base_font = ExtResource("1")
|
||||
|
||||
@@ -1,10 +1,7 @@
|
||||
[gd_resource type="Environment" load_steps=3 format=2]
|
||||
[gd_resource type="Environment" format=3 uid="uid://b4goeb432cjl4"]
|
||||
|
||||
[ext_resource path="res://assets/hdri/tx_night_place.hdr" type="Texture2D" id=1]
|
||||
|
||||
[sub_resource type="Sky" id=1]
|
||||
panorama = ExtResource( 1 )
|
||||
[sub_resource type="Sky" id="1"]
|
||||
|
||||
[resource]
|
||||
background_mode = 3
|
||||
background_sky = SubResource( 1 )
|
||||
sky = SubResource("1")
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
[gd_resource type="ShaderMaterial" format=3]
|
||||
[gd_resource type="ShaderMaterial" format=3 uid="uid://vj5s8nwv5ac7"]
|
||||
|
||||
[sub_resource type="Shader" id="Shader_6qnue"]
|
||||
code = "shader_type spatial;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
[gd_resource type="ShaderMaterial" format=3]
|
||||
[gd_resource type="ShaderMaterial" format=3 uid="uid://8cbl1rknioqx"]
|
||||
|
||||
[sub_resource type="Shader" id="Shader_iwepy"]
|
||||
code = "shader_type spatial;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
[gd_resource type="ShaderMaterial" format=3]
|
||||
[gd_resource type="ShaderMaterial" format=3 uid="uid://dj27bh8fh6g7f"]
|
||||
|
||||
[sub_resource type="Shader" id="Shader_b630w"]
|
||||
code = "shader_type spatial;
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
[gd_scene load_steps=2 format=2]
|
||||
[gd_scene format=3 uid="uid://lt8fwag3uivj"]
|
||||
|
||||
[ext_resource path="res://assets/props/book/sm_book_lod1.mesh" type="ArrayMesh" id=2]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/book/sm_book_lod1.mesh" id="2"]
|
||||
|
||||
[node name="sm_book" type="Node3D"]
|
||||
[node name="sm_book" type="Node3D" unique_id=1509736704]
|
||||
|
||||
[node name="sm_book-lod1" type="MeshInstance3D" parent="."]
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 2 )
|
||||
surface_material_override/0 = null
|
||||
[node name="sm_book-lod1" type="MeshInstance3D" parent="." unique_id=56438111]
|
||||
mesh = ExtResource("2")
|
||||
|
||||
@@ -1,29 +1,25 @@
|
||||
[gd_scene load_steps=4 format=2]
|
||||
[gd_scene format=3 uid="uid://tlua1pg4ro8u"]
|
||||
|
||||
[ext_resource path="res://assets/props/candle/sm_candlestick_lod1.mesh" type="ArrayMesh" id=1]
|
||||
[ext_resource path="res://assets/props/candle/candle.gd" type="Script" id=2]
|
||||
[ext_resource path="res://assets/props/candle/sm_candle_top_lod1.mesh" type="ArrayMesh" id=3]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/candle/sm_candlestick_lod1.mesh" id="1"]
|
||||
[ext_resource type="Script" uid="uid://0v7yafm2dil" path="res://assets/props/candle/candle.gd" id="2"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/candle/sm_candle_top_lod1.mesh" id="3"]
|
||||
|
||||
[node name="sm_candlestick" type="Node3D"]
|
||||
script = ExtResource( 2 )
|
||||
[node name="sm_candlestick" type="Node3D" unique_id=158803858]
|
||||
script = ExtResource("2")
|
||||
|
||||
[node name="sm_candlestick_lod1" type="MeshInstance3D" parent="."]
|
||||
mesh = ExtResource( 1 )
|
||||
surface_material_override/0 = null
|
||||
[node name="sm_candlestick_lod1" type="MeshInstance3D" parent="." unique_id=93495968]
|
||||
mesh = ExtResource("1")
|
||||
|
||||
[node name="candles" type="MeshInstance3D" parent="sm_candlestick_lod1"]
|
||||
transform = Transform3D( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0.000981584, 0.150082, 0 )
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 3 )
|
||||
surface_material_override/0 = null
|
||||
[node name="candles" type="MeshInstance3D" parent="sm_candlestick_lod1" unique_id=1542964088]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.000981584, 0.150082, 0)
|
||||
mesh = ExtResource("3")
|
||||
|
||||
[node name="OmniLight3D" type="OmniLight3D" parent="sm_candlestick_lod1/candles"]
|
||||
transform = Transform3D( 1, 5.5022e-09, 1.96774e-13, -5.5022e-09, 1, 1.08271e-21, -1.96774e-13, -2.1654e-21, 1, 1.3737e-08, 0.0619183, -2.98023e-08 )
|
||||
[node name="OmniLight3D" type="OmniLight3D" parent="sm_candlestick_lod1/candles" unique_id=1368663821]
|
||||
transform = Transform3D(1, 5.5022e-09, 1.96774e-13, -5.5022e-09, 1, 1.08271e-21, -1.96774e-13, -2.1654e-21, 1, 1.3737e-08, 0.0619183, -2.98023e-08)
|
||||
visible = false
|
||||
light_color = Color( 0.960784, 0.611765, 0.00784314, 1 )
|
||||
light_color = Color(0.960784, 0.611765, 0.00784314, 1)
|
||||
light_energy = 12.0
|
||||
light_indirect_energy = 1.4
|
||||
light_bake_mode = 2
|
||||
editor_only = true
|
||||
omni_range = 1.6
|
||||
omni_attenuation = 2.73208
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
[gd_scene load_steps=2 format=2]
|
||||
[gd_scene format=3 uid="uid://cgi8sru6qky81"]
|
||||
|
||||
[ext_resource path="res://assets/props/godet/sm_godet_lod1.mesh" type="ArrayMesh" id=1]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/godet/sm_godet_lod1.mesh" id="1"]
|
||||
|
||||
[node name="sm_godet" type="Node3D"]
|
||||
[node name="sm_godet" type="Node3D" unique_id=2120062082]
|
||||
|
||||
[node name="sm_godet_lod1" type="MeshInstance3D" parent="."]
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 1 )
|
||||
surface_material_override/0 = null
|
||||
[node name="sm_godet_lod1" type="MeshInstance3D" parent="." unique_id=2083222404]
|
||||
mesh = ExtResource("1")
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
[gd_scene load_steps=2 format=2]
|
||||
[gd_scene format=3 uid="uid://ceyvbjwaca6gl"]
|
||||
|
||||
[ext_resource path="res://assets/props/growler/sm_growler_lod1.mesh" type="ArrayMesh" id=1]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/growler/sm_growler_lod1.mesh" id="1"]
|
||||
|
||||
[node name="sm_growler" type="Node3D"]
|
||||
[node name="sm_growler" type="Node3D" unique_id=1516724524]
|
||||
|
||||
[node name="sm_growler_lod1" type="MeshInstance3D" parent="."]
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 1 )
|
||||
surface_material_override/0 = null
|
||||
[node name="sm_growler_lod1" type="MeshInstance3D" parent="." unique_id=358704487]
|
||||
mesh = ExtResource("1")
|
||||
|
||||
@@ -1,19 +1,15 @@
|
||||
[gd_scene load_steps=4 format=2]
|
||||
[gd_scene format=3 uid="uid://ck15k8nlgsgyw"]
|
||||
|
||||
[ext_resource path="res://assets/props/parchment/sm_wood_parchment_lod1.mesh" type="ArrayMesh" id=1]
|
||||
[ext_resource path="res://assets/props/parchment/parchment.gd" type="Script" id=2]
|
||||
[ext_resource path="res://assets/props/parchment/sm_paperparchment_lod0.mesh" type="ArrayMesh" id=3]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/parchment/sm_wood_parchment_lod1.mesh" id="1"]
|
||||
[ext_resource type="Script" uid="uid://ckf1nh8pcemh1" path="res://assets/props/parchment/parchment.gd" id="2"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/parchment/sm_paperparchment_lod0.mesh" id="3"]
|
||||
|
||||
[node name="sm_parchment" type="Node3D"]
|
||||
script = ExtResource( 2 )
|
||||
[node name="sm_parchment" type="Node3D" unique_id=1182674480]
|
||||
script = ExtResource("2")
|
||||
|
||||
[node name="sm_wood_parchment_lod1" type="MeshInstance3D" parent="."]
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 1 )
|
||||
surface_material_override/0 = null
|
||||
[node name="sm_wood_parchment_lod1" type="MeshInstance3D" parent="." unique_id=875384535]
|
||||
mesh = ExtResource("1")
|
||||
|
||||
[node name="paper" type="MeshInstance3D" parent="."]
|
||||
[node name="paper" type="MeshInstance3D" parent="." unique_id=1202959838]
|
||||
visible = false
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 3 )
|
||||
surface_material_override/0 = null
|
||||
mesh = ExtResource("3")
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
[gd_scene load_steps=2 format=2]
|
||||
[gd_scene format=3 uid="uid://8v3e4xmvehhx"]
|
||||
|
||||
[ext_resource path="res://assets/props/stool b/sm_stool_2_lod1.mesh" type="ArrayMesh" id=1]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/stool b/sm_stool_2_lod1.mesh" id="1"]
|
||||
|
||||
[node name="sm_stool_b" type="Node3D"]
|
||||
[node name="sm_stool_b" type="Node3D" unique_id=782579931]
|
||||
|
||||
[node name="sm_stool_2_lod1" type="MeshInstance3D" parent="."]
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 1 )
|
||||
surface_material_override/0 = null
|
||||
[node name="sm_stool_2_lod1" type="MeshInstance3D" parent="." unique_id=873563256]
|
||||
mesh = ExtResource("1")
|
||||
|
||||
@@ -1,10 +1,8 @@
|
||||
[gd_scene load_steps=2 format=2]
|
||||
[gd_scene format=3 uid="uid://deg2or4d7j3ra"]
|
||||
|
||||
[ext_resource path="res://assets/props/table/sm_table_lod2.mesh" type="ArrayMesh" id=1]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/table/sm_table_lod2.mesh" id="1"]
|
||||
|
||||
[node name="sm_table" type="Node3D"]
|
||||
[node name="sm_table" type="Node3D" unique_id=1717889315]
|
||||
|
||||
[node name="sm_table_lod1" type="MeshInstance3D" parent="."]
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource( 1 )
|
||||
surface_material_override/0 = null
|
||||
[node name="sm_table_lod1" type="MeshInstance3D" parent="." unique_id=204112634]
|
||||
mesh = ExtResource("1")
|
||||
|
||||
-11
@@ -1,11 +0,0 @@
|
||||
extends Node
|
||||
|
||||
var table = null
|
||||
|
||||
func _get_data(datas, index):
|
||||
return datas[index].get_data()
|
||||
|
||||
func _set_data(prop_id, row_id, data):
|
||||
table.edit_data(prop_id, row_id, str(data))
|
||||
Global.database.save_db()
|
||||
return data
|
||||
@@ -1 +0,0 @@
|
||||
uid://bbyxkqilmfqeh
|
||||
@@ -1,57 +0,0 @@
|
||||
extends "res://db/MBase.gd"
|
||||
|
||||
var m_name = null
|
||||
var m_thumb = null
|
||||
var m_level = null
|
||||
var mscene = load("res://db/MScene.gd")
|
||||
|
||||
func _init(row_idx):
|
||||
m_level = row_idx
|
||||
table = Global.database.get_table_by_name("levels")
|
||||
|
||||
var datas = table.get_data_at_row_idx(m_level)
|
||||
m_name = _get_name(datas)
|
||||
m_thumb = _get_thumb(datas)
|
||||
|
||||
func object_to_find():
|
||||
var count = 0
|
||||
var datas = _scenes().get_data_by_prop_name_and_data("level", str(m_level))
|
||||
|
||||
if datas.size() != 0:
|
||||
count = datas.size()
|
||||
|
||||
return str(count)
|
||||
|
||||
func reset():
|
||||
var scene_detail = null
|
||||
var t = Global.database.get_table_by_name("scenes")
|
||||
|
||||
for row_index in range(0, t.m_rows_count):
|
||||
scene_detail = mscene.new(row_index)
|
||||
if scene_detail.label() != null:
|
||||
scene_detail.set_lock(int(false))
|
||||
|
||||
func _scenes():
|
||||
return Global.database.get_table_by_name("scenes")
|
||||
|
||||
func object_finding():
|
||||
var count = 0
|
||||
|
||||
for datas in _scenes().get_dictionary_by_prop_name_and_data("level", str(m_level)):
|
||||
if int(datas['lock']) == 1:
|
||||
count = count + 1
|
||||
|
||||
return str(count)
|
||||
|
||||
func name():
|
||||
return m_name
|
||||
|
||||
func thumbnail():
|
||||
return m_thumb
|
||||
|
||||
## PRIVATE
|
||||
func _get_name(datas):
|
||||
return str(_get_data(datas, 0))
|
||||
|
||||
func _get_thumb(datas):
|
||||
return str(_get_data(datas, 1))
|
||||
@@ -1 +0,0 @@
|
||||
uid://dtjnnc3165bhc
|
||||
@@ -1,99 +0,0 @@
|
||||
extends "res://db/MBase.gd"
|
||||
|
||||
var m_value = 0
|
||||
var m_lock = null
|
||||
var m_label = null
|
||||
var m_label_counter = null
|
||||
var m_tick_reference = 0
|
||||
var m_key = null
|
||||
var m_level = null
|
||||
var m_mesh = null
|
||||
var m_counter = null
|
||||
var m_row_id = null
|
||||
|
||||
const LOCK_ID = 0
|
||||
const LABEL_ID = 1
|
||||
const KEY_ID = 2
|
||||
const LEVEL_ID = 3
|
||||
const MESH_ID = 4
|
||||
const LABEL_COUNTER = 5
|
||||
const COUNTER_ID = 6
|
||||
|
||||
func _init(row_index):
|
||||
table = Global.database.get_table_by_name("scenes")
|
||||
m_row_id = row_index
|
||||
var datas = table.get_data_at_row_idx(m_row_id)
|
||||
|
||||
if _get_level(datas) == Global.current_scene_int:
|
||||
m_key = _get_key(datas)
|
||||
m_lock = _get_lock(datas)
|
||||
m_label = _get_label(datas)
|
||||
m_label_counter = _get_label_counter(datas)
|
||||
m_mesh = _get_mesh(datas)
|
||||
m_counter = _get_counter(datas)
|
||||
|
||||
func key():
|
||||
return m_key
|
||||
|
||||
func label():
|
||||
return m_label
|
||||
|
||||
func label_counter():
|
||||
return m_label_counter
|
||||
|
||||
func lock():
|
||||
return m_lock
|
||||
|
||||
func set_lock(p_value):
|
||||
m_lock = _set_data(LOCK_ID, m_row_id, p_value)
|
||||
|
||||
func mesh():
|
||||
return m_mesh
|
||||
|
||||
func tween():
|
||||
return m_mesh + "/Tween"
|
||||
|
||||
func set_mesh(p_value):
|
||||
m_mesh = p_value
|
||||
|
||||
func tick_reference():
|
||||
return m_tick_reference
|
||||
|
||||
func set_tick_reference(p_value):
|
||||
m_tick_reference = p_value
|
||||
|
||||
func value():
|
||||
return m_value
|
||||
|
||||
func set_value(p_value):
|
||||
m_value = p_value
|
||||
|
||||
func audio_sound():
|
||||
var stream = load("res://assets/sounds/objects/" + label() + ".ogg")
|
||||
stream.set_loop(false)
|
||||
return stream
|
||||
|
||||
func counter():
|
||||
return m_counter
|
||||
|
||||
## PRIVATE
|
||||
func _get_lock(datas):
|
||||
return bool(int(_get_data(datas, LOCK_ID)))
|
||||
|
||||
func _get_label(datas):
|
||||
return str(_get_data(datas, LABEL_ID))
|
||||
|
||||
func _get_key(datas):
|
||||
return str(_get_data(datas, KEY_ID))
|
||||
|
||||
func _get_level(datas):
|
||||
return int(_get_data(datas, LEVEL_ID))
|
||||
|
||||
func _get_mesh(datas):
|
||||
return "HiddenObjectsItems/" + str(_get_data(datas, MESH_ID))
|
||||
|
||||
func _get_label_counter(datas):
|
||||
return str(_get_data(datas, LABEL_COUNTER))
|
||||
|
||||
func _get_counter(datas):
|
||||
return int(_get_data(datas, COUNTER_ID))
|
||||
@@ -1 +0,0 @@
|
||||
uid://cntdl3tocn0tv
|
||||
@@ -1,70 +0,0 @@
|
||||
extends "res://db/MBase.gd"
|
||||
|
||||
var m_langue = null
|
||||
var m_gyroscope = null
|
||||
var m_ambient_sound = null
|
||||
var m_resolution = null
|
||||
var m_fullscreen = null
|
||||
var m_version = null
|
||||
|
||||
const ROW_ID = 0
|
||||
const LANGUE_ID = 0
|
||||
const GYRSOCPE_ID = 1
|
||||
const AMBIENT_SOUND = 2
|
||||
const RESOLUTION = 3
|
||||
const FULLSCREEN = 4
|
||||
const VERSION = 5
|
||||
|
||||
func _init():
|
||||
table = Global.database.get_table_by_name("settings")
|
||||
var datas = table.get_data_at_row_idx(ROW_ID)
|
||||
|
||||
m_langue = _get_data(datas, LANGUE_ID)
|
||||
m_gyroscope = _get_data(datas, GYRSOCPE_ID)
|
||||
m_ambient_sound = _get_data(datas, AMBIENT_SOUND)
|
||||
m_resolution = _get_data(datas, RESOLUTION)
|
||||
m_fullscreen = _get_data(datas, FULLSCREEN)
|
||||
m_version = _get_data(datas, VERSION)
|
||||
|
||||
func get_langue():
|
||||
return int(m_langue)
|
||||
|
||||
func get_gyroscope():
|
||||
return bool(int(m_gyroscope))
|
||||
|
||||
func get_ambient_sound():
|
||||
return bool(int(m_ambient_sound))
|
||||
|
||||
func get_resolution():
|
||||
return m_resolution.split(" x ")
|
||||
|
||||
func get_fullscreen():
|
||||
return bool(int(m_fullscreen))
|
||||
|
||||
func get_version():
|
||||
return "v" + str(m_version)
|
||||
|
||||
func set_langue(value):
|
||||
m_langue = _set_data(LANGUE_ID, ROW_ID, value)
|
||||
|
||||
return get_langue()
|
||||
|
||||
func set_gyroscope(value):
|
||||
m_gyroscope = _set_data(GYRSOCPE_ID, ROW_ID, value)
|
||||
|
||||
return get_gyroscope()
|
||||
|
||||
func set_ambient_sound(value):
|
||||
m_ambient_sound = _set_data(AMBIENT_SOUND, ROW_ID, value)
|
||||
|
||||
return get_ambient_sound()
|
||||
|
||||
func set_resolution(value):
|
||||
m_resolution = _set_data(RESOLUTION, ROW_ID, value)
|
||||
|
||||
return get_resolution()
|
||||
|
||||
func set_fullscreen(value):
|
||||
m_fullscreen = _set_data(FULLSCREEN, ROW_ID, value)
|
||||
|
||||
return get_fullscreen()
|
||||
@@ -1 +0,0 @@
|
||||
uid://bf50wtagbmftd
|
||||
@@ -0,0 +1,22 @@
|
||||
class_name LevelEntry extends Resource
|
||||
|
||||
# A single row from the 'levels' table of ahog.json.
|
||||
|
||||
@export var index: int = -1
|
||||
@export var name: String = ""
|
||||
@export var thumb: String = ""
|
||||
|
||||
func object_to_find() -> String:
|
||||
return str(Global.database.scenes_for_level(index).size())
|
||||
|
||||
func object_finding() -> String:
|
||||
var count := 0
|
||||
for s in Global.database.scenes_for_level(index):
|
||||
if s.lock:
|
||||
count += 1
|
||||
return str(count)
|
||||
|
||||
func reset() -> void:
|
||||
for s in Global.database.scenes_for_level(index):
|
||||
s.lock = false
|
||||
Global.database.save()
|
||||
@@ -0,0 +1 @@
|
||||
uid://dp7cvr2c75gj5
|
||||
@@ -0,0 +1,25 @@
|
||||
class_name SceneEntry extends Resource
|
||||
|
||||
# A single hidden-object row from the 'scenes' table of ahog.json.
|
||||
|
||||
@export var lock: bool = false
|
||||
@export var label: String = ""
|
||||
@export var key: String = ""
|
||||
@export var level: int = -1
|
||||
@export var mesh: String = ""
|
||||
@export var label_counter: String = ""
|
||||
@export var counter: int = 1
|
||||
|
||||
# Runtime-only state for the dissolve animation tracker (not persisted).
|
||||
var dissolve_value: float = 0.0
|
||||
var dissolve_tick_reference: int = 0
|
||||
var dissolved: bool = false
|
||||
|
||||
func mesh_path() -> String:
|
||||
return "HiddenObjectsItems/" + mesh
|
||||
|
||||
func audio_sound() -> AudioStream:
|
||||
var stream: AudioStream = load("res://assets/sounds/objects/%s.ogg" % label)
|
||||
if stream is AudioStreamOggVorbis:
|
||||
stream.loop = false
|
||||
return stream
|
||||
@@ -0,0 +1 @@
|
||||
uid://ciro4yspcb6bi
|
||||
@@ -0,0 +1,13 @@
|
||||
class_name SettingsData extends Resource
|
||||
|
||||
# Single-row 'settings' table from ahog.json.
|
||||
|
||||
@export var langue: int = 0
|
||||
@export var gyroscope: bool = false
|
||||
@export var ambient_sound: bool = false
|
||||
@export var resolution: String = "1280 x 720"
|
||||
@export var fullscreen: bool = false
|
||||
@export var version: String = "1.0.0"
|
||||
|
||||
func resolution_split() -> PackedStringArray:
|
||||
return resolution.split(" x ")
|
||||
@@ -0,0 +1 @@
|
||||
uid://dbgb8gs3fddt0
|
||||
@@ -1,40 +0,0 @@
|
||||
[remap]
|
||||
|
||||
importer="texture"
|
||||
type="CompressedTexture2D"
|
||||
uid="uid://coiv0mhlykb6o"
|
||||
path="res://.godot/imported/CheckLightmap.exr-a30cb7f4507712e4e8789c79b715eefb.ctex"
|
||||
metadata={
|
||||
"vram_texture": false
|
||||
}
|
||||
|
||||
[deps]
|
||||
|
||||
source_file="res://developers/aurelien/CheckLightmap.exr"
|
||||
dest_files=["res://.godot/imported/CheckLightmap.exr-a30cb7f4507712e4e8789c79b715eefb.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
|
||||
@@ -1 +0,0 @@
|
||||
uid://pwnyre6lidoy
|
||||
@@ -1,45 +1,38 @@
|
||||
[gd_scene format=2]
|
||||
[gd_scene format=3 uid="uid://bd3s4000bmco5"]
|
||||
|
||||
[node name="Control" type="Control"]
|
||||
[node name="Control" type="Control" unique_id=1050222790]
|
||||
layout_mode = 3
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="GridContainer" type="GridContainer" parent="."]
|
||||
[node name="GridContainer" type="GridContainer" parent="." unique_id=1135032533]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
theme_override_constants/v_separation = 10
|
||||
theme_override_constants/h_separation = 10
|
||||
theme_override_constants/v_separation = 10
|
||||
columns = 2
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TabContainerGeneral" type="TabContainer" parent="GridContainer"]
|
||||
offset_right = 635.0
|
||||
offset_bottom = 233.0
|
||||
[node name="TabContainerGeneral" type="TabContainer" parent="GridContainer" unique_id=577267571]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
tab_alignment = 0
|
||||
current_tab = 0
|
||||
|
||||
[node name="Generale" type="TabBar" parent="GridContainer/TabContainerGeneral"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 4.0
|
||||
offset_top = 32.0
|
||||
offset_right = 36.0
|
||||
offset_bottom = 20.0
|
||||
[node name="Generale" type="TabBar" parent="GridContainer/TabContainerGeneral" unique_id=938207251]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
scrolling_enabled = false
|
||||
metadata/_tab_index = 0
|
||||
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerGeneral/Generale"]
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerGeneral/Generale" unique_id=75607507]
|
||||
layout_mode = 0
|
||||
offset_right = 624.0
|
||||
offset_bottom = 221.0
|
||||
size_flags_horizontal = 3
|
||||
@@ -49,86 +42,58 @@ text = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed non risus.
|
||||
Ut velit mauris, egestas sed, gravida nec, ornare ut, mi. Aenean ut orci vel massa suscipit pulvinar. Nulla sollicitudin. Fusce varius, ligula non tempus aliquam, nunc turpis ullamcorper nibh, in tempus sapien eros vitae ligula. Pellentesque rhoncus nunc et augue. Integer id felis. Curabitur aliquet pellentesque diam. Integer quis metus vitae elit lobortis egestas. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Morbi vel erat non mauris convallis vehicula. Nulla et sapien. Integer tortor tellus, aliquam faucibus, convallis id, congue eu, quam. Mauris ullamcorper felis vitae erat. Proin feugiat, augue non elementum posuere, metus purus iaculis lectus, et tristique ligula justo vitae magna.
|
||||
Aliquam convallis sollicitudin purus. Praesent aliquam, enim at fermentum mollis, ligula massa adipiscing nisl, ac euismod nibh nisl eu lectus. Fusce vulputate sem at sapien. Vivamus leo. Aliquam euismod libero eu enim. Nulla nec felis sed leo placerat imperdiet. Aenean suscipit nulla in justo. Suspendisse cursus rutrum augue. Nulla tincidunt tincidunt mi. Curabitur iaculis, lorem vel rhoncus faucibus, felis magna fermentum augue, et ultricies lacus lorem varius purus. Curabitur eu amet."
|
||||
scroll_active = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TabContainerMobile" type="TabContainer" parent="GridContainer"]
|
||||
offset_left = 645.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 233.0
|
||||
[node name="TabContainerMobile" type="TabContainer" parent="GridContainer" unique_id=1137178016]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
tab_alignment = 0
|
||||
current_tab = 0
|
||||
|
||||
[node name="Mobile" type="TabBar" parent="GridContainer/TabContainerMobile"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 4.0
|
||||
offset_top = 32.0
|
||||
offset_right = -4.0
|
||||
offset_bottom = -4.0
|
||||
tab_alignment = 0
|
||||
[node name="Mobile" type="TabBar" parent="GridContainer/TabContainerMobile" unique_id=1349664801]
|
||||
layout_mode = 2
|
||||
metadata/_tab_index = 0
|
||||
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerMobile/Mobile"]
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerMobile/Mobile" unique_id=1140109331]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Quis autem vel eum iure reprehenderit, qui in ea voluptate velit esse, quam nihil molestiae consequatur, vel illum, qui dolorem eum fugiat, quo voluptas nulla pariatur?"
|
||||
scroll_active = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TabContainerSound" type="TabContainer" parent="GridContainer"]
|
||||
offset_top = 243.0
|
||||
offset_right = 635.0
|
||||
offset_bottom = 476.0
|
||||
[node name="TabContainerSound" type="TabContainer" parent="GridContainer" unique_id=1476221752]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
tab_alignment = 0
|
||||
current_tab = 0
|
||||
|
||||
[node name="Sound" type="TabBar" parent="GridContainer/TabContainerSound"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 4.0
|
||||
offset_top = 32.0
|
||||
offset_right = -4.0
|
||||
offset_bottom = -4.0
|
||||
tab_alignment = 0
|
||||
[node name="Sound" type="TabBar" parent="GridContainer/TabContainerSound" unique_id=1892732599]
|
||||
layout_mode = 2
|
||||
metadata/_tab_index = 0
|
||||
|
||||
[node name="RichTextLabel2" type="RichTextLabel" parent="GridContainer/TabContainerSound/Sound"]
|
||||
[node name="RichTextLabel2" type="RichTextLabel" parent="GridContainer/TabContainerSound/Sound" unique_id=1420180720]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Quis autem vel eum iure reprehenderit, qui in ea voluptate velit esse, quam nihil molestiae consequatur, vel illum, qui dolorem eum fugiat, quo voluptas nulla pariatur?"
|
||||
scroll_active = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TabContainerGraphisme" type="TabContainer" parent="GridContainer"]
|
||||
offset_left = 645.0
|
||||
offset_top = 243.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 476.0
|
||||
[node name="TabContainerGraphisme" type="TabContainer" parent="GridContainer" unique_id=180951967]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
tab_alignment = 0
|
||||
current_tab = 0
|
||||
|
||||
[node name="Graphisme" type="TabBar" parent="GridContainer/TabContainerGraphisme"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 4.0
|
||||
offset_top = 32.0
|
||||
offset_right = -4.0
|
||||
offset_bottom = -4.0
|
||||
tab_alignment = 0
|
||||
[node name="Graphisme" type="TabBar" parent="GridContainer/TabContainerGraphisme" unique_id=1708425172]
|
||||
layout_mode = 2
|
||||
scrolling_enabled = false
|
||||
metadata/_tab_index = 0
|
||||
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerGraphisme/Graphisme"]
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerGraphisme/Graphisme" unique_id=943610410]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
text = "« Pour vous faire mieux connaitre d’où vient l’erreur de ceux qui blâment la volupté, et qui louent en quelque sorte la douleur, je vais entrer dans une explication plus étendue, et vous faire voir tout ce qui a été dit là-dessus par l’inventeur de la vérité, et, pour ainsi dire, par l’architecte de la vie heureuse.
|
||||
@@ -141,58 +106,39 @@ J’en dis autant de ceux qui, par mollesse d’esprit, c’est-à-dire par la c
|
||||
|
||||
La règle que suit en cela un homme sage, c’est de renoncer à de légères voluptés pour en avoir de plus grandes, et de savoir supporter des douleurs légères pour en éviter de plus fâcheuses. »"
|
||||
scroll_active = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TabContainerSound2" type="TabContainer" parent="GridContainer"]
|
||||
offset_top = 486.0
|
||||
offset_right = 635.0
|
||||
offset_bottom = 719.0
|
||||
[node name="TabContainerSound2" type="TabContainer" parent="GridContainer" unique_id=303482291]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
tab_alignment = 0
|
||||
current_tab = 0
|
||||
|
||||
[node name="Sound" type="TabBar" parent="GridContainer/TabContainerSound2"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 4.0
|
||||
offset_top = 32.0
|
||||
offset_right = -4.0
|
||||
offset_bottom = -4.0
|
||||
tab_alignment = 0
|
||||
[node name="Sound" type="TabBar" parent="GridContainer/TabContainerSound2" unique_id=1588376455]
|
||||
layout_mode = 2
|
||||
metadata/_tab_index = 0
|
||||
|
||||
[node name="RichTextLabel2" type="RichTextLabel" parent="GridContainer/TabContainerSound2/Sound"]
|
||||
[node name="RichTextLabel2" type="RichTextLabel" parent="GridContainer/TabContainerSound2/Sound" unique_id=1866823306]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
text = "Quis autem vel eum iure reprehenderit, qui in ea voluptate velit esse, quam nihil molestiae consequatur, vel illum, qui dolorem eum fugiat, quo voluptas nulla pariatur?"
|
||||
scroll_active = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TabContainerGraphisme2" type="TabContainer" parent="GridContainer"]
|
||||
offset_left = 645.0
|
||||
offset_top = 486.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 719.0
|
||||
[node name="TabContainerGraphisme2" type="TabContainer" parent="GridContainer" unique_id=1071745587]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
tab_alignment = 0
|
||||
current_tab = 0
|
||||
|
||||
[node name="Graphisme" type="TabBar" parent="GridContainer/TabContainerGraphisme2"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 4.0
|
||||
offset_top = 32.0
|
||||
offset_right = -4.0
|
||||
offset_bottom = -4.0
|
||||
tab_alignment = 0
|
||||
[node name="Graphisme" type="TabBar" parent="GridContainer/TabContainerGraphisme2" unique_id=704932079]
|
||||
layout_mode = 2
|
||||
scrolling_enabled = false
|
||||
metadata/_tab_index = 0
|
||||
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerGraphisme2/Graphisme"]
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="GridContainer/TabContainerGraphisme2/Graphisme" unique_id=1701535678]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
text = "« Pour vous faire mieux connaitre d’où vient l’erreur de ceux qui blâment la volupté, et qui louent en quelque sorte la douleur, je vais entrer dans une explication plus étendue, et vous faire voir tout ce qui a été dit là-dessus par l’inventeur de la vérité, et, pour ainsi dire, par l’architecte de la vie heureuse.
|
||||
@@ -205,6 +151,3 @@ J’en dis autant de ceux qui, par mollesse d’esprit, c’est-à-dire par la c
|
||||
|
||||
La règle que suit en cela un homme sage, c’est de renoncer à de légères voluptés pour en avoir de plus grandes, et de savoir supporter des douleurs légères pour en éviter de plus fâcheuses. »"
|
||||
scroll_active = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
@@ -1,46 +1,36 @@
|
||||
[gd_scene format=2]
|
||||
[gd_scene format=3 uid="uid://dbplgs43pk2ud"]
|
||||
|
||||
[node name="Control" type="ScrollContainer"]
|
||||
[node name="Control" type="ScrollContainer" unique_id=1602493395]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
scroll_vertical_enabled = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 1280.0
|
||||
custom_minimum_size = Vector2( 1280, 1280 )
|
||||
[node name="MarginContainer" type="MarginContainer" parent="." unique_id=2140982364]
|
||||
custom_minimum_size = Vector2(1280, 1280)
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
theme_override_constants/margin_right = 10
|
||||
theme_override_constants/margin_top = 10
|
||||
theme_override_constants/margin_left = 10
|
||||
theme_override_constants/margin_top = 10
|
||||
theme_override_constants/margin_right = 10
|
||||
theme_override_constants/margin_bottom = 10
|
||||
|
||||
[node name="TabContainerGeneral" type="TabContainer" parent="MarginContainer"]
|
||||
offset_left = 10.0
|
||||
offset_top = 10.0
|
||||
offset_right = 1270.0
|
||||
offset_bottom = 1270.0
|
||||
custom_minimum_size = Vector2( 0, 1080 )
|
||||
[node name="TabContainerGeneral" type="TabContainer" parent="MarginContainer" unique_id=1768198311]
|
||||
custom_minimum_size = Vector2(0, 1080)
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
tab_alignment = 0
|
||||
current_tab = 0
|
||||
|
||||
[node name="Generale" type="TabBar" parent="MarginContainer/TabContainerGeneral"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 4.0
|
||||
offset_top = 32.0
|
||||
offset_right = -4.0
|
||||
offset_bottom = -4.0
|
||||
[node name="Generale" type="TabBar" parent="MarginContainer/TabContainerGeneral" unique_id=2056320346]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
scrolling_enabled = false
|
||||
metadata/_tab_index = 0
|
||||
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="MarginContainer/TabContainerGeneral/Generale"]
|
||||
[node name="RichTextLabel" type="RichTextLabel" parent="MarginContainer/TabContainerGeneral/Generale" unique_id=1728656187]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
@@ -69,6 +59,3 @@ Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed non risus. Suspendi
|
||||
Ut velit mauris, egestas sed, gravida nec, ornare ut, mi. Aenean ut orci vel massa suscipit pulvinar. Nulla sollicitudin. Fusce varius, ligula non tempus aliquam, nunc turpis ullamcorper nibh, in tempus sapien eros vitae ligula. Pellentesque rhoncus nunc et augue. Integer id felis. Curabitur aliquet pellentesque diam. Integer quis metus vitae elit lobortis egestas. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Morbi vel erat non mauris convallis vehicula. Nulla et sapien. Integer tortor tellus, aliquam faucibus, convallis id, congue eu, quam. Mauris ullamcorper felis vitae erat. Proin feugiat, augue non elementum posuere, metus purus iaculis lectus, et tristique ligula justo vitae magna.
|
||||
Aliquam convallis sollicitudin purus. Praesent aliquam, enim at fermentum mollis, ligula massa adipiscing nisl, ac euismod nibh nisl eu lectus. Fusce vulputate sem at sapien. Vivamus leo. Aliquam euismod libero eu enim. Nulla nec felis sed leo placerat imperdiet. Aenean suscipit nulla in justo. Suspendisse cursus rutrum augue. Nulla tincidunt tincidunt mi. Curabitur iaculis, lorem vel rhoncus faucibus, felis magna fermentum augue, et ultricies lacus lorem varius purus. Curabitur eu amet."
|
||||
scroll_active = false
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
@@ -1,11 +1,13 @@
|
||||
[gd_scene load_steps=5 format=2]
|
||||
[gd_scene format=3 uid="uid://v0uklmwi4vrx"]
|
||||
|
||||
[ext_resource path="res://assets/ui/themes/tab_select/UI-level-btn-leather.png" type="Texture2D" id=1]
|
||||
[ext_resource path="res://assets/ui/themes/tab_select/UI-Button-Count.png" type="Texture2D" id=2]
|
||||
[ext_resource path="res://assets/ui/themes/tab_select/UI-level-btn-shadow.png" type="Texture2D" id=3]
|
||||
[ext_resource path="res://assets/ui/themes/tab_select/UI-Button-Reset.png" type="Texture2D" id=4]
|
||||
[ext_resource type="Texture2D" uid="uid://g8iyo0t47j30" path="res://assets/ui/themes/tab_select/UI-level-btn-leather.png" id="1"]
|
||||
[ext_resource type="Texture2D" uid="uid://bs22t34m61as7" path="res://assets/ui/themes/tab_select/UI-Button-Count.png" id="2"]
|
||||
[ext_resource type="Texture2D" uid="uid://dqoumo46armbe" path="res://assets/ui/themes/tab_select/UI-level-btn-shadow.png" id="3"]
|
||||
[ext_resource type="Texture2D" uid="uid://bsrpumg1bhtas" path="res://assets/ui/themes/tab_select/UI-Button-Reset.png" id="4"]
|
||||
|
||||
[node name="Control" type="Control"]
|
||||
[node name="Control" type="Control" unique_id=1768959998]
|
||||
layout_mode = 3
|
||||
anchors_preset = 5
|
||||
anchor_left = 0.5
|
||||
anchor_right = 0.5
|
||||
offset_left = -639.646
|
||||
@@ -14,88 +16,61 @@ offset_right = 640.354
|
||||
offset_bottom = 720.707
|
||||
size_flags_horizontal = 0
|
||||
size_flags_vertical = 0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="BckShadow" type="TextureRect" parent="."]
|
||||
[node name="BckShadow" type="TextureRect" parent="." unique_id=1945468253]
|
||||
layout_mode = 0
|
||||
anchor_left = 0.5
|
||||
anchor_right = 0.5
|
||||
offset_left = -227.0
|
||||
offset_right = 228.0
|
||||
offset_bottom = 720.0
|
||||
texture = ExtResource( 3 )
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
texture = ExtResource("3")
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
[node name="MarginContainer" type="MarginContainer" parent="." unique_id=1876727334]
|
||||
layout_mode = 0
|
||||
anchor_left = 0.5
|
||||
anchor_right = 0.5
|
||||
offset_left = -228.5
|
||||
offset_right = 228.5
|
||||
offset_bottom = 436.0
|
||||
theme_override_constants/margin_right = 20
|
||||
theme_override_constants/margin_top = 20
|
||||
theme_override_constants/margin_left = 20
|
||||
theme_override_constants/margin_top = 20
|
||||
theme_override_constants/margin_right = 20
|
||||
theme_override_constants/margin_bottom = 0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="AlignColumn" type="VBoxContainer" parent="MarginContainer"]
|
||||
offset_left = 20.0
|
||||
offset_top = 20.0
|
||||
offset_right = 437.0
|
||||
offset_bottom = 549.0
|
||||
[node name="AlignColumn" type="VBoxContainer" parent="MarginContainer" unique_id=935049544]
|
||||
layout_mode = 2
|
||||
theme_override_constants/separation = 0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TextureRect" type="TextureRect" parent="MarginContainer/AlignColumn"]
|
||||
offset_right = 417.0
|
||||
offset_bottom = 416.0
|
||||
texture = ExtResource( 1 )
|
||||
[node name="TextureRect" type="TextureRect" parent="MarginContainer/AlignColumn" unique_id=1700077512]
|
||||
layout_mode = 2
|
||||
texture = ExtResource("1")
|
||||
|
||||
[node name="VBoxContainer" type="HBoxContainer" parent="MarginContainer/AlignColumn"]
|
||||
offset_top = 416.0
|
||||
offset_right = 417.0
|
||||
offset_bottom = 529.0
|
||||
[node name="VBoxContainer" type="HBoxContainer" parent="MarginContainer/AlignColumn" unique_id=1865804251]
|
||||
layout_mode = 2
|
||||
theme_override_constants/separation = 0
|
||||
alignment = 1
|
||||
|
||||
[node name="TextureRect2" type="TextureRect" parent="MarginContainer/AlignColumn/VBoxContainer"]
|
||||
offset_left = 7.0
|
||||
offset_right = 185.0
|
||||
offset_bottom = 113.0
|
||||
[node name="TextureRect2" type="TextureRect" parent="MarginContainer/AlignColumn/VBoxContainer" unique_id=1437024102]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 0
|
||||
texture = ExtResource( 4 )
|
||||
texture = ExtResource("4")
|
||||
|
||||
[node name="TextureRect3" type="TextureRect" parent="MarginContainer/AlignColumn/VBoxContainer"]
|
||||
offset_left = 185.0
|
||||
offset_right = 410.0
|
||||
offset_bottom = 113.0
|
||||
pivot_offset = Vector2( -231.224, -72.2715 )
|
||||
[node name="TextureRect3" type="TextureRect" parent="MarginContainer/AlignColumn/VBoxContainer" unique_id=360483509]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 0
|
||||
texture = ExtResource( 2 )
|
||||
texture = ExtResource("2")
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/AlignColumn/VBoxContainer/TextureRect3"]
|
||||
[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/AlignColumn/VBoxContainer/TextureRect3" unique_id=1743053910]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
theme_override_constants/margin_bottom = 10
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="MarginContainer/AlignColumn/VBoxContainer/TextureRect3/MarginContainer"]
|
||||
offset_right = 225.0
|
||||
offset_bottom = 103.0
|
||||
[node name="Label" type="Label" parent="MarginContainer/AlignColumn/VBoxContainer/TextureRect3/MarginContainer" unique_id=1067435383]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 7
|
||||
text = "X / 10"
|
||||
align = 1
|
||||
valign = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
|
||||
+15
-21
@@ -4,55 +4,49 @@ extends Node
|
||||
@export var setting: PackedScene = load("res://scenes/UI/settings/Settings.tscn")
|
||||
@export var choose_scene: PackedScene = load("res://scenes/UI/choose_scenes/ChooseScene.tscn")
|
||||
|
||||
@onready var current_scene = "title"
|
||||
@onready var stream_button = preload("res://assets/sounds/click-button.ogg")
|
||||
@onready var home = $MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/CenterContainer/TextureRect
|
||||
@onready var stream_button: AudioStream = preload("res://assets/sounds/click-button.ogg")
|
||||
@onready var home: TextureButton = $MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/CenterContainer/TextureRect
|
||||
|
||||
func _ready():
|
||||
func _ready() -> void:
|
||||
_translation()
|
||||
home.set_focus_mode(2)
|
||||
home.focus_mode = Control.FOCUS_ALL
|
||||
home.grab_focus()
|
||||
_apply_scene(title)
|
||||
_configure_sound()
|
||||
|
||||
func _configure_sound():
|
||||
stream_button.set_loop(false)
|
||||
func _configure_sound() -> void:
|
||||
if stream_button is AudioStreamOggVorbis:
|
||||
stream_button.loop = false
|
||||
$MarginContainer/HBoxContainer/UI_summary/ClickButton.stream = stream_button
|
||||
|
||||
## PRIVATE
|
||||
func _translation():
|
||||
func _translation() -> void:
|
||||
$MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ButtonPuzzle/Label.text = tr("MAIN_BUTTON_PUZZLES")
|
||||
$MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ButtonSetting/Label.text = tr("MAIN_BUTTON_SETTINGS")
|
||||
$MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ButtonQuit/Label.text = tr("MAIN_BUTTON_QUIT")
|
||||
$MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ContainerVersion/LabelVersion.text = Setting.get_setting_version()
|
||||
|
||||
func _apply_scene(actual_scene):
|
||||
var node = get_node("MarginContainer/HBoxContainer/MarginContainer/")
|
||||
|
||||
func _apply_scene(actual_scene: PackedScene) -> void:
|
||||
var node := get_node("MarginContainer/HBoxContainer/MarginContainer/")
|
||||
if node.get_child_count() != 0:
|
||||
node.get_child(0).queue_free()
|
||||
|
||||
node.add_child(actual_scene.instantiate())
|
||||
|
||||
# Load scene for select game
|
||||
func _on_ButtonPuzzle_pressed():
|
||||
func _on_ButtonPuzzle_pressed() -> void:
|
||||
_sound_button()
|
||||
_apply_scene(choose_scene)
|
||||
|
||||
# Load scene settings
|
||||
func _on_ButtonSetting_pressed():
|
||||
func _on_ButtonSetting_pressed() -> void:
|
||||
_sound_button()
|
||||
_apply_scene(setting)
|
||||
|
||||
# Click to icon game
|
||||
func _on_TextureRect_pressed():
|
||||
func _on_TextureRect_pressed() -> void:
|
||||
_sound_button()
|
||||
_apply_scene(title)
|
||||
|
||||
# Quit the game
|
||||
func _on_ButtonQuit_pressed():
|
||||
func _on_ButtonQuit_pressed() -> void:
|
||||
_sound_button()
|
||||
get_tree().quit(0)
|
||||
|
||||
func _sound_button():
|
||||
func _sound_button() -> void:
|
||||
$MarginContainer/HBoxContainer/UI_summary/ClickButton.play()
|
||||
|
||||
+5
-57
@@ -1,8 +1,8 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://bwkk5khc1y210"]
|
||||
|
||||
[ext_resource type="Script" path="res://scenes/Main.gd" id="1"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/UI/background/Background.tscn" id="5"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/UI/summary/Summary.tscn" id="8"]
|
||||
[ext_resource type="Script" uid="uid://by2coyg8u0u67" path="res://scenes/Main.gd" id="1"]
|
||||
[ext_resource type="PackedScene" uid="uid://edbpygl0vh8c" path="res://scenes/UI/background/Background.tscn" id="5"]
|
||||
[ext_resource type="PackedScene" uid="uid://bjrsudbbriijh" path="res://scenes/UI/summary/Summary.tscn" id="8"]
|
||||
|
||||
[node name="Main" type="Control" unique_id=1146227135]
|
||||
layout_mode = 3
|
||||
@@ -15,7 +15,6 @@ script = ExtResource("1")
|
||||
|
||||
[node name="BackgroundPicture" parent="." unique_id=1341502133 instance=ExtResource("5")]
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
|
||||
@@ -32,61 +31,10 @@ layout_mode = 2
|
||||
size_flags_horizontal = 0
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="PanelWood" parent="MarginContainer/HBoxContainer/UI_summary" index="0"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="VBoxContainer" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood" index="0"]
|
||||
layout_mode = 0
|
||||
[node name="VBoxContainer" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood" parent_id_path=PackedInt32Array(1690362681, 1864179308) index="0" unique_id=1602451066]
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
|
||||
[node name="CenterContainer" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="0"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="TextureRect" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/CenterContainer" index="0"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="ButtonPuzzle" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="1"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ButtonPuzzle" index="0"]
|
||||
|
||||
[node name="ButtonSetting" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="2"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ButtonSetting" index="0"]
|
||||
|
||||
[node name="ButtonCredits" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="3"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ButtonCredits" index="0"]
|
||||
|
||||
[node name="MarginContainer" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="4"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="ButtonQuit" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="5"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ButtonQuit" index="0"]
|
||||
|
||||
[node name="ContainerVersion" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="6"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="MarginLeft" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ContainerVersion" index="0"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="LabelVersion" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ContainerVersion" index="1"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="MarginRight" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer/ContainerVersion" index="2"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="MarginContainerBottom" parent="MarginContainer/HBoxContainer/UI_summary/PanelWood/VBoxContainer" index="7"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="TextureRect" parent="MarginContainer/HBoxContainer/UI_summary" index="1"]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="MarginContainer/HBoxContainer" unique_id=1017122368]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 7
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://edbpygl0vh8c"]
|
||||
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/bck.jpg" id="1"]
|
||||
[ext_resource type="Texture2D" uid="uid://ypy03afi81pt" path="res://assets/ui/themes/bck.jpg" id="1"]
|
||||
|
||||
[node name="BackgroundPicture" type="TextureRect"]
|
||||
[node name="BackgroundPicture" type="TextureRect" unique_id=42074458]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
texture = ExtResource("1")
|
||||
|
||||
@@ -2,68 +2,57 @@ extends Control
|
||||
|
||||
@export var template: PackedScene = load("res://scenes/UI/choose_scenes/parts/Template.tscn")
|
||||
|
||||
func _ready():
|
||||
_load_button_access_scenes()
|
||||
func _ready() -> void:
|
||||
for level in Global.database.levels:
|
||||
_apply_scene(level)
|
||||
|
||||
## PRIVATE
|
||||
func _load_button_access_scenes():
|
||||
for row_index in range(0, Global.database.get_table_by_name("levels").m_rows_count):
|
||||
_apply_scene(load("res://db/MLevel.gd").new(row_index), row_index)
|
||||
|
||||
func _apply_scene(level, index):
|
||||
$MarginContainer.add_child(_load_scene(level.name()))
|
||||
var node = _build_path(level.name())
|
||||
|
||||
func _apply_scene(level: LevelEntry) -> void:
|
||||
$MarginContainer.add_child(_load_scene(level.name))
|
||||
var node := _build_path(level.name)
|
||||
_configure_select(level, node)
|
||||
configure_reset(level, node, index, false)
|
||||
configure_reset(level, node, false)
|
||||
configure_counter(level, node)
|
||||
|
||||
func _load_scene(p_name):
|
||||
var template_instance = template.instantiate()
|
||||
func _load_scene(p_name: String) -> Node:
|
||||
var template_instance := template.instantiate()
|
||||
template_instance.set_name(p_name)
|
||||
|
||||
return template_instance
|
||||
|
||||
func _build_path(p_name):
|
||||
func _build_path(p_name: String) -> String:
|
||||
return "MarginContainer/" + p_name
|
||||
|
||||
func _load_texture(thumbnail):
|
||||
return load(thumbnail)
|
||||
|
||||
func _configure_select(level, node):
|
||||
var selector = get_node(node+"/MarginContainer/CenterAlign/MainButton")
|
||||
var thumbnail = get_node(node+"/MarginContainer/CenterAlign/MainButton/MarginStich/ThumbnailLevel")
|
||||
|
||||
thumbnail.set_texture(_load_texture(level.thumbnail()))
|
||||
var handler = Event.level_pressed(level.name())
|
||||
func _configure_select(level: LevelEntry, node: String) -> void:
|
||||
var selector := get_node(node + "/MarginContainer/CenterAlign/MainButton")
|
||||
var thumbnail: TextureRect = get_node(node + "/MarginContainer/CenterAlign/MainButton/MarginStich/ThumbnailLevel")
|
||||
thumbnail.texture = load(level.thumb)
|
||||
var handler := Event.level_pressed(level.name)
|
||||
if handler.is_valid():
|
||||
selector.pressed.connect(handler)
|
||||
|
||||
func configure_reset(level, node, index, animate):
|
||||
var reset = get_node(node+"/MarginContainer/CenterAlign/MainButton/TabAlign/ButtonReset")
|
||||
var animation = get_node(node+"/AnimationPlayer")
|
||||
func configure_reset(level: LevelEntry, node: String, animate: bool) -> void:
|
||||
var reset: BaseButton = get_node(node + "/MarginContainer/CenterAlign/MainButton/TabAlign/ButtonReset")
|
||||
var animation: AnimationPlayer = get_node(node + "/AnimationPlayer")
|
||||
if int(level.object_finding()) == 0:
|
||||
_configure_reset_disable(animation, reset, animate)
|
||||
else:
|
||||
_configure_reset_enable(animation, reset, level, node, index)
|
||||
_configure_reset_enable(animation, reset, level, node)
|
||||
|
||||
func _configure_reset_disable(animation, reset, animate = false):
|
||||
func _configure_reset_disable(animation: AnimationPlayer, reset: BaseButton, animate: bool = false) -> void:
|
||||
animation.play("SlideReset")
|
||||
if !animate:
|
||||
if not animate:
|
||||
animation.seek(1, false)
|
||||
|
||||
reset.set_disabled(true)
|
||||
reset.set_default_cursor_shape(CURSOR_ARROW)
|
||||
reset.mouse_default_cursor_shape = CURSOR_ARROW
|
||||
for c in reset.pressed.get_connections():
|
||||
reset.pressed.disconnect(c["callable"])
|
||||
|
||||
func _configure_reset_enable(animation, reset, level, node, index):
|
||||
func _configure_reset_enable(animation: AnimationPlayer, reset: BaseButton, level: LevelEntry, node: String) -> void:
|
||||
animation.play_backwards("SlideReset")
|
||||
reset.set_disabled(false)
|
||||
reset.set_default_cursor_shape(CURSOR_POINTING_HAND)
|
||||
reset.pressed.connect(Event._on_reset_level.bind(level, node, index, self))
|
||||
reset.mouse_default_cursor_shape = CURSOR_POINTING_HAND
|
||||
reset.pressed.connect(Event._on_reset_level.bind(level, node, level.index, self))
|
||||
|
||||
func configure_counter(level, node):
|
||||
var count = get_node(node+"/MarginContainer/CenterAlign/MainButton/TabAlign/ButtonCount/MarginBottom/Label")
|
||||
|
||||
count.set_text(level.object_finding()+" / "+level.object_to_find())
|
||||
func configure_counter(level: LevelEntry, node: String) -> void:
|
||||
var count: Label = get_node(node + "/MarginContainer/CenterAlign/MainButton/TabAlign/ButtonCount/MarginBottom/Label")
|
||||
count.text = level.object_finding() + " / " + level.object_to_find()
|
||||
|
||||
@@ -1,25 +1,22 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://b1np8c74w5sea"]
|
||||
|
||||
[ext_resource type="Script" path="res://scenes/UI/choose_scenes/ChooseScene.gd" id="1"]
|
||||
[ext_resource type="Script" uid="uid://bcfdw1mmwinhn" path="res://scenes/UI/choose_scenes/ChooseScene.gd" id="1"]
|
||||
|
||||
[sub_resource type="StyleBoxEmpty" id="EmptyPanel"]
|
||||
|
||||
[node name="ChooseScene" type="ScrollContainer"]
|
||||
[node name="ChooseScene" type="ScrollContainer" unique_id=1732973661]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
theme_override_styles/panel = SubResource("EmptyPanel")
|
||||
horizontal_scroll_mode = 0
|
||||
vertical_scroll_mode = 0
|
||||
theme_override_styles/panel = SubResource("EmptyPanel")
|
||||
script = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="MarginContainer" type="GridContainer" parent="."]
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 720.0
|
||||
[node name="MarginContainer" type="GridContainer" parent="." unique_id=469264802]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
columns = 3
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://bdv2y5ciy4xpo"]
|
||||
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_base.tres" id="1"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/tab_select/UI-Button-Reset-hover.png" id="2"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/tab_select/UI-Button-Reset-disabled.png" id="3"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/tab_select/UI-Button-Count-hover.png" id="4"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/tab_select/UI-Button-Reset.png" id="5"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/tab_select/UI-Button-Count.png" id="6"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/tab_select/UI-level-btn-shadow.png" id="7"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/tab_select/UI-level-btn-leather.png" id="8"]
|
||||
[ext_resource type="FontVariation" uid="uid://inv1rofq17xy" path="res://assets/fonts/kirsty/kirsty_base.tres" id="1"]
|
||||
[ext_resource type="Texture2D" uid="uid://fi0dokesq6bq" path="res://assets/ui/themes/tab_select/UI-Button-Reset-hover.png" id="2"]
|
||||
[ext_resource type="Texture2D" uid="uid://550rkcq2ihsj" path="res://assets/ui/themes/tab_select/UI-Button-Reset-disabled.png" id="3"]
|
||||
[ext_resource type="Texture2D" uid="uid://bddr54amp71fv" path="res://assets/ui/themes/tab_select/UI-Button-Count-hover.png" id="4"]
|
||||
[ext_resource type="Texture2D" uid="uid://bsrpumg1bhtas" path="res://assets/ui/themes/tab_select/UI-Button-Reset.png" id="5"]
|
||||
[ext_resource type="Texture2D" uid="uid://bs22t34m61as7" path="res://assets/ui/themes/tab_select/UI-Button-Count.png" id="6"]
|
||||
[ext_resource type="Texture2D" uid="uid://dqoumo46armbe" path="res://assets/ui/themes/tab_select/UI-level-btn-shadow.png" id="7"]
|
||||
[ext_resource type="Texture2D" uid="uid://g8iyo0t47j30" path="res://assets/ui/themes/tab_select/UI-level-btn-leather.png" id="8"]
|
||||
|
||||
[sub_resource type="Animation" id="1"]
|
||||
resource_name = "SlideReset"
|
||||
@@ -23,69 +23,67 @@ tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0, 1)
|
||||
}
|
||||
|
||||
[node name="TilePuzzle" type="Control"]
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_oblr1"]
|
||||
_data = {
|
||||
&"SlideReset": SubResource("1")
|
||||
}
|
||||
|
||||
[node name="TilePuzzle" type="Control" unique_id=1136813254]
|
||||
layout_mode = 3
|
||||
anchors_preset = 0
|
||||
offset_left = 320.0
|
||||
offset_right = 1600.0
|
||||
offset_bottom = 720.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="BackgroundTile" type="TextureRect" parent="."]
|
||||
[node name="BackgroundTile" type="TextureRect" parent="." unique_id=1429542932]
|
||||
visible = false
|
||||
layout_mode = 0
|
||||
anchor_left = 0.5
|
||||
anchor_right = 0.5
|
||||
offset_left = -114.0
|
||||
offset_right = 115.0
|
||||
offset_bottom = 456.0
|
||||
texture = ExtResource("7")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
[node name="MarginContainer" type="MarginContainer" parent="." unique_id=509628273]
|
||||
layout_mode = 0
|
||||
anchor_left = 0.5
|
||||
anchor_right = 0.5
|
||||
offset_left = -114.0
|
||||
offset_right = 115.0
|
||||
offset_bottom = 720.0
|
||||
theme_override_constants/margin_right = 10
|
||||
theme_override_constants/margin_top = 10
|
||||
theme_override_constants/margin_left = 10
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
theme_override_constants/margin_top = 10
|
||||
theme_override_constants/margin_right = 10
|
||||
|
||||
[node name="CenterAlign" type="VBoxContainer" parent="MarginContainer"]
|
||||
offset_left = 10.0
|
||||
offset_top = 10.0
|
||||
offset_right = 219.0
|
||||
offset_bottom = 720.0
|
||||
[node name="CenterAlign" type="VBoxContainer" parent="MarginContainer" unique_id=314766412]
|
||||
layout_mode = 2
|
||||
theme_override_constants/separation = 0
|
||||
|
||||
[node name="MainButton" type="TextureButton" parent="MarginContainer/CenterAlign"]
|
||||
offset_right = 209.0
|
||||
offset_bottom = 208.0
|
||||
[node name="MainButton" type="TextureButton" parent="MarginContainer/CenterAlign" unique_id=1876585747]
|
||||
layout_mode = 2
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("8")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="MarginStich" type="MarginContainer" parent="MarginContainer/CenterAlign/MainButton"]
|
||||
[node name="MarginStich" type="MarginContainer" parent="MarginContainer/CenterAlign/MainButton" unique_id=2061086300]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
theme_override_constants/margin_right = 5
|
||||
theme_override_constants/margin_top = 5
|
||||
theme_override_constants/margin_left = 5
|
||||
theme_override_constants/margin_top = 5
|
||||
theme_override_constants/margin_right = 5
|
||||
theme_override_constants/margin_bottom = 5
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="ThumbnailLevel" type="TextureRect" parent="MarginContainer/CenterAlign/MainButton/MarginStich"]
|
||||
[node name="ThumbnailLevel" type="TextureRect" parent="MarginContainer/CenterAlign/MainButton/MarginStich" unique_id=1401509555]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
expand_mode = 1
|
||||
|
||||
[node name="ThumbnailLevel" type="TextureRect" parent="MarginContainer/CenterAlign/MainButton" unique_id=330142441]
|
||||
layout_mode = 0
|
||||
offset_left = 5.0
|
||||
offset_top = 5.0
|
||||
offset_right = 204.0
|
||||
@@ -93,74 +91,47 @@ offset_bottom = 203.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
expand_mode = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="ThumbnailLevel" type="TextureRect" parent="MarginContainer/CenterAlign/MainButton"]
|
||||
offset_left = 5.0
|
||||
offset_top = 5.0
|
||||
offset_right = 204.0
|
||||
offset_bottom = 203.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
expand_mode = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TabAlign" type="HBoxContainer" parent="MarginContainer/CenterAlign/MainButton"]
|
||||
[node name="TabAlign" type="HBoxContainer" parent="MarginContainer/CenterAlign/MainButton" unique_id=820994914]
|
||||
show_behind_parent = true
|
||||
layout_mode = 0
|
||||
offset_top = 208.0
|
||||
offset_right = 209.0
|
||||
offset_bottom = 710.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="ButtonReset" type="TextureButton" parent="MarginContainer/CenterAlign/MainButton/TabAlign"]
|
||||
[node name="ButtonReset" type="TextureButton" parent="MarginContainer/CenterAlign/MainButton/TabAlign" unique_id=42918781]
|
||||
show_behind_parent = true
|
||||
offset_left = 1.0
|
||||
offset_right = 90.0
|
||||
offset_bottom = 57.0
|
||||
layout_mode = 2
|
||||
size_flags_vertical = 0
|
||||
texture_normal = ExtResource("5")
|
||||
texture_hover = ExtResource("2")
|
||||
texture_disabled = ExtResource("3")
|
||||
|
||||
[node name="ButtonCount" type="TextureButton" parent="MarginContainer/CenterAlign/MainButton/TabAlign"]
|
||||
offset_left = 94.0
|
||||
offset_right = 207.0
|
||||
offset_bottom = 57.0
|
||||
mouse_default_cursor_shape = 2
|
||||
[node name="ButtonCount" type="TextureButton" parent="MarginContainer/CenterAlign/MainButton/TabAlign" unique_id=192493579]
|
||||
layout_mode = 2
|
||||
size_flags_vertical = 0
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("6")
|
||||
texture_hover = ExtResource("4")
|
||||
texture_focused = ExtResource("4")
|
||||
|
||||
[node name="MarginBottom" type="MarginContainer" parent="MarginContainer/CenterAlign/MainButton/TabAlign/ButtonCount"]
|
||||
[node name="MarginBottom" type="MarginContainer" parent="MarginContainer/CenterAlign/MainButton/TabAlign/ButtonCount" unique_id=944673833]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
theme_override_constants/margin_bottom = 10
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="MarginContainer/CenterAlign/MainButton/TabAlign/ButtonCount/MarginBottom"]
|
||||
offset_right = 113.0
|
||||
offset_bottom = 47.0
|
||||
[node name="Label" type="Label" parent="MarginContainer/CenterAlign/MainButton/TabAlign/ButtonCount/MarginBottom" unique_id=1766311049]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 7
|
||||
theme_override_fonts/font = ExtResource("1")
|
||||
text = "X / 10"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
anims/SlideReset = SubResource("1")
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="." unique_id=922689445]
|
||||
libraries/ = SubResource("AnimationLibrary_oblr1")
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
extends CenterContainer
|
||||
|
||||
func _ready():
|
||||
print("[ending_#ready]")
|
||||
func _ready() -> void:
|
||||
$AudioStreamPlayer.play()
|
||||
|
||||
func _on_Timer_timeout():
|
||||
print("[ending#_on_Timer_timeout]")
|
||||
func _on_Timer_timeout() -> void:
|
||||
Global.goto_scene("res://scenes/Main.tscn")
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://c8sg2clnv7eld"]
|
||||
|
||||
[ext_resource type="Script" path="res://scenes/UI/ending/Ending.gd" id="1"]
|
||||
[ext_resource type="AudioStream" path="res://assets/sounds/victory.ogg" id="2"]
|
||||
[ext_resource type="FontFile" path="res://assets/fonts/MKX Title.ttf" id="3"]
|
||||
[ext_resource type="Script" uid="uid://cqqhb0tct4m01" path="res://scenes/UI/ending/Ending.gd" id="1"]
|
||||
[ext_resource type="AudioStream" uid="uid://b76kuq712ix8k" path="res://assets/sounds/victory.ogg" id="2"]
|
||||
[ext_resource type="FontFile" uid="uid://c7ps8q01ej5du" path="res://assets/fonts/MKX Title.ttf" id="3"]
|
||||
|
||||
[sub_resource type="FontFile" id="1"]
|
||||
fallbacks = Array[Font]([ExtResource("3")])
|
||||
@@ -21,42 +21,32 @@ cache/0/16/0/underline_position = 0.0
|
||||
cache/0/16/0/underline_thickness = 0.0
|
||||
cache/0/16/0/scale = 1.0
|
||||
|
||||
[node name="CenterContainer" type="CenterContainer"]
|
||||
[node name="CenterContainer" type="CenterContainer" unique_id=2065892859]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
script = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="ColorRect" type="ColorRect" parent="."]
|
||||
offset_left = 640.0
|
||||
offset_top = 360.0
|
||||
offset_right = 640.0
|
||||
offset_bottom = 360.0
|
||||
grow_horizontal = 0
|
||||
grow_vertical = 0
|
||||
[node name="ColorRect" type="ColorRect" parent="." unique_id=1128227116]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
color = Color(0, 0, 0, 1)
|
||||
|
||||
[node name="Timer" type="Timer" parent="."]
|
||||
[node name="Timer" type="Timer" parent="." unique_id=1372711213]
|
||||
wait_time = 4.31
|
||||
autostart = true
|
||||
|
||||
[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="."]
|
||||
[node name="AudioStreamPlayer" type="AudioStreamPlayer" parent="." unique_id=780977400]
|
||||
stream = ExtResource("2")
|
||||
volume_db = -29.411
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
offset_left = 477.0
|
||||
offset_top = 275.0
|
||||
offset_right = 802.0
|
||||
offset_bottom = 444.0
|
||||
theme_override_fonts/font = SubResource("1")
|
||||
[node name="Label" type="Label" parent="." unique_id=1880017385]
|
||||
layout_mode = 2
|
||||
theme_override_colors/font_color = Color(1, 1, 1, 1)
|
||||
theme_override_fonts/font = SubResource("1")
|
||||
text = "aHog !!!
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
extends Control
|
||||
|
||||
func _ready():
|
||||
func _ready() -> void:
|
||||
get_node("LabelLoading").text = tr("LOADING")
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://cyxlaf1u2nhjn"]
|
||||
|
||||
[ext_resource type="PackedScene" path="res://scenes/UI/loading/parts/LoadingBare.tscn" id="1"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/UI/loading/parts/TopPart.tscn" id="2"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/UI/background/Background.tscn" id="3"]
|
||||
[ext_resource type="PackedScene" uid="uid://t4bee0w11cj2" path="res://scenes/UI/loading/parts/LoadingBare.tscn" id="1"]
|
||||
[ext_resource type="PackedScene" uid="uid://dxvg52gd5h1kh" path="res://scenes/UI/loading/parts/TopPart.tscn" id="2"]
|
||||
[ext_resource type="PackedScene" uid="uid://edbpygl0vh8c" path="res://scenes/UI/background/Background.tscn" id="3"]
|
||||
|
||||
[sub_resource type="Animation" id="1"]
|
||||
resource_name = "BorderAnim"
|
||||
@@ -29,26 +29,40 @@ tracks/1/keys = {
|
||||
"times": PackedFloat32Array(0, 0.4)
|
||||
}
|
||||
|
||||
[node name="Control" type="Control"]
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_ygatp"]
|
||||
_data = {
|
||||
&"BorderAnim": SubResource("1")
|
||||
}
|
||||
|
||||
[node name="BackgroundPicture" parent="." instance=ExtResource("3")]
|
||||
layout_mode = 1
|
||||
[node name="Control" type="Control" unique_id=1398968538]
|
||||
layout_mode = 3
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
|
||||
[node name="LoadingTopBorder" parent="." instance=ExtResource("2")]
|
||||
[node name="BackgroundPicture" parent="." unique_id=2027281585 instance=ExtResource("3")]
|
||||
layout_mode = 1
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
|
||||
[node name="LoadingTopBorder" parent="." unique_id=218348086 instance=ExtResource("2")]
|
||||
layout_mode = 0
|
||||
anchors_preset = 0
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
offset_top = 0.362091
|
||||
offset_bottom = 0.362061
|
||||
grow_vertical = 1
|
||||
|
||||
[node name="LoadingBare" parent="." instance=ExtResource("1")]
|
||||
[node name="LoadingBare" parent="." unique_id=1550577651 instance=ExtResource("1")]
|
||||
layout_mode = 0
|
||||
anchors_preset = 0
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
offset_top = 360.0
|
||||
|
||||
[node name="AnimLoading" type="AnimationPlayer" parent="."]
|
||||
method_call_mode = 1
|
||||
anims/BorderAnim = SubResource("1")
|
||||
[node name="AnimLoading" type="AnimationPlayer" parent="." unique_id=1450388645]
|
||||
callback_mode_method = 1
|
||||
libraries/ = SubResource("AnimationLibrary_ygatp")
|
||||
|
||||
@@ -1,28 +1,24 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://c8wq3txgsbayx"]
|
||||
|
||||
[node name="Tile" type="VBoxContainer"]
|
||||
[node name="Tile" type="VBoxContainer" unique_id=689859814]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
size_flags_horizontal = 3
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="."]
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 237.0
|
||||
[node name="MarginContainer" type="MarginContainer" parent="." unique_id=2052541719]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="BorderLeft" type="ColorRect" parent="."]
|
||||
offset_top = 241.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 478.0
|
||||
[node name="BorderLeft" type="ColorRect" parent="." unique_id=1201756514]
|
||||
custom_minimum_size = Vector2(0, 8)
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
color = Color(0.74902, 0.701961, 0.65098, 1)
|
||||
|
||||
[node name="MarginContainer2" type="MarginContainer" parent="."]
|
||||
offset_top = 482.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 720.0
|
||||
[node name="MarginContainer2" type="MarginContainer" parent="." unique_id=31910865]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://ct7qxiscklbm8"]
|
||||
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_title.tres" id="1"]
|
||||
[ext_resource type="Script" path="res://scenes/UI/loading/Loading.gd" id="2"]
|
||||
[ext_resource type="FontVariation" uid="uid://bqx3uv23bwjul" path="res://assets/fonts/kirsty/kirsty_title.tres" id="1"]
|
||||
[ext_resource type="Script" uid="uid://dsma7tpjx5f65" path="res://scenes/UI/loading/Loading.gd" id="2"]
|
||||
|
||||
[node name="VBoxLoading" type="VBoxContainer"]
|
||||
[node name="VBoxLoading" type="VBoxContainer" unique_id=854342834]
|
||||
anchors_preset = 8
|
||||
anchor_left = 0.5
|
||||
anchor_top = 0.5
|
||||
anchor_right = 0.5
|
||||
@@ -17,16 +18,12 @@ size_flags_vertical = 0
|
||||
theme_override_constants/separation = 0
|
||||
alignment = 1
|
||||
script = ExtResource("2")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="LabelLoading" type="Label" parent="."]
|
||||
offset_right = 193.0
|
||||
offset_bottom = 56.0
|
||||
[node name="LabelLoading" type="Label" parent="." unique_id=673745546]
|
||||
layout_mode = 2
|
||||
theme_override_colors/font_color = Color(0.74902, 0.701961, 0.65098, 1)
|
||||
theme_override_fonts/font = ExtResource("1")
|
||||
theme_override_font_sizes/font_size = 46
|
||||
theme_override_colors/font_color = Color(0.74902, 0.701961, 0.65098, 1)
|
||||
text = "loading"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 2
|
||||
|
||||
@@ -1,44 +1,37 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://t4bee0w11cj2"]
|
||||
|
||||
[ext_resource type="Theme" path="res://assets/ui/themes/leather.theme" id="1"]
|
||||
|
||||
[node name="LoadingBare" type="Control"]
|
||||
[node name="LoadingBare" type="Control" unique_id=1614726848]
|
||||
layout_mode = 3
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="."]
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="." unique_id=1258548453]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="VBoxContainer"]
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 237.0
|
||||
[node name="MarginContainer" type="MarginContainer" parent="VBoxContainer" unique_id=144824491]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer"]
|
||||
offset_top = 241.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 478.0
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer" unique_id=1257929124]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="HSplitContainer" type="HSplitContainer" parent="VBoxContainer/HBoxContainer"]
|
||||
offset_right = 238.0
|
||||
offset_bottom = 237.0
|
||||
[node name="HSplitContainer" type="HSplitContainer" parent="VBoxContainer/HBoxContainer" unique_id=1650805636]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_stretch_ratio = 0.3
|
||||
|
||||
[node name="ProgressBar" type="ProgressBar" parent="VBoxContainer/HBoxContainer"]
|
||||
offset_left = 242.0
|
||||
offset_right = 1037.0
|
||||
offset_bottom = 237.0
|
||||
[node name="ProgressBar" type="ProgressBar" parent="VBoxContainer/HBoxContainer" unique_id=2054750986]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
theme = ExtResource("1")
|
||||
@@ -46,16 +39,12 @@ max_value = 1.0
|
||||
step = 0.1
|
||||
rounded = true
|
||||
|
||||
[node name="HSplitContainer2" type="HSplitContainer" parent="VBoxContainer/HBoxContainer"]
|
||||
offset_left = 1041.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 237.0
|
||||
[node name="HSplitContainer2" type="HSplitContainer" parent="VBoxContainer/HBoxContainer" unique_id=462638225]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_stretch_ratio = 0.3
|
||||
|
||||
[node name="MarginContainer2" type="MarginContainer" parent="VBoxContainer"]
|
||||
offset_top = 482.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 720.0
|
||||
[node name="MarginContainer2" type="MarginContainer" parent="VBoxContainer" unique_id=371664312]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
|
||||
@@ -1,87 +1,61 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://dxvg52gd5h1kh"]
|
||||
|
||||
[ext_resource type="PackedScene" path="res://scenes/UI/loading/parts/LabelLoading.tscn" id="1"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/UI/loading/parts/BorderColor.tscn" id="2"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/bck-hrz-grd.png" id="3"]
|
||||
[ext_resource type="PackedScene" uid="uid://ct7qxiscklbm8" path="res://scenes/UI/loading/parts/LabelLoading.tscn" id="1"]
|
||||
[ext_resource type="PackedScene" uid="uid://c8wq3txgsbayx" path="res://scenes/UI/loading/parts/BorderColor.tscn" id="2"]
|
||||
[ext_resource type="Texture2D" uid="uid://c0ddrujen604n" path="res://assets/ui/themes/bck-hrz-grd.png" id="3"]
|
||||
|
||||
[node name="LoadingBorder" type="Control"]
|
||||
[node name="LoadingBorder" type="Control" unique_id=167487990]
|
||||
clip_contents = true
|
||||
layout_mode = 3
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
clip_contents = true
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="BackgroundGradient" type="VBoxContainer" parent="."]
|
||||
[node name="BackgroundGradient" type="VBoxContainer" parent="." unique_id=1476252897]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
theme_override_constants/separation = 0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="BlackColor" type="ColorRect" parent="BackgroundGradient"]
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 240.0
|
||||
[node name="BlackColor" type="ColorRect" parent="BackgroundGradient" unique_id=1692081529]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
color = Color(0, 0, 0, 1)
|
||||
|
||||
[node name="ColorRect" type="TextureRect" parent="BackgroundGradient"]
|
||||
offset_top = 240.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 480.0
|
||||
[node name="ColorRect" type="TextureRect" parent="BackgroundGradient" unique_id=1221457874]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
texture = ExtResource("3")
|
||||
expand_mode = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="BackgroundGradient"]
|
||||
offset_top = 480.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 720.0
|
||||
[node name="MarginContainer" type="MarginContainer" parent="BackgroundGradient" unique_id=658862845]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="LabelAndBorder" type="HBoxContainer" parent="."]
|
||||
[node name="LabelAndBorder" type="HBoxContainer" parent="." unique_id=1120691617]
|
||||
clip_contents = true
|
||||
layout_mode = 0
|
||||
anchor_top = 0.5
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 0.5
|
||||
offset_top = -30.0
|
||||
offset_bottom = 30.0
|
||||
clip_contents = true
|
||||
size_flags_vertical = 5
|
||||
theme_override_constants/separation = 20
|
||||
alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="BorderLeft" parent="LabelAndBorder" instance=ExtResource("2")]
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
offset_right = 523.0
|
||||
offset_bottom = 60.0
|
||||
[node name="BorderLeft" parent="LabelAndBorder" unique_id=492130723 instance=ExtResource("2")]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="LabelLoading" parent="LabelAndBorder" instance=ExtResource("1")]
|
||||
anchor_left = 0.0
|
||||
anchor_top = 0.0
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
offset_left = 543.0
|
||||
offset_top = 0.0
|
||||
offset_right = 736.0
|
||||
offset_bottom = 56.0
|
||||
[node name="LabelLoading" parent="LabelAndBorder" unique_id=1883632327 instance=ExtResource("1")]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="BorderRight" parent="LabelAndBorder" instance=ExtResource("2")]
|
||||
anchor_right = 0.0
|
||||
anchor_bottom = 0.0
|
||||
offset_left = 756.0
|
||||
offset_right = 1280.0
|
||||
offset_bottom = 60.0
|
||||
[node name="BorderRight" parent="LabelAndBorder" unique_id=1411830674 instance=ExtResource("2")]
|
||||
layout_mode = 2
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
extends Node
|
||||
|
||||
func _ready():
|
||||
func _ready() -> void:
|
||||
_apply_translation()
|
||||
_apply_settings_language()
|
||||
_apply_settings_gyroscope()
|
||||
@@ -9,50 +9,46 @@ func _ready():
|
||||
_apply_settings_fullscreen()
|
||||
|
||||
## PRIVATE
|
||||
func _apply_translation():
|
||||
func _apply_translation() -> void:
|
||||
$VBoxContainer/langue/VBoxContainer/Label.text = tr("SETTINGS_LABEL_LANGUE")
|
||||
$VBoxContainer/gyroscope/HBoxContainer/Label.text = tr("SETTINGS_LABEL_GYROSCOPE")
|
||||
|
||||
func _apply_settings_language():
|
||||
var data = $VBoxContainer/langue/VBoxContainer/data
|
||||
|
||||
func _apply_settings_language() -> void:
|
||||
var data: ItemList = $VBoxContainer/langue/VBoxContainer/data
|
||||
data.add_item("English", load("res://assets/ui/flags/english.png"), true) # id : 0
|
||||
data.add_item("Français", load("res://assets/ui/flags/french.png"), true) # id : 1
|
||||
|
||||
data.select(Setting.get_setting_language())
|
||||
|
||||
func _apply_settings_gyroscope():
|
||||
func _apply_settings_gyroscope() -> void:
|
||||
$VBoxContainer/gyroscope/HBoxContainer/data.button_pressed = Setting.get_setting_gyrosocpe()
|
||||
|
||||
func _apply_settings_sound_ambient():
|
||||
func _apply_settings_sound_ambient() -> void:
|
||||
$VBoxContainer/ambient_sound/HBoxContainer/data.button_pressed = Setting.get_setting_ambient_sound()
|
||||
|
||||
func _apply_settings_resolution():
|
||||
var data = $VBoxContainer/resolution/VBoxContainer/data
|
||||
|
||||
data.add_item("2560 x 1440", null, true) # id : 0
|
||||
data.add_item("1920 x 1080", null, true) # id : 1
|
||||
data.add_item("1280 x 720", null, true) # id : 2
|
||||
data.add_item("854 x 576", null, true) # id : 3
|
||||
|
||||
func _apply_settings_resolution() -> void:
|
||||
var data: ItemList = $VBoxContainer/resolution/VBoxContainer/data
|
||||
data.add_item("2560 x 1440", null, true)
|
||||
data.add_item("1920 x 1080", null, true)
|
||||
data.add_item("1280 x 720", null, true)
|
||||
data.add_item("854 x 576", null, true)
|
||||
for index in range(4):
|
||||
if data.get_item_text(index).split(' x ') == Setting.get_setting_resolution():
|
||||
if data.get_item_text(index).split(" x ") == Setting.get_setting_resolution():
|
||||
data.select(index)
|
||||
|
||||
func _apply_settings_fullscreen():
|
||||
func _apply_settings_fullscreen() -> void:
|
||||
$VBoxContainer/fullscreen/HBoxContainer/data.button_pressed = Setting.get_setting_fullscreen()
|
||||
|
||||
func _on_gyroscope_pressed():
|
||||
Setting.set_setting_gyroscope(int($VBoxContainer/gyroscope/HBoxContainer/data.button_pressed))
|
||||
func _on_gyroscope_pressed() -> void:
|
||||
Setting.set_setting_gyroscope($VBoxContainer/gyroscope/HBoxContainer/data.button_pressed)
|
||||
|
||||
func _on_ambient_sound_pressed():
|
||||
Setting.set_setting_ambient_sound(int($VBoxContainer/ambient_sound/HBoxContainer/data.button_pressed))
|
||||
func _on_ambient_sound_pressed() -> void:
|
||||
Setting.set_setting_ambient_sound($VBoxContainer/ambient_sound/HBoxContainer/data.button_pressed)
|
||||
|
||||
func _on_langue_item_selected(index):
|
||||
func _on_langue_item_selected(index: int) -> void:
|
||||
Setting.set_setting_language(index)
|
||||
|
||||
func _on_resolution_item_selected(index):
|
||||
func _on_resolution_item_selected(index: int) -> void:
|
||||
Setting.set_setting_resolution($VBoxContainer/resolution/VBoxContainer/data.get_item_text(index))
|
||||
|
||||
func _on_fullscreen_item_selected():
|
||||
Setting.set_setting_fullscreen(int($VBoxContainer/fullscreen/HBoxContainer/data.button_pressed))
|
||||
func _on_fullscreen_item_selected() -> void:
|
||||
Setting.set_setting_fullscreen($VBoxContainer/fullscreen/HBoxContainer/data.button_pressed)
|
||||
|
||||
@@ -1,145 +1,97 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://ccc65743enkt6"]
|
||||
|
||||
[ext_resource type="Script" path="res://scenes/UI/settings/Settings.gd" id="1"]
|
||||
[ext_resource type="Script" uid="uid://4r5k5evs8p4" path="res://scenes/UI/settings/Settings.gd" id="1"]
|
||||
|
||||
[node name="Settings" type="CenterContainer"]
|
||||
[node name="Settings" type="CenterContainer" unique_id=699546480]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = -1.12244
|
||||
offset_right = -1.12244
|
||||
script = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="."]
|
||||
offset_left = 547.0
|
||||
offset_top = 265.0
|
||||
offset_right = 732.0
|
||||
offset_bottom = 455.0
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="." unique_id=302387473]
|
||||
layout_mode = 2
|
||||
alignment = 1
|
||||
|
||||
[node name="langue" type="CenterContainer" parent="VBoxContainer"]
|
||||
offset_right = 185.0
|
||||
offset_bottom = 27.0
|
||||
[node name="langue" type="CenterContainer" parent="VBoxContainer" unique_id=282359486]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="VBoxContainer/langue"]
|
||||
offset_left = 67.0
|
||||
offset_right = 117.0
|
||||
offset_bottom = 27.0
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="VBoxContainer/langue" unique_id=1667789483]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" type="Label" parent="VBoxContainer/langue/VBoxContainer"]
|
||||
offset_right = 50.0
|
||||
offset_bottom = 14.0
|
||||
[node name="Label" type="Label" parent="VBoxContainer/langue/VBoxContainer" unique_id=1488070578]
|
||||
layout_mode = 2
|
||||
text = "langue :"
|
||||
horizontal_alignment = 1
|
||||
|
||||
[node name="data" type="ItemList" parent="VBoxContainer/langue/VBoxContainer"]
|
||||
offset_top = 18.0
|
||||
offset_right = 50.0
|
||||
offset_bottom = 27.0
|
||||
[node name="data" type="ItemList" parent="VBoxContainer/langue/VBoxContainer" unique_id=1488206371]
|
||||
layout_mode = 2
|
||||
focus_mode = 0
|
||||
auto_height = true
|
||||
max_columns = 2
|
||||
same_column_width = true
|
||||
fixed_icon_size = Vector2(32, 32)
|
||||
fixed_icon_size = Vector2i(32, 32)
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/langue"]
|
||||
offset_left = 92.0
|
||||
offset_top = 13.0
|
||||
offset_right = 92.0
|
||||
offset_bottom = 13.0
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/langue" unique_id=1459762193]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="gyroscope" type="CenterContainer" parent="VBoxContainer"]
|
||||
offset_top = 31.0
|
||||
offset_right = 185.0
|
||||
offset_bottom = 71.0
|
||||
[node name="gyroscope" type="CenterContainer" parent="VBoxContainer" unique_id=1525036037]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/gyroscope"]
|
||||
offset_left = 16.0
|
||||
offset_right = 169.0
|
||||
offset_bottom = 40.0
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/gyroscope" unique_id=1912659566]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" type="Label" parent="VBoxContainer/gyroscope/HBoxContainer"]
|
||||
offset_top = 13.0
|
||||
offset_right = 73.0
|
||||
offset_bottom = 27.0
|
||||
[node name="Label" type="Label" parent="VBoxContainer/gyroscope/HBoxContainer" unique_id=1359372643]
|
||||
layout_mode = 2
|
||||
text = "gyroscope :"
|
||||
|
||||
[node name="data" type="CheckButton" parent="VBoxContainer/gyroscope/HBoxContainer"]
|
||||
offset_left = 77.0
|
||||
offset_right = 153.0
|
||||
offset_bottom = 40.0
|
||||
horizontal_alignment = 1
|
||||
[node name="data" type="CheckButton" parent="VBoxContainer/gyroscope/HBoxContainer" unique_id=1589233703]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="ambient_sound" type="CenterContainer" parent="VBoxContainer"]
|
||||
offset_top = 75.0
|
||||
offset_right = 185.0
|
||||
offset_bottom = 115.0
|
||||
[node name="ambient_sound" type="CenterContainer" parent="VBoxContainer" unique_id=633296278]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/ambient_sound"]
|
||||
offset_right = 185.0
|
||||
offset_bottom = 40.0
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/ambient_sound" unique_id=1092892428]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" type="Label" parent="VBoxContainer/ambient_sound/HBoxContainer"]
|
||||
offset_top = 13.0
|
||||
offset_right = 105.0
|
||||
offset_bottom = 27.0
|
||||
[node name="Label" type="Label" parent="VBoxContainer/ambient_sound/HBoxContainer" unique_id=488463942]
|
||||
layout_mode = 2
|
||||
text = "Ambiant sound :"
|
||||
|
||||
[node name="data" type="CheckButton" parent="VBoxContainer/ambient_sound/HBoxContainer"]
|
||||
offset_left = 109.0
|
||||
offset_right = 185.0
|
||||
offset_bottom = 40.0
|
||||
[node name="data" type="CheckButton" parent="VBoxContainer/ambient_sound/HBoxContainer" unique_id=273527408]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="resolution" type="CenterContainer" parent="VBoxContainer"]
|
||||
offset_top = 119.0
|
||||
offset_right = 185.0
|
||||
offset_bottom = 146.0
|
||||
[node name="resolution" type="CenterContainer" parent="VBoxContainer" unique_id=1502344262]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="VBoxContainer/resolution"]
|
||||
offset_left = 54.0
|
||||
offset_right = 130.0
|
||||
offset_bottom = 27.0
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="VBoxContainer/resolution" unique_id=2142236831]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" type="Label" parent="VBoxContainer/resolution/VBoxContainer"]
|
||||
offset_right = 76.0
|
||||
offset_bottom = 14.0
|
||||
[node name="Label" type="Label" parent="VBoxContainer/resolution/VBoxContainer" unique_id=1803587554]
|
||||
layout_mode = 2
|
||||
text = "Resolution :"
|
||||
|
||||
[node name="data" type="ItemList" parent="VBoxContainer/resolution/VBoxContainer"]
|
||||
offset_top = 18.0
|
||||
offset_right = 76.0
|
||||
offset_bottom = 27.0
|
||||
focus_mode = 0
|
||||
[node name="data" type="ItemList" parent="VBoxContainer/resolution/VBoxContainer" unique_id=2020766411]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
focus_mode = 0
|
||||
auto_height = true
|
||||
same_column_width = true
|
||||
|
||||
[node name="fullscreen" type="CenterContainer" parent="VBoxContainer"]
|
||||
offset_top = 150.0
|
||||
offset_right = 185.0
|
||||
offset_bottom = 190.0
|
||||
[node name="fullscreen" type="CenterContainer" parent="VBoxContainer" unique_id=1761837864]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/fullscreen"]
|
||||
offset_left = 15.0
|
||||
offset_right = 169.0
|
||||
offset_bottom = 40.0
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="VBoxContainer/fullscreen" unique_id=1642161546]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="Label" type="Label" parent="VBoxContainer/fullscreen/HBoxContainer"]
|
||||
offset_top = 13.0
|
||||
offset_right = 74.0
|
||||
offset_bottom = 27.0
|
||||
[node name="Label" type="Label" parent="VBoxContainer/fullscreen/HBoxContainer" unique_id=89060107]
|
||||
layout_mode = 2
|
||||
text = "Fullscreen :"
|
||||
|
||||
[node name="data" type="CheckButton" parent="VBoxContainer/fullscreen/HBoxContainer"]
|
||||
offset_left = 78.0
|
||||
offset_right = 154.0
|
||||
offset_bottom = 40.0
|
||||
[node name="data" type="CheckButton" parent="VBoxContainer/fullscreen/HBoxContainer" unique_id=741966003]
|
||||
layout_mode = 2
|
||||
|
||||
[connection signal="item_selected" from="VBoxContainer/langue/VBoxContainer/data" to="." method="_on_langue_item_selected"]
|
||||
[connection signal="pressed" from="VBoxContainer/gyroscope/HBoxContainer/data" to="." method="_on_gyroscope_pressed"]
|
||||
|
||||
+63
-117
@@ -1,232 +1,178 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://bjrsudbbriijh"]
|
||||
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/button-summary-hover.jpg" id="1"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/button-summary.jpg" id="2"]
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_base.tres" id="3"]
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_title.tres" id="4"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/icones/treasure.png" id="5"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/icones/treasure-hover.png" id="7"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/bck-vert-grd.png" id="8"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/wood-tile.jpg" id="9"]
|
||||
[ext_resource type="Texture2D" uid="uid://b6d68t2cpf8hs" path="res://assets/ui/themes/button-summary-hover.jpg" id="1"]
|
||||
[ext_resource type="Texture2D" uid="uid://bhow02gjk6svj" path="res://assets/ui/themes/button-summary.jpg" id="2"]
|
||||
[ext_resource type="FontVariation" uid="uid://inv1rofq17xy" path="res://assets/fonts/kirsty/kirsty_base.tres" id="3"]
|
||||
[ext_resource type="FontVariation" uid="uid://bqx3uv23bwjul" path="res://assets/fonts/kirsty/kirsty_title.tres" id="4"]
|
||||
[ext_resource type="Texture2D" uid="uid://bydkxwkmepqg3" path="res://assets/ui/icones/treasure.png" id="5"]
|
||||
[ext_resource type="Texture2D" uid="uid://cr77dbagn5xvr" path="res://assets/ui/icones/treasure-hover.png" id="7"]
|
||||
[ext_resource type="Texture2D" uid="uid://dp0r6com08d1g" path="res://assets/ui/themes/bck-vert-grd.png" id="8"]
|
||||
|
||||
[node name="Summary" type="HBoxContainer"]
|
||||
[node name="Summary" type="HBoxContainer" unique_id=1162717370]
|
||||
anchors_preset = 9
|
||||
anchor_bottom = 1.0
|
||||
offset_right = 236.0
|
||||
theme_override_constants/separation = 0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="PanelWood" type="Panel" parent="."]
|
||||
offset_right = 350.0
|
||||
offset_bottom = 1080.0
|
||||
[node name="PanelWood" type="Panel" parent="." unique_id=1864179308]
|
||||
custom_minimum_size = Vector2(350, 0)
|
||||
layout_mode = 2
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="PanelWood"]
|
||||
[node name="VBoxContainer" type="VBoxContainer" parent="PanelWood" unique_id=1602451066]
|
||||
clip_contents = true
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
clip_contents = true
|
||||
size_flags_horizontal = 8
|
||||
size_flags_vertical = 11
|
||||
theme_override_constants/separation = 30
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="CenterContainer" type="CenterContainer" parent="PanelWood/VBoxContainer"]
|
||||
offset_right = 350.0
|
||||
offset_bottom = 271.0
|
||||
[node name="CenterContainer" type="CenterContainer" parent="PanelWood/VBoxContainer" unique_id=279647120]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="TextureRect" type="TextureButton" parent="PanelWood/VBoxContainer/CenterContainer"]
|
||||
offset_left = 111.0
|
||||
offset_top = 71.0
|
||||
offset_right = 239.0
|
||||
offset_bottom = 199.0
|
||||
mouse_default_cursor_shape = 2
|
||||
[node name="TextureRect" type="TextureButton" parent="PanelWood/VBoxContainer/CenterContainer" unique_id=996591666]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 4
|
||||
size_flags_vertical = 4
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("5")
|
||||
texture_hover = ExtResource("7")
|
||||
texture_focused = ExtResource("7")
|
||||
stretch_mode = 3
|
||||
|
||||
[node name="ButtonPuzzle" type="TextureButton" parent="PanelWood/VBoxContainer"]
|
||||
offset_top = 301.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 378.0
|
||||
mouse_default_cursor_shape = 2
|
||||
[node name="ButtonPuzzle" type="TextureButton" parent="PanelWood/VBoxContainer" unique_id=56901804]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 0
|
||||
size_flags_vertical = 0
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("2")
|
||||
texture_hover = ExtResource("1")
|
||||
texture_focused = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonPuzzle"]
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonPuzzle" unique_id=1120215443]
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_left = 0.0
|
||||
offset_top = 0.0
|
||||
offset_right = 0.0
|
||||
offset_bottom = 0.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
theme_override_fonts/font = ExtResource("4")
|
||||
theme_override_font_sizes/font_size = 46
|
||||
text = "Puzzles"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
|
||||
[node name="ButtonSetting" type="TextureButton" parent="PanelWood/VBoxContainer"]
|
||||
offset_top = 408.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 485.0
|
||||
mouse_default_cursor_shape = 2
|
||||
[node name="ButtonSetting" type="TextureButton" parent="PanelWood/VBoxContainer" unique_id=2122755671]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 0
|
||||
size_flags_vertical = 0
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("2")
|
||||
texture_hover = ExtResource("1")
|
||||
texture_focused = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonSetting"]
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonSetting" unique_id=628254543]
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
size_flags_horizontal = 7
|
||||
size_flags_vertical = 3
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
theme_override_fonts/font = ExtResource("4")
|
||||
theme_override_font_sizes/font_size = 46
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Paramètres"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false,
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="ButtonCredits" type="TextureButton" parent="PanelWood/VBoxContainer"]
|
||||
offset_top = 515.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 592.0
|
||||
mouse_default_cursor_shape = 2
|
||||
[node name="ButtonCredits" type="TextureButton" parent="PanelWood/VBoxContainer" unique_id=679378055]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 0
|
||||
size_flags_vertical = 0
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("2")
|
||||
texture_hover = ExtResource("1")
|
||||
texture_focused = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonCredits"]
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonCredits" unique_id=226913021]
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
size_flags_horizontal = 7
|
||||
size_flags_vertical = 3
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
theme_override_fonts/font = ExtResource("4")
|
||||
theme_override_font_sizes/font_size = 46
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Crédits"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false,
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="MarginContainer" type="MarginContainer" parent="PanelWood/VBoxContainer"]
|
||||
offset_top = 622.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 893.0
|
||||
[node name="MarginContainer" type="MarginContainer" parent="PanelWood/VBoxContainer" unique_id=1157747201]
|
||||
layout_mode = 2
|
||||
size_flags_vertical = 3
|
||||
|
||||
[node name="ButtonQuit" type="TextureButton" parent="PanelWood/VBoxContainer"]
|
||||
offset_top = 923.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 1000.0
|
||||
mouse_default_cursor_shape = 2
|
||||
[node name="ButtonQuit" type="TextureButton" parent="PanelWood/VBoxContainer" unique_id=487898453]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 0
|
||||
size_flags_vertical = 0
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("2")
|
||||
texture_hover = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonQuit"]
|
||||
[node name="Label" type="Label" parent="PanelWood/VBoxContainer/ButtonQuit" unique_id=1896709909]
|
||||
layout_mode = 1
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
grow_horizontal = 2
|
||||
grow_vertical = 2
|
||||
size_flags_horizontal = 7
|
||||
size_flags_vertical = 3
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
theme_override_fonts/font = ExtResource("4")
|
||||
theme_override_font_sizes/font_size = 46
|
||||
theme_override_colors/font_color = Color(0, 0, 0, 1)
|
||||
text = "Quit"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false,
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="ContainerVersion" type="HBoxContainer" parent="PanelWood/VBoxContainer"]
|
||||
offset_top = 1030.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 1050.0
|
||||
[node name="ContainerVersion" type="HBoxContainer" parent="PanelWood/VBoxContainer" unique_id=2120265353]
|
||||
layout_mode = 2
|
||||
|
||||
[node name="MarginLeft" type="MarginContainer" parent="PanelWood/VBoxContainer/ContainerVersion"]
|
||||
offset_right = 283.0
|
||||
offset_bottom = 20.0
|
||||
[node name="MarginLeft" type="MarginContainer" parent="PanelWood/VBoxContainer/ContainerVersion" unique_id=1727590743]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
|
||||
[node name="LabelVersion" type="Label" parent="PanelWood/VBoxContainer/ContainerVersion"]
|
||||
offset_left = 287.0
|
||||
offset_right = 334.0
|
||||
offset_bottom = 20.0
|
||||
[node name="LabelVersion" type="Label" parent="PanelWood/VBoxContainer/ContainerVersion" unique_id=612070584]
|
||||
layout_mode = 2
|
||||
size_flags_vertical = 0
|
||||
theme_override_fonts/font = ExtResource("3")
|
||||
theme_override_colors/font_color = Color(0.741176, 0.478431, 0.372549, 1)
|
||||
theme_override_fonts/font = ExtResource("3")
|
||||
text = "v 0.0.0"
|
||||
horizontal_alignment = 2
|
||||
|
||||
[node name="MarginRight" type="MarginContainer" parent="PanelWood/VBoxContainer/ContainerVersion"]
|
||||
offset_left = 338.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 20.0
|
||||
[node name="MarginRight" type="MarginContainer" parent="PanelWood/VBoxContainer/ContainerVersion" unique_id=265761369]
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_stretch_ratio = 0.04
|
||||
|
||||
[node name="MarginContainerBottom" type="MarginContainer" parent="PanelWood/VBoxContainer"]
|
||||
offset_top = 1080.0
|
||||
offset_right = 350.0
|
||||
offset_bottom = 1080.0
|
||||
[node name="MarginContainerBottom" type="MarginContainer" parent="PanelWood/VBoxContainer" unique_id=62036307]
|
||||
layout_mode = 2
|
||||
size_flags_stretch_ratio = 0.2
|
||||
|
||||
[node name="TextureRect" type="TextureRect" parent="."]
|
||||
offset_left = 350.0
|
||||
offset_right = 446.0
|
||||
offset_bottom = 1080.0
|
||||
[node name="TextureRect" type="TextureRect" parent="." unique_id=900425396]
|
||||
clip_contents = true
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 11
|
||||
size_flags_vertical = 3
|
||||
texture = ExtResource("8")
|
||||
stretch_mode = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="ClickButton" type="AudioStreamPlayer" parent="."]
|
||||
[node name="ClickButton" type="AudioStreamPlayer" parent="." unique_id=1653606507]
|
||||
|
||||
@@ -1,18 +1,13 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://c778egnikip8v"]
|
||||
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/game-title.png" id="1"]
|
||||
[ext_resource type="Texture2D" uid="uid://bfrcdlqx7h0jr" path="res://assets/ui/themes/game-title.png" id="1"]
|
||||
|
||||
[node name="Control" type="CenterContainer"]
|
||||
[node name="Control" type="CenterContainer" unique_id=1033867655]
|
||||
anchors_preset = 15
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
pivot_offset = Vector2(-656.735, -331.043)
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TextureRect" type="TextureRect" parent="."]
|
||||
offset_left = 305.0
|
||||
offset_top = 282.0
|
||||
offset_right = 974.0
|
||||
offset_bottom = 438.0
|
||||
[node name="TextureRect" type="TextureRect" parent="." unique_id=1237902130]
|
||||
layout_mode = 2
|
||||
texture = ExtResource("1")
|
||||
|
||||
+129
-148
@@ -1,79 +1,65 @@
|
||||
extends Node3D
|
||||
|
||||
const TIME_MAX = 3000 # msec
|
||||
const GYROSCOPE_MAX_DIFF = 0.5
|
||||
const OFFSET_CAMERA_MAX = 0.12
|
||||
const OFFSET_STEP_CHANGE = 0.01
|
||||
const RAY_LENGTH = 1000
|
||||
const TIME_MAX := 3000 # msec
|
||||
const GYROSCOPE_MAX_DIFF := 0.5
|
||||
const OFFSET_CAMERA_MAX := 0.12
|
||||
const OFFSET_STEP_CHANGE := 0.01
|
||||
const RAY_LENGTH := 1000
|
||||
|
||||
@export var object_first: PackedScene = load("res://scenes/levels/parts/ObjectListFirst.tscn")
|
||||
@export var object_std: PackedScene = load("res://scenes/levels/parts/ObjectListStandard.tscn")
|
||||
@export var object_last: PackedScene = load("res://scenes/levels/parts/ObjectListLast.tscn")
|
||||
|
||||
@onready var gyroscope_value_old = Vector3(0, 0, 0)
|
||||
@onready var table = Global.database.get_table_by_name("scenes")
|
||||
@onready var meshes = {}
|
||||
@onready var from = null
|
||||
@onready var to = null
|
||||
@onready var mlevel = load("res://db/MLevel.gd")
|
||||
@onready var mscene = load("res://db/MScene.gd")
|
||||
@onready var victory_condition = 0
|
||||
@onready var victory_progress = 0
|
||||
@onready var last_button = null
|
||||
@onready var animation_player = null
|
||||
var gyroscope_value_old := Vector3(0, 0, 0)
|
||||
var meshes: Dictionary[String, SceneEntry] = {}
|
||||
var from = null
|
||||
var to = null
|
||||
var victory_condition: String = "0"
|
||||
var victory_progress: String = "0"
|
||||
var last_button: Node = null
|
||||
|
||||
func _ready():
|
||||
_load_translations()
|
||||
func _ready() -> void:
|
||||
_load_meshes()
|
||||
_load_back_button()
|
||||
_load_prepare_victory_condition()
|
||||
_load_hud_menu()
|
||||
_load_ambient_sound()
|
||||
|
||||
func _load_translations():
|
||||
pass
|
||||
func _load_meshes() -> void:
|
||||
for scene in Global.database.scenes_for_level(Global.current_scene_int):
|
||||
meshes[scene.key] = scene
|
||||
create_dissolve_mesh(scene.key)
|
||||
|
||||
func _load_meshes():
|
||||
var scene_detail = null
|
||||
|
||||
for row_index in range(0, table.m_rows_count):
|
||||
scene_detail = mscene.new(row_index)
|
||||
|
||||
if scene_detail.key() != null:
|
||||
meshes[scene_detail.key()] = scene_detail
|
||||
create_dissolve_mesh(scene_detail.key())
|
||||
|
||||
func _load_back_button():
|
||||
func _load_back_button() -> void:
|
||||
$Quit/TextureButton.pressed.connect(Event._on_main_scene_pressed)
|
||||
|
||||
func _load_prepare_victory_condition():
|
||||
var level = mlevel.new(Global.current_scene_int)
|
||||
|
||||
func _load_prepare_victory_condition() -> void:
|
||||
var level: LevelEntry = Global.database.level_by_index(Global.current_scene_int)
|
||||
if level == null:
|
||||
return
|
||||
victory_condition = level.object_to_find()
|
||||
victory_progress = level.object_finding()
|
||||
|
||||
func _load_hud_menu():
|
||||
var counter = 0
|
||||
var scene = null
|
||||
var label_counter = null
|
||||
|
||||
func _load_hud_menu() -> void:
|
||||
var counter := 0
|
||||
var label_counter: String = ""
|
||||
for key in meshes:
|
||||
scene = meshes[key]
|
||||
var scene: SceneEntry = meshes[key]
|
||||
_create_button_info(scene, counter, label_counter)
|
||||
label_counter = scene.label_counter()
|
||||
counter = counter + 1
|
||||
label_counter = scene.label_counter
|
||||
counter += 1
|
||||
|
||||
func _load_ambient_sound():
|
||||
func _load_ambient_sound() -> void:
|
||||
if Setting.get_setting_ambient_sound():
|
||||
$AmbientSound.play()
|
||||
$AmbientSound.stream_paused = false
|
||||
|
||||
func _create_button_info(scene, counter, label_counter):
|
||||
var button = _search_button_to_use(counter)
|
||||
var label_name = scene.label()
|
||||
func _create_button_info(scene: SceneEntry, counter: int, label_counter: String) -> void:
|
||||
var button := _search_button_to_use(counter)
|
||||
var label_name := scene.label
|
||||
|
||||
if label_counter != null and label_counter == scene.label_counter():
|
||||
label_name = last_button.get_node("Label").text + " " + str(scene.counter())
|
||||
if label_counter != "" and label_counter == scene.label_counter:
|
||||
label_name = last_button.get_node("Label").text + " " + str(scene.counter)
|
||||
_configure_button_object(last_button, scene, label_name)
|
||||
_create_animation_warning(_get_node_animated().get_node("Label"), label_name)
|
||||
else:
|
||||
@@ -83,194 +69,189 @@ func _create_button_info(scene, counter, label_counter):
|
||||
|
||||
last_button = button
|
||||
|
||||
func _get_node_animated():
|
||||
return $ListObjects/ListContainer.get_child($ListObjects/ListContainer.get_child_count() - 1 )
|
||||
func _get_node_animated() -> Node:
|
||||
return $ListObjects/ListContainer.get_child($ListObjects/ListContainer.get_child_count() - 1)
|
||||
|
||||
func _search_button_to_use(counter):
|
||||
func _search_button_to_use(counter: int) -> Node:
|
||||
if counter == 0:
|
||||
return object_first.instantiate()
|
||||
elif counter == meshes.size() - 1:
|
||||
return object_last.instantiate()
|
||||
else:
|
||||
return object_std.instantiate()
|
||||
return object_std.instantiate()
|
||||
|
||||
func _configure_button_object(button, scene, label):
|
||||
func _configure_button_object(button: Node, scene: SceneEntry, label: String) -> void:
|
||||
button.get_node("Label").set_text(label)
|
||||
button.set_meta("animation", label)
|
||||
button.set_meta("name", scene.label())
|
||||
button.set_meta("counter", scene.counter())
|
||||
button.set_meta("name", scene.label)
|
||||
button.set_meta("counter", scene.counter)
|
||||
button.set_meta("counted", 0)
|
||||
|
||||
func _create_animation_slide(node, p_name):
|
||||
func _create_animation_slide(node: Node, p_name: String) -> void:
|
||||
_add_animation_to_player(p_name, GameAnimation.level_hud_slide(node))
|
||||
|
||||
func _create_animation_warning(node, p_name):
|
||||
func _create_animation_warning(node: Node, p_name: String) -> void:
|
||||
_add_animation_to_player(p_name, GameAnimation.level_hud_warning(node))
|
||||
|
||||
func _add_animation_to_player(p_name: String, anim: Animation) -> void:
|
||||
var player = $ListObjects/AnimationPlayer
|
||||
var lib = player.get_animation_library("")
|
||||
var player: AnimationPlayer = $ListObjects/AnimationPlayer
|
||||
var lib := player.get_animation_library("")
|
||||
if lib == null:
|
||||
lib = AnimationLibrary.new()
|
||||
player.add_animation_library("", lib)
|
||||
lib.add_animation(p_name, anim)
|
||||
|
||||
func _process(_delta):
|
||||
func _process(_delta: float) -> void:
|
||||
_check_dissolve_mesh()
|
||||
_check_change_angle_camera()
|
||||
_check_victory_condition()
|
||||
|
||||
func create_dissolve_mesh(key):
|
||||
var mesh = _node_to_mesh(key)
|
||||
func create_dissolve_mesh(key: String) -> void:
|
||||
var mesh := _node_to_mesh(key)
|
||||
if mesh == null:
|
||||
return
|
||||
var material = mesh.get_active_material(0)
|
||||
var material := mesh.get_active_material(0)
|
||||
if material == null:
|
||||
return
|
||||
material.set_shader_parameter("dissolve_amount", 0.0)
|
||||
|
||||
func _check_dissolve_mesh():
|
||||
func _check_dissolve_mesh() -> void:
|
||||
# Event dissolve in object searched by gamer
|
||||
for key in meshes:
|
||||
if bool(meshes[key].lock()) == true and meshes[key].mesh() != null:
|
||||
var mesh = _node_to_mesh(key)
|
||||
if mesh == null:
|
||||
continue
|
||||
if meshes[key].tick_reference() == 0:
|
||||
meshes[key].set_tick_reference(Time.get_ticks_msec())
|
||||
_node_object_list(key)
|
||||
GameAnimation.start_dissolve(mesh, mesh.get_active_material(0))
|
||||
var scene: SceneEntry = meshes[key]
|
||||
if not scene.lock or scene.dissolved:
|
||||
continue
|
||||
var mesh := _node_to_mesh(key)
|
||||
if mesh == null:
|
||||
continue
|
||||
if scene.dissolve_tick_reference == 0:
|
||||
scene.dissolve_tick_reference = Time.get_ticks_msec()
|
||||
_node_object_list(key)
|
||||
GameAnimation.start_dissolve(mesh, mesh.get_active_material(0))
|
||||
if Time.get_ticks_msec() < scene.dissolve_tick_reference + TIME_MAX:
|
||||
scene.dissolve_value += 0.01
|
||||
else:
|
||||
_clean_mesh(key)
|
||||
|
||||
if Time.get_ticks_msec() < meshes[key].tick_reference() + TIME_MAX:
|
||||
meshes[key].set_value(meshes[key].value() + 0.01)
|
||||
else:
|
||||
_clean_mesh(key)
|
||||
func _clean_mesh(key: String) -> void:
|
||||
var level: LevelEntry = Global.database.level_by_index(Global.current_scene_int)
|
||||
if level != null:
|
||||
victory_progress = level.object_finding()
|
||||
var mesh := _node_to_mesh(key)
|
||||
if mesh != null:
|
||||
mesh.call_deferred("free")
|
||||
meshes[key].dissolved = true
|
||||
|
||||
func _clean_mesh(key):
|
||||
victory_progress = mlevel.new(Global.current_scene_int).object_finding()
|
||||
_node_to_mesh(key).call_deferred("free")
|
||||
meshes[key].set_mesh(null)
|
||||
func _check_change_angle_camera() -> void:
|
||||
var camera: Camera3D = $"MainCamera"
|
||||
var gyroscope := Input.get_gyroscope()
|
||||
|
||||
func _check_change_angle_camera():
|
||||
var camera = $"MainCamera"
|
||||
var gyroscope = Input.get_gyroscope()
|
||||
|
||||
if camera.h_offset >= -OFFSET_CAMERA_MAX:
|
||||
if _action_pressed("ui_left") or _action_gyroscope("left", gyroscope):
|
||||
print("[warcraft#_ready] move camera angle to left")
|
||||
$"Main Camera3D".h_offset -= OFFSET_STEP_CHANGE
|
||||
|
||||
|
||||
if camera.h_offset <= OFFSET_CAMERA_MAX:
|
||||
if _action_pressed("ui_right") or _action_gyroscope("right", gyroscope):
|
||||
print("[warcraft#_ready] move camera angle to right")
|
||||
$"Main Camera3D".h_offset += OFFSET_STEP_CHANGE
|
||||
|
||||
|
||||
if camera.v_offset >= -OFFSET_CAMERA_MAX:
|
||||
if _action_pressed("ui_down") or _action_gyroscope("down", gyroscope):
|
||||
print("[warcraft#_ready] move camera angle to down")
|
||||
$"Main Camera3D".v_offset -= OFFSET_STEP_CHANGE
|
||||
|
||||
|
||||
if camera.v_offset <= OFFSET_CAMERA_MAX:
|
||||
if _action_pressed("ui_up") or _action_gyroscope("up", gyroscope):
|
||||
print("[warcraft#_ready] move camera angle to up")
|
||||
$"Main Camera3D".v_offset += OFFSET_STEP_CHANGE
|
||||
|
||||
|
||||
gyroscope_value_old = gyroscope
|
||||
|
||||
func _action_pressed(action):
|
||||
func _action_pressed(action: String) -> bool:
|
||||
return Input.is_action_pressed(action)
|
||||
|
||||
func _action_gyroscope(action, gyroscope):
|
||||
if Setting.get_setting_gyrosocpe():
|
||||
var expression = Expression.new()
|
||||
|
||||
expression.parse("_gyroscope_changed_"+action+"(gyroscope)", ["gyroscope"])
|
||||
|
||||
if expression.execute([gyroscope], self):
|
||||
return true
|
||||
else:
|
||||
return false
|
||||
else:
|
||||
func _action_gyroscope(action: String, gyroscope: Vector3) -> bool:
|
||||
if not Setting.get_setting_gyrosocpe():
|
||||
return false
|
||||
var expression := Expression.new()
|
||||
expression.parse("_gyroscope_changed_" + action + "(gyroscope)", ["gyroscope"])
|
||||
return bool(expression.execute([gyroscope], self))
|
||||
|
||||
func _gyroscope_changed_left(gyroscope):
|
||||
func _gyroscope_changed_left(gyroscope: Vector3) -> bool:
|
||||
return (gyroscope.abs().y - gyroscope_value_old.abs().y) > GYROSCOPE_MAX_DIFF and \
|
||||
gyroscope.y < gyroscope_value_old.y
|
||||
|
||||
func _gyroscope_changed_right(gyroscope):
|
||||
func _gyroscope_changed_right(gyroscope: Vector3) -> bool:
|
||||
return (gyroscope.abs().y - gyroscope_value_old.abs().y) > GYROSCOPE_MAX_DIFF and \
|
||||
gyroscope.y > gyroscope_value_old.y
|
||||
|
||||
func _gyroscope_changed_down(gyroscope):
|
||||
func _gyroscope_changed_down(gyroscope: Vector3) -> bool:
|
||||
return (gyroscope.abs().z - gyroscope_value_old.abs().z) > GYROSCOPE_MAX_DIFF and \
|
||||
gyroscope.z > gyroscope_value_old.z or \
|
||||
(gyroscope.abs().x - gyroscope_value_old.abs().x) > GYROSCOPE_MAX_DIFF and \
|
||||
gyroscope.x > gyroscope_value_old.x
|
||||
|
||||
func _gyroscope_changed_up(gyroscope):
|
||||
func _gyroscope_changed_up(gyroscope: Vector3) -> bool:
|
||||
return (gyroscope.abs().z - gyroscope_value_old.abs().z) > GYROSCOPE_MAX_DIFF and \
|
||||
gyroscope.z < gyroscope_value_old.z or \
|
||||
(gyroscope.abs().x - gyroscope_value_old.abs().x) > GYROSCOPE_MAX_DIFF and \
|
||||
gyroscope.x < gyroscope_value_old.x
|
||||
|
||||
func _start_dissolve(key):
|
||||
if bool(meshes[key].lock()) == false:
|
||||
meshes[key].set_lock(int(true))
|
||||
$ObjectFind.stream = meshes[key].audio_sound()
|
||||
$ObjectFind.play()
|
||||
func _start_dissolve(key: String) -> void:
|
||||
if not meshes.has(key):
|
||||
return
|
||||
var scene: SceneEntry = meshes[key]
|
||||
if scene.lock:
|
||||
return
|
||||
scene.lock = true
|
||||
Global.database.save()
|
||||
$ObjectFind.stream = scene.audio_sound()
|
||||
$ObjectFind.play()
|
||||
|
||||
func _check_victory_condition():
|
||||
func _check_victory_condition() -> void:
|
||||
if victory_condition == victory_progress:
|
||||
print("[levels#_check_victory_condition] \\o/\\o/ \\o/ \\o/ \\o/\\o/")
|
||||
print("[levels#_check_victory_condition] Win !!")
|
||||
Global.goto_scene("res://scenes/UI/ending/Ending.tscn")
|
||||
|
||||
func _node_to_mesh(key):
|
||||
return get_node_or_null(meshes[key].mesh())
|
||||
|
||||
func _node_to_area(key):
|
||||
return get_node_or_null(meshes[key].mesh() + "/Area3D")
|
||||
|
||||
func _node_object_list(key):
|
||||
var animation_played = null
|
||||
func _node_to_mesh(key: String) -> MeshInstance3D:
|
||||
if not meshes.has(key):
|
||||
return null
|
||||
return get_node_or_null(meshes[key].mesh_path()) as MeshInstance3D
|
||||
|
||||
func _node_object_list(key: String) -> void:
|
||||
var animation_played: String = ""
|
||||
for child in $ListObjects/ListContainer.get_children():
|
||||
if child.has_meta("name"):
|
||||
if child.get_meta("name") == meshes[key].label():
|
||||
child.set_meta("counted", child.get_meta("counted") + 1)
|
||||
|
||||
if child.get_meta("counter") == child.get_meta("counted"):
|
||||
animation_played = child.get_meta("name")
|
||||
else:
|
||||
var diff = child.get_meta("counter") - child.get_meta("counted")
|
||||
var txt = child.get_meta("name")
|
||||
if diff != 1:
|
||||
txt = txt + " " + str(diff)
|
||||
animation_played = child.get_meta("animation")
|
||||
child.get_node("Label").set_text(txt)
|
||||
|
||||
$ListObjects/AnimationPlayer.queue(animation_played)
|
||||
if not child.has_meta("name"):
|
||||
continue
|
||||
if child.get_meta("name") != meshes[key].label:
|
||||
continue
|
||||
child.set_meta("counted", child.get_meta("counted") + 1)
|
||||
if child.get_meta("counter") == child.get_meta("counted"):
|
||||
animation_played = child.get_meta("name")
|
||||
else:
|
||||
var diff: int = child.get_meta("counter") - child.get_meta("counted")
|
||||
var txt: String = child.get_meta("name")
|
||||
if diff != 1:
|
||||
txt = txt + " " + str(diff)
|
||||
animation_played = child.get_meta("animation")
|
||||
child.get_node("Label").set_text(txt)
|
||||
$ListObjects/AnimationPlayer.queue(animation_played)
|
||||
|
||||
func _input(event):
|
||||
func _input(event: InputEvent) -> void:
|
||||
if event is InputEventMouseButton or event is InputEventScreenTouch:
|
||||
var camera = $"MainCamera"
|
||||
var camera: Camera3D = $"MainCamera"
|
||||
from = camera.project_ray_origin(event.position)
|
||||
to = from + camera.project_ray_normal(event.position) * RAY_LENGTH
|
||||
|
||||
func _physics_process(_delta):
|
||||
var space_state = get_world_3d().direct_space_state
|
||||
func _physics_process(_delta: float) -> void:
|
||||
var space_state := get_world_3d().direct_space_state
|
||||
if from != null and to != null:
|
||||
_check_collider(space_state)
|
||||
|
||||
func _check_collider(space_state):
|
||||
var query = PhysicsRayQueryParameters3D.create(from, to)
|
||||
func _check_collider(space_state: PhysicsDirectSpaceState3D) -> void:
|
||||
var query := PhysicsRayQueryParameters3D.create(from, to)
|
||||
query.collision_mask = 1
|
||||
query.collide_with_bodies = false
|
||||
query.collide_with_areas = true
|
||||
var result = space_state.intersect_ray(query)
|
||||
var result := space_state.intersect_ray(query)
|
||||
from = null
|
||||
to = null
|
||||
if result.has("collider"):
|
||||
var node = result["collider"].get_parent()
|
||||
var node: Node = result["collider"].get_parent()
|
||||
if node != null:
|
||||
_start_dissolve(node.name)
|
||||
|
||||
+10
-11
@@ -1,20 +1,19 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://c8cbqvsyyn3m3"]
|
||||
|
||||
[ext_resource type="Script" path="res://scenes/levels/Levels.gd" id="1"]
|
||||
[ext_resource type="AudioStream" path="res://assets/sounds/ambient-sound-level-warcraft.ogg" id="2"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/levels/parts/Back.tscn" id="3"]
|
||||
[ext_resource type="PackedScene" path="res://scenes/levels/parts/ListObjects.tscn" id="4"]
|
||||
[ext_resource type="Script" uid="uid://ce1psw7egwxgt" path="res://scenes/levels/Levels.gd" id="1"]
|
||||
[ext_resource type="AudioStream" uid="uid://c5a3t4h5uuheq" path="res://assets/sounds/ambient-sound-level-warcraft.ogg" id="2"]
|
||||
[ext_resource type="PackedScene" uid="uid://caedpu4rcpa6a" path="res://scenes/levels/parts/Back.tscn" id="3"]
|
||||
[ext_resource type="PackedScene" uid="uid://bgqkui3o0tkfq" path="res://scenes/levels/parts/ListObjects.tscn" id="4"]
|
||||
|
||||
[node name="Node3D" type="Node3D"]
|
||||
[node name="Node3D" type="Node3D" unique_id=1371937604]
|
||||
script = ExtResource("1")
|
||||
|
||||
[node name="ListObjects" parent="." instance=ExtResource("4")]
|
||||
[node name="ListObjects" parent="." unique_id=761455924 instance=ExtResource("4")]
|
||||
|
||||
[node name="Quit" parent="." instance=ExtResource("3")]
|
||||
[node name="Quit" parent="." unique_id=1722889037 instance=ExtResource("3")]
|
||||
|
||||
[node name="AmbientSound" type="AudioStreamPlayer" parent="."]
|
||||
[node name="AmbientSound" type="AudioStreamPlayer" parent="." unique_id=135767778]
|
||||
stream = ExtResource("2")
|
||||
volume_db = -15.0
|
||||
stream_paused = true
|
||||
|
||||
[node name="ObjectFind" type="AudioStreamPlayer" parent="."]
|
||||
[node name="ObjectFind" type="AudioStreamPlayer" parent="." unique_id=586286347]
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://couv4chot3vuy"]
|
||||
|
||||
[ext_resource type="PackedScene" path="res://scenes/levels/Levels.tscn" id="1"]
|
||||
[ext_resource type="PackedScene" uid="uid://c8cbqvsyyn3m3" path="res://scenes/levels/Levels.tscn" id="1"]
|
||||
|
||||
[sub_resource type="Sky" id="1"]
|
||||
|
||||
@@ -11,7 +11,6 @@ background_energy_multiplier = 0.6
|
||||
sky = SubResource("1")
|
||||
ambient_light_color = Color(0.694118, 0.168627, 0.67451, 1)
|
||||
ambient_light_sky_contribution = 0.5
|
||||
ambient_light_energy = 0.4
|
||||
tonemap_mode = 2
|
||||
ssr_enabled = true
|
||||
glow_enabled = true
|
||||
@@ -24,12 +23,9 @@ fog_depth_curve = 1.10957
|
||||
fog_depth_begin = 0.0
|
||||
fog_depth_end = 60.0
|
||||
|
||||
[node name="Home" instance=ExtResource("1")]
|
||||
[node name="Home" unique_id=962070354 instance=ExtResource("1")]
|
||||
|
||||
[node name="MainCamera" type="Camera3D" parent="." index="4"]
|
||||
[node name="MainCamera" type="Camera3D" parent="." index="4" unique_id=1199679200]
|
||||
transform = Transform3D(0.160708, -0.25632, 0.953138, 0, 0.96569, 0.259696, -0.987002, -0.0417351, 0.155194, 1.84336, 1.66169, 0.663199)
|
||||
environment = SubResource("2")
|
||||
fov = 38.5632
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
@@ -1,22 +1,19 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://caedpu4rcpa6a"]
|
||||
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-Back.png" id="1"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-Back-Overlay.png" id="2"]
|
||||
[ext_resource type="Texture2D" uid="uid://c3tndlulsrson" path="res://assets/ui/themes/UI-Button-Back.png" id="1"]
|
||||
[ext_resource type="Texture2D" uid="uid://btf3i68yapi3b" path="res://assets/ui/themes/UI-Button-Back-Overlay.png" id="2"]
|
||||
|
||||
[node name="Control" type="Control"]
|
||||
[node name="Control" type="Control" unique_id=722170891]
|
||||
layout_mode = 3
|
||||
anchors_preset = 0
|
||||
offset_right = 1440.0
|
||||
offset_bottom = 900.0
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="TextureButton" type="TextureButton" parent="."]
|
||||
[node name="TextureButton" type="TextureButton" parent="." unique_id=1245301894]
|
||||
layout_mode = 0
|
||||
offset_right = 40.0
|
||||
offset_bottom = 40.0
|
||||
mouse_default_cursor_shape = 2
|
||||
texture_normal = ExtResource("1")
|
||||
texture_hover = ExtResource("2")
|
||||
texture_focused = ExtResource("2")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://bgqkui3o0tkfq"]
|
||||
|
||||
[ext_resource type="Theme" path="res://assets/ui/themes/leather.theme" id="2"]
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_base.tres" id="3"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/icones/skull.png" id="4"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList-last-hover.png" id="6"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList-last.png" id="8"]
|
||||
[ext_resource type="FontVariation" uid="uid://inv1rofq17xy" path="res://assets/fonts/kirsty/kirsty_base.tres" id="3"]
|
||||
[ext_resource type="Texture2D" uid="uid://dn8uon4qa6naj" path="res://assets/ui/icones/skull.png" id="4"]
|
||||
[ext_resource type="Texture2D" uid="uid://b6qxaqvf46lvy" path="res://assets/ui/themes/UI-Button-ItemsList-last-hover.png" id="6"]
|
||||
[ext_resource type="Texture2D" uid="uid://dxd25u6105236" path="res://assets/ui/themes/UI-Button-ItemsList-last.png" id="8"]
|
||||
|
||||
[sub_resource type="Animation" id="1"]
|
||||
resource_name = "ObjectFind"
|
||||
@@ -33,7 +33,14 @@ tracks/0/keys = {
|
||||
"times": PackedFloat32Array(0, 1)
|
||||
}
|
||||
|
||||
[node name="Control" type="MarginContainer"]
|
||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_vpan8"]
|
||||
_data = {
|
||||
&"ObjectFind": SubResource("1"),
|
||||
&"ObjectFindAll": SubResource("2")
|
||||
}
|
||||
|
||||
[node name="Control" type="MarginContainer" unique_id=316364814]
|
||||
anchors_preset = 6
|
||||
anchor_left = 1.0
|
||||
anchor_top = 0.5
|
||||
anchor_right = 1.0
|
||||
@@ -44,30 +51,25 @@ offset_bottom = 450.0
|
||||
grow_horizontal = 0
|
||||
grow_vertical = 2
|
||||
size_flags_vertical = 3
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="ListContainer" type="VBoxContainer" parent="."]
|
||||
offset_right = 196.0
|
||||
offset_bottom = 900.0
|
||||
[node name="ListContainer" type="VBoxContainer" parent="." unique_id=10094609]
|
||||
custom_minimum_size = Vector2(196, 900)
|
||||
layout_mode = 2
|
||||
size_flags_horizontal = 3
|
||||
size_flags_vertical = 3
|
||||
theme_override_constants/separation = -14
|
||||
alignment = 1
|
||||
|
||||
[node name="TextureButtonLast" type="TextureButton" parent="ListContainer"]
|
||||
[node name="TextureButtonLast" type="TextureButton" parent="ListContainer" unique_id=129456161]
|
||||
visible = false
|
||||
offset_top = 409.0
|
||||
offset_right = 196.0
|
||||
offset_bottom = 490.0
|
||||
layout_mode = 2
|
||||
focus_mode = 0
|
||||
texture_normal = ExtResource("8")
|
||||
texture_hover = ExtResource("6")
|
||||
texture_focused = ExtResource("6")
|
||||
|
||||
[node name="Label" type="Label" parent="ListContainer/TextureButtonLast"]
|
||||
[node name="Label" type="Label" parent="ListContainer/TextureButtonLast" unique_id=172840960]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
theme = ExtResource("2")
|
||||
@@ -75,23 +77,15 @@ theme_override_fonts/font = ExtResource("3")
|
||||
text = "Last"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="ListContainer"]
|
||||
[node name="HBoxContainer" type="HBoxContainer" parent="ListContainer" unique_id=1143563347]
|
||||
visible = false
|
||||
offset_top = 419.0
|
||||
offset_right = 196.0
|
||||
offset_bottom = 547.0
|
||||
layout_mode = 2
|
||||
alignment = 1
|
||||
|
||||
[node name="TextureButtonIndice" type="TextureButton" parent="ListContainer/HBoxContainer"]
|
||||
offset_left = 34.0
|
||||
offset_right = 162.0
|
||||
offset_bottom = 128.0
|
||||
[node name="TextureButtonIndice" type="TextureButton" parent="ListContainer/HBoxContainer" unique_id=273706555]
|
||||
layout_mode = 2
|
||||
texture_normal = ExtResource("4")
|
||||
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||
anims/ObjectFind = SubResource("1")
|
||||
anims/ObjectFindAll = SubResource("2")
|
||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="." unique_id=360897851]
|
||||
libraries/ = SubResource("AnimationLibrary_vpan8")
|
||||
|
||||
@@ -1,21 +1,18 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://bby57ysxl07dj"]
|
||||
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList-first-hover.png" id="1"]
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_base.tres" id="2"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList-first.png" id="3"]
|
||||
[ext_resource type="Texture2D" uid="uid://cfhudyifoebpt" path="res://assets/ui/themes/UI-Button-ItemsList-first-hover.png" id="1"]
|
||||
[ext_resource type="FontVariation" uid="uid://inv1rofq17xy" path="res://assets/fonts/kirsty/kirsty_base.tres" id="2"]
|
||||
[ext_resource type="Texture2D" uid="uid://bgd2d1mwwloun" path="res://assets/ui/themes/UI-Button-ItemsList-first.png" id="3"]
|
||||
|
||||
[node name="TextureButton" type="TextureButton"]
|
||||
[node name="TextureButton" type="TextureButton" unique_id=2046084801]
|
||||
offset_right = 196.0
|
||||
offset_bottom = 81.0
|
||||
texture_normal = ExtResource("3")
|
||||
texture_hover = ExtResource("1")
|
||||
texture_focused = ExtResource("1")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false,
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
[node name="Label" type="Label" parent="." unique_id=1188661282]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
offset_right = -3.05176e-05
|
||||
@@ -23,6 +20,3 @@ theme_override_fonts/font = ExtResource("2")
|
||||
text = "First Entry"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
@@ -1,22 +1,19 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://b6lqvebvxutd4"]
|
||||
|
||||
[ext_resource type="Theme" path="res://assets/ui/themes/leather.theme" id="1"]
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_base.tres" id="2"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList-last-hover.png" id="3"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList-last.png" id="4"]
|
||||
[ext_resource type="FontVariation" uid="uid://inv1rofq17xy" path="res://assets/fonts/kirsty/kirsty_base.tres" id="2"]
|
||||
[ext_resource type="Texture2D" uid="uid://b6qxaqvf46lvy" path="res://assets/ui/themes/UI-Button-ItemsList-last-hover.png" id="3"]
|
||||
[ext_resource type="Texture2D" uid="uid://dxd25u6105236" path="res://assets/ui/themes/UI-Button-ItemsList-last.png" id="4"]
|
||||
|
||||
[node name="TextureButton" type="TextureButton"]
|
||||
[node name="TextureButton" type="TextureButton" unique_id=692381198]
|
||||
offset_right = 196.0
|
||||
offset_bottom = 81.0
|
||||
texture_normal = ExtResource("4")
|
||||
texture_hover = ExtResource("3")
|
||||
texture_focused = ExtResource("3")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false,
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
[node name="Label" type="Label" parent="." unique_id=1734999920]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
theme = ExtResource("1")
|
||||
@@ -24,6 +21,3 @@ theme_override_fonts/font = ExtResource("2")
|
||||
text = "Last"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
@@ -1,27 +1,21 @@
|
||||
[gd_scene format=3]
|
||||
[gd_scene format=3 uid="uid://bfk6qijaib0to"]
|
||||
|
||||
[ext_resource type="FontVariation" path="res://assets/fonts/kirsty/kirsty_base.tres" id="1"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList.png" id="2"]
|
||||
[ext_resource type="Texture2D" path="res://assets/ui/themes/UI-Button-ItemsList-hover.png" id="3"]
|
||||
[ext_resource type="FontVariation" uid="uid://inv1rofq17xy" path="res://assets/fonts/kirsty/kirsty_base.tres" id="1"]
|
||||
[ext_resource type="Texture2D" uid="uid://cfnphivxnyeqx" path="res://assets/ui/themes/UI-Button-ItemsList.png" id="2"]
|
||||
[ext_resource type="Texture2D" uid="uid://dgxfqk5oc3vxq" path="res://assets/ui/themes/UI-Button-ItemsList-hover.png" id="3"]
|
||||
|
||||
[node name="TextureButton" type="TextureButton"]
|
||||
[node name="TextureButton" type="TextureButton" unique_id=57974175]
|
||||
offset_right = 196.0
|
||||
offset_bottom = 81.0
|
||||
texture_normal = ExtResource("2")
|
||||
texture_hover = ExtResource("3")
|
||||
texture_focused = ExtResource("3")
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false,
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
[node name="Label" type="Label" parent="." unique_id=796010441]
|
||||
layout_mode = 0
|
||||
anchor_right = 1.0
|
||||
anchor_bottom = 1.0
|
||||
theme_override_fonts/font = ExtResource("1")
|
||||
text = "Middle"
|
||||
horizontal_alignment = 1
|
||||
vertical_alignment = 1
|
||||
__meta__ = {
|
||||
"_edit_use_anchors_": false
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[gd_scene format=4]
|
||||
[gd_scene format=4 uid="uid://bkq24nk716fvj"]
|
||||
|
||||
[ext_resource type="PackedScene" path="res://scenes/levels/Levels.tscn" id="1"]
|
||||
[ext_resource type="PackedScene" uid="uid://c8cbqvsyyn3m3" path="res://scenes/levels/Levels.tscn" id="1"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/stack gold/sm_stackgold.mesh" id="2"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/fiole/sm_fiole_socle.mesh" id="3"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/apple/sm_apple.mesh" id="4"]
|
||||
@@ -26,18 +26,18 @@
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/candle/sm_candle_d_lod1.mesh" id="25"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/candle/sm_candle_top_lod1.mesh" id="26"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/candle/sm_candle_b_lod1.mesh" id="27"]
|
||||
[ext_resource type="PackedScene" path="res://assets/props/table/sm_table.tscn" id="28"]
|
||||
[ext_resource type="PackedScene" path="res://assets/props/candle/sm_candlestick.tscn" id="29"]
|
||||
[ext_resource type="PackedScene" path="res://assets/props/parchment/sm_parchment.tscn" id="30"]
|
||||
[ext_resource type="PackedScene" path="res://assets/props/stool b/sm_stool_2.tscn" id="31"]
|
||||
[ext_resource type="PackedScene" path="res://assets/props/godet/sm_godet.tscn" id="32"]
|
||||
[ext_resource type="PackedScene" path="res://assets/props/book/sm_book.tscn" id="33"]
|
||||
[ext_resource type="PackedScene" path="res://assets/props/growler/sm_growler.tscn" id="34"]
|
||||
[ext_resource type="PackedScene" uid="uid://deg2or4d7j3ra" path="res://assets/props/table/sm_table.tscn" id="28"]
|
||||
[ext_resource type="PackedScene" uid="uid://tlua1pg4ro8u" path="res://assets/props/candle/sm_candlestick.tscn" id="29"]
|
||||
[ext_resource type="PackedScene" uid="uid://ck15k8nlgsgyw" path="res://assets/props/parchment/sm_parchment.tscn" id="30"]
|
||||
[ext_resource type="PackedScene" uid="uid://8v3e4xmvehhx" path="res://assets/props/stool b/sm_stool_2.tscn" id="31"]
|
||||
[ext_resource type="PackedScene" uid="uid://cgi8sru6qky81" path="res://assets/props/godet/sm_godet.tscn" id="32"]
|
||||
[ext_resource type="PackedScene" uid="uid://lt8fwag3uivj" path="res://assets/props/book/sm_book.tscn" id="33"]
|
||||
[ext_resource type="PackedScene" uid="uid://ceyvbjwaca6gl" path="res://assets/props/growler/sm_growler.tscn" id="34"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/column/sm_column.mesh" id="35"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/misc/plane.mesh" id="36"]
|
||||
[ext_resource type="MeshLibrary" path="res://assets/props/rock floor/floor_lib.meshlib" id="37"]
|
||||
[ext_resource type="ArrayMesh" path="res://assets/props/fireplace/sm_fireplace.mesh" id="38"]
|
||||
[ext_resource type="Material" path="res://assets/materials/gray.tres" id="39"]
|
||||
[ext_resource type="Material" uid="uid://vj5s8nwv5ac7" path="res://assets/materials/gray.tres" id="39"]
|
||||
[ext_resource type="Material" path="res://assets/props/rock floor/materials/MA_rock_floor.material" id="40"]
|
||||
|
||||
[sub_resource type="Sky" id="1"]
|
||||
@@ -49,7 +49,6 @@ background_energy_multiplier = 0.6
|
||||
sky = SubResource("1")
|
||||
ambient_light_color = Color(0.694118, 0.168627, 0.67451, 1)
|
||||
ambient_light_sky_contribution = 0.5
|
||||
ambient_light_energy = 0.4
|
||||
tonemap_mode = 2
|
||||
ssr_enabled = true
|
||||
glow_enabled = true
|
||||
@@ -146,465 +145,414 @@ fog_depth_curve = 1.10957
|
||||
fog_depth_begin = 0.0
|
||||
fog_depth_end = 60.0
|
||||
|
||||
[node name="Warcraft" instance=ExtResource("1")]
|
||||
[node name="Warcraft" unique_id=345493318 instance=ExtResource("1")]
|
||||
|
||||
[node name="MainCamera" type="Camera3D" parent="." index="4"]
|
||||
[node name="MainCamera" type="Camera3D" parent="." index="4" unique_id=393336172]
|
||||
transform = Transform3D(0.160708, -0.25632, 0.953138, 0, 0.96569, 0.259696, -0.987002, -0.0417352, 0.155194, 1.84336, 1.66169, 0.663199)
|
||||
environment = SubResource("2")
|
||||
fov = 38.5632
|
||||
__meta__ = {
|
||||
"_editor_description_": ""
|
||||
}
|
||||
|
||||
[node name="HiddenObjectsItems" type="RayCast3D" parent="." index="5"]
|
||||
[node name="HiddenObjectsItems" type="RayCast3D" parent="." index="5" unique_id=1025977229]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.233905, 1.0296, -0.405055)
|
||||
collision_mask = 2
|
||||
collide_with_areas = true
|
||||
collide_with_bodies = false
|
||||
|
||||
[node name="Fioles" type="Node3D" parent="HiddenObjectsItems" index="0"]
|
||||
[node name="Fioles" type="Node3D" parent="HiddenObjectsItems" index="0" unique_id=2800182]
|
||||
|
||||
[node name="Fiole1" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles" index="0"]
|
||||
[node name="Fiole1" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles" index="0" unique_id=955369630]
|
||||
transform = Transform3D(-0.210773, -0.635682, 0.742619, 0.949185, -0.314721, 0, 0.233718, 0.704883, 0.669714, 0.0481223, 0, -0.094099)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("12")
|
||||
surface_material_override/0 = ExtResource("13")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Fioles/Fiole1" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Fioles/Fiole1" index="0" unique_id=332657566]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Fioles/Fiole1/Area3D" index="0"]
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Fioles/Fiole1/Area3D" index="0" unique_id=1406858482]
|
||||
transform = Transform3D(1, 2.98023e-08, -4.47035e-08, -2.98023e-08, -8.9407e-08, 1, -1.19209e-07, -1, -1.49012e-07, 0, 0.0801148, -2.98023e-08)
|
||||
shape = SubResource("3")
|
||||
|
||||
[node name="Fiole2" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles" index="1"]
|
||||
[node name="Fiole2" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles" index="1" unique_id=103765745]
|
||||
transform = Transform3D(0.655275, 0.636944, -0.4061, 0.670978, -0.243833, 0.700239, 0.346993, -0.731333, -0.587153, -4.19531, -0.894133, 2.66915)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("12")
|
||||
surface_material_override/0 = ExtResource("19")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Fioles/Fiole2" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Fioles/Fiole2" index="0" unique_id=2127726958]
|
||||
transform = Transform3D(1, -2.98023e-08, 0, -2.98023e-08, 1, 0, 1.49012e-08, -1.19209e-07, 1, -2.38419e-07, -0.0202575, 0)
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Fioles/Fiole2/Area3D" index="0"]
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Fioles/Fiole2/Area3D" index="0" unique_id=999529519]
|
||||
transform = Transform3D(1, 5.96046e-08, -8.9407e-08, 2.98023e-08, -8.9407e-08, 1, -8.9407e-08, -1, 0, 2.38419e-07, 0.0823998, -1.19209e-07)
|
||||
shape = SubResource("4")
|
||||
|
||||
[node name="FioleSocle" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles" index="2"]
|
||||
[node name="FioleSocle" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles" index="2" unique_id=1265322717]
|
||||
transform = Transform3D(0.6773, -1.86265e-09, 0.735707, -0.0293841, 0.999202, 0.0270513, -0.73512, -0.03994, 0.67676, -2.27881, -0.11528, -1.23929)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("3")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="Fiole3" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles/FioleSocle" index="0"]
|
||||
[node name="Fiole3" type="MeshInstance3D" parent="HiddenObjectsItems/Fioles/FioleSocle" index="0" unique_id=1395377242]
|
||||
transform = Transform3D(0.919703, -0.349433, -0.179005, 0.316708, 0.929754, -0.187758, 0.232039, 0.115989, 0.965766, -1.19209e-07, 0.1147, 0.00100636)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("12")
|
||||
surface_material_override/0 = ExtResource("21")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Fioles/FioleSocle/Fiole3" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Fioles/FioleSocle/Fiole3" index="0" unique_id=568423200]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Fioles/FioleSocle/Fiole3/Area3D" index="0"]
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Fioles/FioleSocle/Fiole3/Area3D" index="0" unique_id=1521608711]
|
||||
transform = Transform3D(1, 2.08616e-07, -7.45058e-08, -5.96046e-08, -1.49012e-07, 1, 5.96046e-08, -1, -1.04308e-07, -1.78814e-07, 0.0560231, 0)
|
||||
shape = SubResource("5")
|
||||
|
||||
[node name="Dagger" type="MeshInstance3D" parent="HiddenObjectsItems" index="1"]
|
||||
[node name="Dagger" type="MeshInstance3D" parent="HiddenObjectsItems" index="1" unique_id=1643532804]
|
||||
transform = Transform3D(-0.625025, -0.777847, 0.0655765, 0, 0.0840072, 0.996466, -0.780606, 0.622816, -0.0525065, 0.69073, -0.117415, 0.830941)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("17")
|
||||
surface_material_override/0 = ExtResource("14")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Dagger" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Dagger" index="0" unique_id=1063229720]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Dagger/Area3D" index="0"]
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Dagger/Area3D" index="0" unique_id=2023818708]
|
||||
transform = Transform3D(1, 0, 0, 0, -4.37114e-08, 1, 0, -1, -4.37114e-08, 0, 0.0802139, 0)
|
||||
shape = SubResource("6")
|
||||
|
||||
[node name="Spyglass" type="MeshInstance3D" parent="HiddenObjectsItems" index="2"]
|
||||
[node name="Spyglass" type="MeshInstance3D" parent="HiddenObjectsItems" index="2" unique_id=1094398513]
|
||||
transform = Transform3D(0.652362, 0.137749, 0.63579, -0.234678, 0.889605, 0.0480562, -0.606736, -0.195981, 0.665013, -2.884, -0.292075, -0.429783)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("23")
|
||||
surface_material_override/0 = ExtResource("24")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Spyglass" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Spyglass" index="0" unique_id=413854268]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Spyglass/Area3D" index="0"]
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="HiddenObjectsItems/Spyglass/Area3D" index="0" unique_id=220484189]
|
||||
transform = Transform3D(1, 0, 2.98023e-08, 1.86265e-09, 1, 3.72529e-09, 0, 5.58794e-09, 1, 2.38419e-07, -1.19209e-07, 0.0177531)
|
||||
shape = SubResource("7")
|
||||
|
||||
[node name="Beer" type="MeshInstance3D" parent="HiddenObjectsItems" index="3"]
|
||||
[node name="Beer" type="MeshInstance3D" parent="HiddenObjectsItems" index="3" unique_id=1035641934]
|
||||
transform = Transform3D(0.996658, -0.053142, 0.0620432, 0.0548108, 0.998171, -0.0255105, -0.060574, 0.0288258, 0.997748, -2.8842, 0.173697, 1.98168)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("22")
|
||||
surface_material_override/0 = ExtResource("5")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Beer" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Beer" index="0" unique_id=1547056764]
|
||||
transform = Transform3D(1, 0, 7.45058e-09, -1.16415e-10, 1, -1.86265e-09, 0, 0, 1, -2.38419e-07, -0.21161, -1.19209e-07)
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeBeer" type="CollisionShape3D" parent="HiddenObjectsItems/Beer/Area3D" index="0"]
|
||||
[node name="CollisionShapeBeer" type="CollisionShape3D" parent="HiddenObjectsItems/Beer/Area3D" index="0" unique_id=1719564897]
|
||||
transform = Transform3D(1, 0, -1.61817e-08, 1.83936e-08, -4.28408e-08, 1, 0, -1, -4.65661e-08, 9.53674e-07, 0.0746492, 2.38419e-07)
|
||||
shape = SubResource("8")
|
||||
|
||||
[node name="Weapon" type="MeshInstance3D" parent="HiddenObjectsItems" index="4"]
|
||||
[node name="Weapon" type="MeshInstance3D" parent="HiddenObjectsItems" index="4" unique_id=2061065249]
|
||||
transform = Transform3D(0.540284, -0.813497, 0.215212, -0.009216, 0.250018, 0.968198, -0.841432, -0.525085, 0.127583, -2.7508, -0.359206, 1.19589)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("7")
|
||||
surface_material_override/0 = ExtResource("8")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Weapon" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Weapon" index="0" unique_id=1267533074]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeWeapon" type="CollisionShape3D" parent="HiddenObjectsItems/Weapon/Area3D" index="0"]
|
||||
[node name="CollisionShapeWeapon" type="CollisionShape3D" parent="HiddenObjectsItems/Weapon/Area3D" index="0" unique_id=760867605]
|
||||
transform = Transform3D(-1.49012e-07, 0, 1, -1, -1.49012e-08, 0, 3.72529e-08, -1, -5.21541e-08, 0.0388942, 0.0484145, -8.19564e-08)
|
||||
shape = SubResource("9")
|
||||
|
||||
[node name="Apples" type="Node3D" parent="HiddenObjectsItems" index="5"]
|
||||
[node name="Apples" type="Node3D" parent="HiddenObjectsItems" index="5" unique_id=1941061793]
|
||||
|
||||
[node name="Apple1" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="0"]
|
||||
[node name="Apple1" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="0" unique_id=1622857820]
|
||||
transform = Transform3D(0.849809, -0.0462348, 0.525058, 0.0744364, 0.996689, -0.0327109, -0.521807, 0.0668814, 0.850438, -2.20275, -0.0779731, 2.45146)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("4")
|
||||
surface_material_override/0 = ExtResource("15")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple1" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple1" index="0" unique_id=1928212459]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeApple" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple1/Area3D" index="0"]
|
||||
[node name="CollisionShapeApple" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple1/Area3D" index="0" unique_id=1262510568]
|
||||
transform = Transform3D(-1.45286e-07, -2.98023e-08, 1, -1, -1.11759e-08, 0, 1.86265e-08, -1, -8.9407e-08, -1.90735e-06, 0.00575864, 0)
|
||||
shape = SubResource("10")
|
||||
|
||||
[node name="Apple2" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="1"]
|
||||
[node name="Apple2" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="1" unique_id=1376103767]
|
||||
transform = Transform3D(-0.190449, 0, 0.981697, 0, 1, 0, -0.981697, 0, -0.190449, -1.71166, -0.0869397, -1.29534)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("4")
|
||||
surface_material_override/0 = ExtResource("9")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple2" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple2" index="0" unique_id=1312476035]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeApple2" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple2/Area3D" index="0"]
|
||||
[node name="CollisionShapeApple2" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple2/Area3D" index="0" unique_id=560389459]
|
||||
transform = Transform3D(-1.49012e-07, 4.47035e-08, 1, -1, -1.49012e-08, 0, 3.72529e-08, -1, -1.49012e-08, -4.76837e-07, -0.00566041, 0)
|
||||
shape = SubResource("11")
|
||||
|
||||
[node name="Apple3" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="2"]
|
||||
[node name="Apple3" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="2" unique_id=4711947]
|
||||
transform = Transform3D(0.823731, 0.226496, -0.519776, -0.248954, 0.96813, 0.0273319, 0.509401, 0.106886, 0.853865, -0.718663, -0.36046, 1.92043)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("4")
|
||||
surface_material_override/0 = ExtResource("20")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple3" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple3" index="0" unique_id=1159697360]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeApple3" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple3/Area3D" index="0"]
|
||||
[node name="CollisionShapeApple3" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple3/Area3D" index="0" unique_id=189019927]
|
||||
transform = Transform3D(-1.71363e-07, 0, 1, -1, -3.72529e-08, 1.49012e-08, 2.98023e-08, -1, -1.19209e-07, -3.57628e-07, 0.0142345, 2.38419e-07)
|
||||
shape = SubResource("12")
|
||||
|
||||
[node name="Apple4" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="3"]
|
||||
[node name="Apple4" type="MeshInstance3D" parent="HiddenObjectsItems/Apples" index="3" unique_id=271256083]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -4.38775, -0.940515, 0.233058)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("4")
|
||||
surface_material_override/0 = ExtResource("10")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple4" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Apples/Apple4" index="0" unique_id=650841676]
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeApple4" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple4/Area3D" index="0"]
|
||||
[node name="CollisionShapeApple4" type="CollisionShape3D" parent="HiddenObjectsItems/Apples/Apple4/Area3D" index="0" unique_id=2006844477]
|
||||
transform = Transform3D(-1.49012e-07, 0, 1, -1, -1.49012e-08, 0, 3.72529e-08, -1, -5.21541e-08, -4.76837e-07, 0.00115258, -1.17347e-07)
|
||||
shape = SubResource("13")
|
||||
|
||||
[node name="Coins" type="Node3D" parent="HiddenObjectsItems" index="6"]
|
||||
[node name="Coins" type="Node3D" parent="HiddenObjectsItems" index="6" unique_id=1225184523]
|
||||
|
||||
[node name="Coin1" type="MeshInstance3D" parent="HiddenObjectsItems/Coins" index="0"]
|
||||
[node name="Coin1" type="MeshInstance3D" parent="HiddenObjectsItems/Coins" index="0" unique_id=433511801]
|
||||
transform = Transform3D(-0.958704, -0.0851446, 0.271362, -0.0825332, 0.996367, 0.0210433, -0.272167, -0.00222202, -0.962248, 0.215021, 0.00178671, 0.520763)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("2")
|
||||
surface_material_override/0 = ExtResource("18")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Coins/Coin1" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Coins/Coin1" index="0" unique_id=559620821]
|
||||
transform = Transform3D(1, -4.65661e-09, 0, 2.68919e-08, 1, 4.65661e-10, -1.19209e-07, -1.14087e-08, 1, -0.0781975, -0.0532835, -0.0615574)
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeGold1" type="CollisionShape3D" parent="HiddenObjectsItems/Coins/Coin1/Area3D" index="0"]
|
||||
[node name="CollisionShapeGold1" type="CollisionShape3D" parent="HiddenObjectsItems/Coins/Coin1/Area3D" index="0" unique_id=1553751010]
|
||||
transform = Transform3D(1, -4.65661e-08, 0, -1.38185e-07, 0.999999, 3.14321e-08, 4.17233e-07, -4.19095e-09, 1, 0.0276761, 0.00212932, 0.0336302)
|
||||
shape = SubResource("14")
|
||||
|
||||
[node name="Coin2" type="MeshInstance3D" parent="HiddenObjectsItems/Coins" index="1"]
|
||||
[node name="Coin2" type="MeshInstance3D" parent="HiddenObjectsItems/Coins" index="1" unique_id=53639517]
|
||||
transform = Transform3D(0.250245, 2.79397e-09, -0.968183, 0.0456076, 0.99889, 0.0117882, 0.967108, -0.0471065, 0.249967, 0.752443, -0.000386238, 1.36745)
|
||||
layers = 3
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("2")
|
||||
surface_material_override/0 = ExtResource("16")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Coins/Coin2" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Coins/Coin2" index="0" unique_id=1112277990]
|
||||
transform = Transform3D(1, -1.49012e-08, 0, 0, 1, 9.31323e-10, 1.49012e-08, -3.72529e-09, 1, -0.0553267, -0.0679173, -0.0739018)
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeGold2" type="CollisionShape3D" parent="HiddenObjectsItems/Coins/Coin2/Area3D" index="0"]
|
||||
[node name="CollisionShapeGold2" type="CollisionShape3D" parent="HiddenObjectsItems/Coins/Coin2/Area3D" index="0" unique_id=71907372]
|
||||
transform = Transform3D(1, 0, 2.98023e-08, 7.45058e-09, 1, -9.31323e-10, 5.96046e-08, 0, 1, 0.0499306, 1.19209e-07, 0.0191208)
|
||||
shape = SubResource("15")
|
||||
|
||||
[node name="Coin3" type="MeshInstance3D" parent="HiddenObjectsItems/Coins" index="2"]
|
||||
[node name="Coin3" type="MeshInstance3D" parent="HiddenObjectsItems/Coins" index="2" unique_id=549331432]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -4.74641, -0.885448, -0.198129)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("2")
|
||||
surface_material_override/0 = ExtResource("6")
|
||||
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Coins/Coin3" index="0"]
|
||||
[node name="Area3D" type="Area3D" parent="HiddenObjectsItems/Coins/Coin3" index="0" unique_id=24543742]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.0744205, -0.0795707, -0.040606)
|
||||
collision_mask = 2
|
||||
|
||||
[node name="CollisionShapeGold3" type="CollisionShape3D" parent="HiddenObjectsItems/Coins/Coin3/Area3D" index="0"]
|
||||
[node name="CollisionShapeGold3" type="CollisionShape3D" parent="HiddenObjectsItems/Coins/Coin3/Area3D" index="0" unique_id=1711381155]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.0358186, 0, 0.0109152)
|
||||
shape = SubResource("16")
|
||||
|
||||
[node name="MainSceneProps" type="Node3D" parent="." index="6"]
|
||||
[node name="MainSceneProps" type="Node3D" parent="." index="6" unique_id=2115846529]
|
||||
|
||||
[node name="sm_book" parent="MainSceneProps" index="0" instance=ExtResource("33")]
|
||||
[node name="sm_book" parent="MainSceneProps" index="0" unique_id=1510532816 instance=ExtResource("33")]
|
||||
transform = Transform3D(0.259561, 0, 0.965727, 0.0582327, 0.99818, -0.0156514, -0.963969, 0.0602995, 0.259089, 0.13025, 0.960907, -0.456389)
|
||||
|
||||
[node name="sm_book2" parent="MainSceneProps/sm_book" index="1" instance=ExtResource("33")]
|
||||
[node name="sm_book2" parent="MainSceneProps/sm_book" index="1" unique_id=1854901352 instance=ExtResource("33")]
|
||||
transform = Transform3D(0.0229641, -0.00339183, -0.999731, 0.0393653, 0.999223, -0.00248598, 0.998961, -0.0392976, 0.0230803, 0.00279957, 0.066205, -0.000443451)
|
||||
|
||||
[node name="sm_book3" parent="MainSceneProps/sm_book/sm_book2" index="1" instance=ExtResource("33")]
|
||||
[node name="sm_book3" parent="MainSceneProps/sm_book/sm_book2" index="1" unique_id=1012481615 instance=ExtResource("33")]
|
||||
transform = Transform3D(0.86032, -0.0497817, -0.507318, 0.0471006, 0.998725, -0.0181282, 0.507573, -0.00829895, 0.861568, 0.00110056, 0.070618, -0.00503528)
|
||||
|
||||
[node name="sm_candlestick" parent="MainSceneProps/sm_book/sm_book2/sm_book3" index="1" instance=ExtResource("29")]
|
||||
[node name="sm_candlestick" parent="MainSceneProps/sm_book/sm_book2/sm_book3" index="1" unique_id=587981133 instance=ExtResource("29")]
|
||||
transform = Transform3D(1.0543, -0.0109484, 1.03432, -0.0329634, 1.4758, 0.0492217, -1.03385, -0.0582193, 1.05321, 0.0299356, 0.0326169, -0.0690778)
|
||||
|
||||
[node name="sm_table" parent="MainSceneProps" index="1" instance=ExtResource("28")]
|
||||
[node name="sm_table" parent="MainSceneProps" index="1" unique_id=1346910313 instance=ExtResource("28")]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.0926853, 0.0400838, 0.290515)
|
||||
|
||||
[node name="sm_stool_b" parent="MainSceneProps" index="2" instance=ExtResource("31")]
|
||||
[node name="sm_stool_b" parent="MainSceneProps" index="2" unique_id=1159250399 instance=ExtResource("31")]
|
||||
transform = Transform3D(-0.232037, 0, -0.972707, 0, 1, 0, 0.972707, 0, -0.232037, -2.91873, 0.0130518, 0.702275)
|
||||
|
||||
[node name="sm_stool_b2" parent="MainSceneProps" index="3" instance=ExtResource("31")]
|
||||
[node name="sm_stool_b2" parent="MainSceneProps" index="3" unique_id=1510866957 instance=ExtResource("31")]
|
||||
transform = Transform3D(0.769693, -0.034908, -0.637459, 0.0288114, 0.999386, -0.0199395, 0.637764, -0.00301879, 0.770226, -4.33166, 0.0231258, 1.08363)
|
||||
|
||||
[node name="sm_stool_b3" parent="MainSceneProps" index="4" instance=ExtResource("31")]
|
||||
[node name="sm_stool_b3" parent="MainSceneProps" index="4" unique_id=509124392 instance=ExtResource("31")]
|
||||
transform = Transform3D(0.98104, 0, 0.193806, 0, 1, 0, -0.193806, 0, 0.98104, -3.04076, 0.0372323, -0.817556)
|
||||
|
||||
[node name="sm_stool_b7" parent="MainSceneProps" index="5" instance=ExtResource("31")]
|
||||
[node name="sm_stool_b7" parent="MainSceneProps" index="5" unique_id=1148217742 instance=ExtResource("31")]
|
||||
transform = Transform3D(0.656257, 0, 0.754538, 0, 1, 0, -0.754538, 0, 0.656257, -0.888955, 0.0130518, 1.64328)
|
||||
|
||||
[node name="sm_stool_b4" parent="MainSceneProps" index="6" instance=ExtResource("31")]
|
||||
[node name="sm_stool_b4" parent="MainSceneProps" index="6" unique_id=1444546572 instance=ExtResource("31")]
|
||||
transform = Transform3D(0.892389, 0, -0.451267, 0, 1, 0, 0.451267, 0, 0.892389, 1.35966, 0.013052, 1.23435)
|
||||
|
||||
[node name="sm_stool_b5" parent="MainSceneProps" index="7" instance=ExtResource("31")]
|
||||
[node name="sm_stool_b5" parent="MainSceneProps" index="7" unique_id=86068654 instance=ExtResource("31")]
|
||||
transform = Transform3D(0.839193, 0, 0.543834, 0, 1, 0, -0.543834, 0, 0.839193, 0.474083, 0.013052, -1.39025)
|
||||
|
||||
[node name="sm_book2" parent="MainSceneProps" index="8" instance=ExtResource("33")]
|
||||
[node name="sm_book2" parent="MainSceneProps" index="8" unique_id=1588522519 instance=ExtResource("33")]
|
||||
transform = Transform3D(0.122577, 0.0288089, -0.992041, -0.0361233, 0.999045, 0.0245489, 0.991801, 0.0328267, 0.1235, 0.493202, 0.942654, -0.0854386)
|
||||
|
||||
[node name="sm_book3" parent="MainSceneProps" index="9" instance=ExtResource("33")]
|
||||
[node name="sm_book3" parent="MainSceneProps" index="9" unique_id=870021440 instance=ExtResource("33")]
|
||||
transform = Transform3D(0.5, 0, 0.866025, 0, 1, 0, -0.866025, 0, 0.5, 0.0106606, 0.96499, 0.981535)
|
||||
|
||||
[node name="sm_book" parent="MainSceneProps/sm_book3" index="1" instance=ExtResource("33")]
|
||||
[node name="sm_book" parent="MainSceneProps/sm_book3" index="1" unique_id=745945160 instance=ExtResource("33")]
|
||||
transform = Transform3D(0.992026, 0, 0.592682, 0, 1.15559, 0, -0.592682, 0, 0.992026, -0.000832617, 0.0791223, -0.012241)
|
||||
|
||||
[node name="sm_godet" parent="MainSceneProps" index="10" instance=ExtResource("32")]
|
||||
[node name="sm_godet" parent="MainSceneProps" index="10" unique_id=1451124813 instance=ExtResource("32")]
|
||||
transform = Transform3D(0.875311, 0.480987, 0.0498184, 0.0206958, 0.0656668, -0.997627, -0.483117, 0.874265, 0.0475244, -0.191043, 0.95253, 0.11484)
|
||||
|
||||
[node name="sm_godet2" parent="MainSceneProps" index="11" instance=ExtResource("32")]
|
||||
[node name="sm_godet2" parent="MainSceneProps" index="11" unique_id=2118296060 instance=ExtResource("32")]
|
||||
transform = Transform3D(0.706057, 0, -0.708155, 0, 1, 0, 0.708155, 0, 0.706057, -0.112722, 0.901657, 0.00149509)
|
||||
|
||||
[node name="sm_godet6" parent="MainSceneProps" index="12" instance=ExtResource("32")]
|
||||
[node name="sm_godet6" parent="MainSceneProps" index="12" unique_id=1358866642 instance=ExtResource("32")]
|
||||
transform = Transform3D(0.757895, 0, 0.652376, 0, 1, 0, -0.652376, 0, 0.757895, -0.28474, 0.905096, 0.78228)
|
||||
|
||||
[node name="sm_godet5" parent="MainSceneProps" index="13" instance=ExtResource("32")]
|
||||
[node name="sm_godet5" parent="MainSceneProps" index="13" unique_id=1953501969 instance=ExtResource("32")]
|
||||
transform = Transform3D(0.886172, -0.463214, 0.0114893, -0.0309068, -0.0343508, 0.998932, -0.462324, -0.885581, -0.0447572, -0.0861932, 0.982616, 0.742759)
|
||||
|
||||
[node name="sm_godet4" parent="MainSceneProps" index="14" instance=ExtResource("32")]
|
||||
[node name="sm_godet4" parent="MainSceneProps" index="14" unique_id=834937130 instance=ExtResource("32")]
|
||||
transform = Transform3D(0.690251, 0, 0.72357, 0, 1, 0, -0.72357, 0, 0.690251, -0.333186, 0.901657, 0.177792)
|
||||
|
||||
[node name="sm_growler" parent="MainSceneProps" index="15" instance=ExtResource("34")]
|
||||
[node name="sm_growler" parent="MainSceneProps" index="15" unique_id=184052561 instance=ExtResource("34")]
|
||||
transform = Transform3D(0.0876426, 0, -0.996152, 0, 1, 0, 0.996152, 0, 0.0876426, -0.316595, 0.905106, -0.0726386)
|
||||
|
||||
[node name="Parchment" parent="MainSceneProps" index="16" instance=ExtResource("30")]
|
||||
[node name="Parchment" parent="MainSceneProps" index="16" unique_id=2051903541 instance=ExtResource("30")]
|
||||
transform = Transform3D(0.796076, 0.00917861, -0.605127, 0, 0.999885, 0.0151663, 0.605197, -0.0120736, 0.795984, 0.543303, 0.962739, 0.755265)
|
||||
paper = true
|
||||
|
||||
[node name="ParchmentWithoutPaper" parent="MainSceneProps" index="17" instance=ExtResource("30")]
|
||||
[node name="ParchmentWithoutPaper" parent="MainSceneProps" index="17" unique_id=2106537160 instance=ExtResource("30")]
|
||||
transform = Transform3D(-0.596381, 0.0184557, 0.802489, 0.0225364, 0.999726, -0.00624354, -0.802385, 0.0143617, -0.596634, 0.281044, 0.958449, -0.253034)
|
||||
|
||||
[node name="sm_candle_d2" type="MeshInstance3D" parent="MainSceneProps" index="18"]
|
||||
[node name="sm_candle_d2" type="MeshInstance3D" parent="MainSceneProps" index="18" unique_id=572897683]
|
||||
transform = Transform3D(-0.927966, 1.10978e-07, -0.372664, 6.91459e-08, 1, 1.25617e-07, 0.372664, 9.08001e-08, -0.927966, 0.457262, 1.00485, -0.058084)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("25")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="sm_candle_top2" type="MeshInstance3D" parent="MainSceneProps" index="19"]
|
||||
[node name="sm_candle_top2" type="MeshInstance3D" parent="MainSceneProps" index="19" unique_id=1743924627]
|
||||
transform = Transform3D(2.94906, 0, 0, 0, 2.85, 0, 0, 0, 2.94906, 0.347704, 1.00342, 1.16015)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("26")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="sm_candle_b" type="MeshInstance3D" parent="MainSceneProps/sm_candle_top2" index="0"]
|
||||
[node name="sm_candle_b" type="MeshInstance3D" parent="MainSceneProps/sm_candle_top2" index="0" unique_id=728142810]
|
||||
transform = Transform3D(0.553417, 0, 0, 0, 0.553417, 0, 0, 0, 0.553417, 0.0504003, -0.0129334, 0.00162044)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("27")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="Tableleft" parent="." index="7" instance=ExtResource("28")]
|
||||
[node name="Tableleft" parent="." index="7" unique_id=1890270555 instance=ExtResource("28")]
|
||||
transform = Transform3D(-0.958482, 0, -0.285153, 0, 1, 0, 0.285153, 0, -0.958482, -2.60247, 0.0491341, 2.15903)
|
||||
|
||||
[node name="sm_growler" parent="Tableleft" index="1" instance=ExtResource("34")]
|
||||
[node name="sm_growler" parent="Tableleft" index="1" unique_id=391479572 instance=ExtResource("34")]
|
||||
transform = Transform3D(-0.958482, 0, 0.285153, 0, 1, 0, -0.285153, 0, -0.958482, 0.179069, 0.843493, 2.38419e-07)
|
||||
|
||||
[node name="sm_godet" parent="Tableleft" index="2" instance=ExtResource("32")]
|
||||
[node name="sm_godet" parent="Tableleft" index="2" unique_id=1409624650 instance=ExtResource("32")]
|
||||
transform = Transform3D(-0.958482, 0.0116327, 0.284916, 0, 0.999168, -0.0407945, -0.285153, -0.0391008, -0.957684, 0.00578856, 0.850618, 0.189056)
|
||||
|
||||
[node name="sm_godet2" parent="Tableleft" index="3" instance=ExtResource("32")]
|
||||
[node name="sm_godet2" parent="Tableleft" index="3" unique_id=2026873366 instance=ExtResource("32")]
|
||||
transform = Transform3D(-0.958482, -0.0136413, 0.284827, 0, 0.998855, 0.0478387, -0.285153, 0.0458525, -0.957385, 0.102124, 0.837641, -0.25378)
|
||||
|
||||
[node name="TableRight" parent="." index="8" instance=ExtResource("28")]
|
||||
[node name="TableRight" parent="." index="8" unique_id=1886475024 instance=ExtResource("28")]
|
||||
transform = Transform3D(0.707107, 0, -0.707107, 0, 1, 0, 0.707107, 0, 0.707107, -2.1664, 0.0295653, -2.02667)
|
||||
|
||||
[node name="Growler" parent="TableRight" index="1" instance=ExtResource("34")]
|
||||
[node name="Growler" parent="TableRight" index="1" unique_id=2119298594 instance=ExtResource("34")]
|
||||
transform = Transform3D(0.428226, 0, -0.903672, 0, 1, 0, 0.903672, 0, 0.428226, 0.260903, 0.870654, 0.24329)
|
||||
|
||||
[node name="Godet" parent="TableRight" index="2" instance=ExtResource("32")]
|
||||
[node name="Godet" parent="TableRight" index="2" unique_id=1561743702 instance=ExtResource("32")]
|
||||
transform = Transform3D(0.869771, 0, 0.493456, 0, 1, 0, -0.493456, 0, 0.869771, 0.124432, 0.85553, -0.0287701)
|
||||
|
||||
[node name="Godet3" parent="TableRight" index="3" instance=ExtResource("32")]
|
||||
[node name="Godet3" parent="TableRight" index="3" unique_id=1882592562 instance=ExtResource("32")]
|
||||
transform = Transform3D(0.979508, 0.200153, 0.0224678, -0.0198889, -0.0148863, 0.999692, 0.200426, -0.979652, -0.0106004, 0.511135, 0.919194, 0.249402)
|
||||
|
||||
[node name="Godet4" parent="TableRight" index="4" instance=ExtResource("32")]
|
||||
[node name="Godet4" parent="TableRight" index="4" unique_id=1004208616 instance=ExtResource("32")]
|
||||
transform = Transform3D(-0.236782, -0.0445638, 0.970541, -0.0267146, 0.998868, 0.039347, -0.971196, -0.0166109, -0.237705, 0.291596, 0.864092, -0.00375021)
|
||||
|
||||
[node name="Building" type="Node3D" parent="." index="9"]
|
||||
[node name="Building" type="Node3D" parent="." index="9" unique_id=1130916952]
|
||||
|
||||
[node name="walls" type="Node3D" parent="Building" index="0"]
|
||||
[node name="walls" type="Node3D" parent="Building" index="0" unique_id=1931637314]
|
||||
|
||||
[node name="wall_left" type="MeshInstance3D" parent="Building/walls" index="0"]
|
||||
[node name="wall_left" type="MeshInstance3D" parent="Building/walls" index="0" unique_id=1657524276]
|
||||
transform = Transform3D(17.6823, 0, 0, 0, -2.06229e-06, 7.98594, 0, -6.6644, -4.9309e-08, -3.48147, 2.21218, 4.82163)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("36")
|
||||
surface_material_override/0 = ExtResource("39")
|
||||
|
||||
[node name="wall_roof" type="MeshInstance3D" parent="Building/walls" index="1"]
|
||||
[node name="wall_roof" type="MeshInstance3D" parent="Building/walls" index="1" unique_id=874282409]
|
||||
transform = Transform3D(19.0333, 0, 0, 0, -2.05553, -1.80384e-05, 0, 1.78061e-06, -20.8236, -3.43417, 4.19346, -0.500263)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("36")
|
||||
surface_material_override/0 = ExtResource("39")
|
||||
|
||||
[node name="wall_right" type="MeshInstance3D" parent="Building/walls" index="2"]
|
||||
[node name="wall_right" type="MeshInstance3D" parent="Building/walls" index="2" unique_id=1374518962]
|
||||
transform = Transform3D(-6.12822, -1.14249, -5.98427e-08, 0, -2.8759e-07, 7.88397, -1.08057, 6.47934, 3.39384e-07, -0.343511, 2.21218, -5.27151)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("36")
|
||||
surface_material_override/0 = ExtResource("39")
|
||||
|
||||
[node name="wall_right2" type="MeshInstance3D" parent="Building/walls" index="3"]
|
||||
[node name="wall_right2" type="MeshInstance3D" parent="Building/walls" index="3" unique_id=1293622976]
|
||||
transform = Transform3D(-6.12822, -1.14249, -5.98427e-08, 0, -2.8759e-07, 7.88397, -1.08057, 6.47934, 3.39384e-07, -5.52464, 2.21218, -6.18509)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("36")
|
||||
surface_material_override/0 = ExtResource("39")
|
||||
|
||||
[node name="wall_background" type="MeshInstance3D" parent="Building/walls" index="4"]
|
||||
[node name="wall_background" type="MeshInstance3D" parent="Building/walls" index="4" unique_id=267282421]
|
||||
transform = Transform3D(-3.92366, 6.98897, 3.66077e-07, 0, -3.1021e-07, 8.50407, 22.2522, 1.23234, 6.45493e-08, -7.48147, 2.21218, -0.975186)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("36")
|
||||
surface_material_override/0 = ExtResource("39")
|
||||
|
||||
[node name="GridMapFloor" type="GridMap" parent="Building" index="1"]
|
||||
[node name="GridMapFloor" type="GridMap" parent="Building" index="1" unique_id=1860847202]
|
||||
mesh_library = ExtResource("37")
|
||||
use_in_baked_light = true
|
||||
cell_center_y = false
|
||||
cell_center_z = false
|
||||
baked_meshes = [SubResource("17")]
|
||||
data = {
|
||||
"cells": PackedInt32Array(0, 0, 536870912, 65531, 0, 536870915, 65532, 0, 536870912, 65533, 0, 1073741824, 65534, 0, 0, 65535, 0, 0, 0, 1, 536870912, 65531, 1, 536870915, 65532, 1, 0, 65533, 1, 536870912, 65534, 1, 536870912, 65535, 1, 0, 0, 2, 536870912, 65531, 2, 536870915, 65532, 2, 536870912, 65533, 2, 536870912, 65534, 2, 0, 65535, 2, 0, 0, 65533, 0, 65532, 65533, 0, 65533, 65533, 536870912, 65534, 65533, 0, 65535, 65533, 536870912, 0, 65534, 0, 65531, 65534, 3, 65532, 65534, 536870912, 65533, 65534, 536870912, 65534, 65534, 536870912, 65535, 65534, 536870912, 0, 65535, 536870912, 65531, 65535, 536870915, 65532, 65535, 0, 65533, 65535, 1073741824, 65534, 65535, 1073741824, 65535, 65535, 1073741824)
|
||||
}
|
||||
__meta__ = {
|
||||
"_editor_clip_": 0,
|
||||
"_editor_floor_": Vector3(0, 0, 0)
|
||||
"cells": PackedInt32Array(0, 0, 0, 65531, 0, 3, 65532, 0, 0, 65533, 0, 0, 65534, 0, 0, 65535, 0, 0, 0, 1, 0, 65531, 1, 3, 65532, 1, 0, 65533, 1, 0, 65534, 1, 0, 65535, 1, 0, 0, 2, 0, 65531, 2, 3, 65532, 2, 0, 65533, 2, 0, 65534, 2, 0, 65535, 2, 0, 0, 65533, 0, 65532, 65533, 0, 65533, 65533, 0, 65534, 65533, 0, 65535, 65533, 0, 0, 65534, 0, 65531, 65534, 3, 65532, 65534, 0, 65533, 65534, 0, 65534, 65534, 0, 65535, 65534, 0, 0, 65535, 0, 65531, 65535, 3, 65532, 65535, 0, 65533, 65535, 0, 65534, 65535, 0, 65535, 65535, 0)
|
||||
}
|
||||
|
||||
[node name="sm_column" type="MeshInstance3D" parent="Building" index="2"]
|
||||
[node name="sm_column" type="MeshInstance3D" parent="Building" index="2" unique_id=812902144]
|
||||
transform = Transform3D(0.173648, 0, 0.984808, 0, 1, 0, -0.984808, 0, 0.173648, -6.41226, 0, -3.39909)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("35")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="sm_column2" type="MeshInstance3D" parent="Building" index="3"]
|
||||
[node name="sm_column2" type="MeshInstance3D" parent="Building" index="3" unique_id=386923556]
|
||||
transform = Transform3D(0.173648, 0, 0.984808, 0, 1, 0, -0.984808, 0, 0.173648, -7.23782, 0, 1.51736)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("35")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="sm_column3" type="MeshInstance3D" parent="Building" index="4"]
|
||||
[node name="sm_column3" type="MeshInstance3D" parent="Building" index="4" unique_id=1628736415]
|
||||
transform = Transform3D(0.173648, 0, 0.984808, 0, 1, 0, -0.984808, 0, 0.173648, -7.73765, 0, 4.20657)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("35")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="sm_column4" type="MeshInstance3D" parent="Building" index="5"]
|
||||
[node name="sm_column4" type="MeshInstance3D" parent="Building" index="5" unique_id=480527079]
|
||||
transform = Transform3D(0.173648, 0, 0.984808, 0, 1, 0, -0.984808, 0, 0.173648, -5.90352, 0, -6.13626)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("35")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="sm_fireplace" type="MeshInstance3D" parent="Building" index="6"]
|
||||
[node name="sm_fireplace" type="MeshInstance3D" parent="Building" index="6" unique_id=544928378]
|
||||
transform = Transform3D(0.173648, 0, 0.984808, 0, 1, 0, -0.984808, 0, 0.173648, -7.17176, -2.38419e-07, -1.02066)
|
||||
use_in_baked_light = true
|
||||
mesh = ExtResource("38")
|
||||
surface_material_override/0 = null
|
||||
|
||||
[node name="FireplaceLight" type="OmniLight3D" parent="Building/sm_fireplace" index="0"]
|
||||
[node name="FireplaceLight" type="OmniLight3D" parent="Building/sm_fireplace" index="0" unique_id=848691682]
|
||||
transform = Transform3D(0.173304, -0.0109248, -0.984808, 0.0629123, 0.998019, -1.78701e-07, 0.982857, -0.0619565, 0.173648, 0.00967455, 0.654315, 0.510273)
|
||||
visible = false
|
||||
light_color = Color(0.960784, 0.611765, 0.00784314, 1)
|
||||
light_energy = 1.4
|
||||
light_indirect_energy = 1.4
|
||||
light_bake_mode = 2
|
||||
shadow_enabled = true
|
||||
editor_only = true
|
||||
omni_range = 1.8
|
||||
omni_attenuation = 1.23114
|
||||
|
||||
[node name="Lighting" type="Node3D" parent="." index="10"]
|
||||
[node name="Lighting" type="Node3D" parent="." index="10" unique_id=1285725286]
|
||||
|
||||
[node name="Red Color Left" type="SpotLight3D" parent="Lighting" index="0"]
|
||||
[node name="Red Color Left" type="SpotLight3D" parent="Lighting" index="0" unique_id=1225515490]
|
||||
transform = Transform3D(0.949107, 0.151161, -0.276307, 0, 0.877297, 0.479948, 0.314953, -0.455522, 0.832649, -4.0515, 2.45338, 4.26157)
|
||||
visible = false
|
||||
light_color = Color(0.643137, 0.109804, 0.152941, 1)
|
||||
light_energy = 11.3
|
||||
light_specular = 1.0
|
||||
light_bake_mode = 2
|
||||
shadow_enabled = true
|
||||
shadow_bias = 0.1
|
||||
shadow_contact = 1.0
|
||||
editor_only = true
|
||||
spot_range = 5.43268
|
||||
spot_attenuation = 1.41421
|
||||
spot_angle = 31.2
|
||||
|
||||
[node name="Red Color Left2" type="SpotLight3D" parent="Lighting" index="1"]
|
||||
[node name="Red Color Left2" type="SpotLight3D" parent="Lighting" index="1" unique_id=546741258]
|
||||
transform = Transform3D(0.80562, 0.042778, 0.590886, -0.18969, 0.963507, 0.18887, -0.561244, -0.264243, 0.784335, 0.631187, 2.3448, 4.15934)
|
||||
visible = false
|
||||
light_color = Color(0.643137, 0.109804, 0.152941, 1)
|
||||
light_energy = 0.4
|
||||
light_bake_mode = 2
|
||||
shadow_enabled = true
|
||||
shadow_bias = 0.1
|
||||
shadow_contact = 1.0
|
||||
editor_only = true
|
||||
spot_range = 15.1
|
||||
spot_attenuation = 1.41
|
||||
|
||||
[node name="WorldEnvironment" type="WorldEnvironment" parent="Lighting" index="2"]
|
||||
[node name="WorldEnvironment" type="WorldEnvironment" parent="Lighting" index="2" unique_id=553282329]
|
||||
environment = SubResource("19")
|
||||
|
||||
[node name="Blue Color Right" type="SpotLight3D" parent="Lighting" index="3"]
|
||||
[node name="Blue Color Right" type="SpotLight3D" parent="Lighting" index="3" unique_id=245462134]
|
||||
transform = Transform3D(-0.994228, 0.0863279, -0.0637094, 0.0626716, 0.949248, 0.308222, 0.0870842, 0.302451, -0.949179, -4.00108, 2.13555, -5.73587)
|
||||
visible = false
|
||||
light_color = Color(0.501961, 0.529412, 1, 1)
|
||||
light_energy = 4.0
|
||||
light_bake_mode = 2
|
||||
shadow_enabled = true
|
||||
shadow_bias = 0.1
|
||||
editor_only = true
|
||||
@@ -612,19 +560,16 @@ spot_range = 7.07277
|
||||
spot_attenuation = 1.46409
|
||||
spot_angle = 29.7
|
||||
|
||||
[node name="Blue Color Right2" type="SpotLight3D" parent="Lighting" index="4"]
|
||||
[node name="Blue Color Right2" type="SpotLight3D" parent="Lighting" index="4" unique_id=303023451]
|
||||
transform = Transform3D(-0.596615, 0.0976924, 0.79656, 0.0626716, 0.995204, -0.0751143, -0.800077, 0.00510741, -0.599875, -0.159195, 1.47445, -4.78163)
|
||||
visible = false
|
||||
light_color = Color(0.501961, 0.529412, 1, 1)
|
||||
light_energy = 32.0
|
||||
light_bake_mode = 2
|
||||
shadow_enabled = true
|
||||
spot_range = 7.07277
|
||||
spot_attenuation = 1.86607
|
||||
spot_angle = 28.7038
|
||||
|
||||
[node name="LightmapGI" type="LightmapGI" parent="." index="11"]
|
||||
[node name="LightmapGI" type="LightmapGI" parent="." index="11" unique_id=1786787406]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -3.06928, 2.35676, -0.183365)
|
||||
extents = Vector3(6.50885, 3.63237, 10)
|
||||
bounces = 5
|
||||
environment_mode = 1
|
||||
|
||||
@@ -1,25 +1,21 @@
|
||||
[gd_resource type="Environment" load_steps=3 format=2]
|
||||
[gd_resource type="Environment" format=3 uid="uid://bpxo3nvua1i8r"]
|
||||
|
||||
[ext_resource path="res://assets/hdri/tx_night_place.hdr" type="Texture2D" id=1]
|
||||
|
||||
[sub_resource type="Sky" id=2]
|
||||
panorama = ExtResource( 1 )
|
||||
[sub_resource type="Sky" id="2"]
|
||||
|
||||
[resource]
|
||||
background_mode = 2
|
||||
sky = SubResource( 2 )
|
||||
background_color = Color( 0.188235, 0.133333, 0.133333, 1 )
|
||||
background_color = Color(0.188235, 0.133333, 0.133333, 1)
|
||||
background_energy_multiplier = 0.6
|
||||
ambient_light_color = Color( 0.694118, 0.168627, 0.67451, 1 )
|
||||
ambient_light_energy = 0.4
|
||||
sky = SubResource("2")
|
||||
ambient_light_color = Color(0.694118, 0.168627, 0.67451, 1)
|
||||
ambient_light_sky_contribution = 0.5
|
||||
tonemap_mode = 2
|
||||
glow_enabled = true
|
||||
fog_enabled = true
|
||||
fog_mode = 1
|
||||
fog_light_color = Color( 0.562167, 0.29, 1, 0.941176 )
|
||||
fog_light_color = Color(0.562167, 0.29, 1, 0.941176)
|
||||
fog_density = 1.0
|
||||
fog_height = 2.0
|
||||
fog_depth_curve = 1.10957
|
||||
fog_depth_begin = 0.0
|
||||
fog_depth_end = 60.0
|
||||
fog_depth_curve = 1.10957
|
||||
fog_height = 2.0
|
||||
tonemap_mode = 2
|
||||
ss_reflections_enabled = true
|
||||
glow_enabled = true
|
||||
|
||||
+134
-105
@@ -1,128 +1,157 @@
|
||||
extends Node
|
||||
|
||||
# Lightweight replacement for the godot_db_manager plugin (incompatible with
|
||||
# Godot 4). Keeps the ahog.json format used by the rest of the project and
|
||||
# exposes the same surface API the M* model classes expect:
|
||||
# Loads ahog.json once into typed Resource arrays:
|
||||
# Global.database.settings -> SettingsData
|
||||
# Global.database.levels -> Array[LevelEntry]
|
||||
# Global.database.scenes -> Array[SceneEntry]
|
||||
#
|
||||
# Global.database.get_table_by_name(name) -> Table
|
||||
# Global.database.save_db()
|
||||
# table.get_data_at_row_idx(row_id) -> [Cell, Cell, ...]
|
||||
# table.edit_data(prop_id, row_id, value)
|
||||
# table.m_rows_count
|
||||
# table.get_data_by_prop_name_and_data(prop_name, value) -> Array
|
||||
# table.get_dictionary_by_prop_name_and_data(prop_name, value) -> Array[Dict]
|
||||
# cell.get_data() -> String
|
||||
# save() round-trips back to the same JSON format so game progress
|
||||
# (per-scene lock state) persists across runs.
|
||||
|
||||
class Cell:
|
||||
var _value
|
||||
func _init(value):
|
||||
_value = value
|
||||
func get_data():
|
||||
return _value
|
||||
|
||||
class Table:
|
||||
var name: String
|
||||
var props: Array
|
||||
var data: Array
|
||||
var m_rows_count: int
|
||||
|
||||
func _init(table_dict: Dictionary):
|
||||
name = table_dict["table_name"]
|
||||
props = table_dict["props"]
|
||||
data = table_dict["data"]
|
||||
m_rows_count = data.size() / max(1, props.size())
|
||||
|
||||
func _col_count() -> int:
|
||||
return props.size()
|
||||
|
||||
func _find_prop_idx(prop_name: String) -> int:
|
||||
for i in range(props.size()):
|
||||
if props[i]["name"] == prop_name:
|
||||
return i
|
||||
return -1
|
||||
|
||||
func get_data_at_row_idx(row_idx: int) -> Array:
|
||||
var start = row_idx * _col_count()
|
||||
var cells = []
|
||||
for i in range(_col_count()):
|
||||
cells.append(Cell.new(data[start + i]))
|
||||
return cells
|
||||
|
||||
func edit_data(prop_id: int, row_id: int, value) -> void:
|
||||
data[row_id * _col_count() + prop_id] = str(value)
|
||||
|
||||
func get_data_by_prop_name_and_data(prop_name: String, value) -> Array:
|
||||
var prop_idx = _find_prop_idx(prop_name)
|
||||
var matches = []
|
||||
if prop_idx == -1:
|
||||
return matches
|
||||
for row in range(m_rows_count):
|
||||
if data[row * _col_count() + prop_idx] == str(value):
|
||||
matches.append(row)
|
||||
return matches
|
||||
|
||||
func get_dictionary_by_prop_name_and_data(prop_name: String, value) -> Array:
|
||||
var prop_idx = _find_prop_idx(prop_name)
|
||||
var results = []
|
||||
if prop_idx == -1:
|
||||
return results
|
||||
for row in range(m_rows_count):
|
||||
if data[row * _col_count() + prop_idx] == str(value):
|
||||
var d = {}
|
||||
for i in range(_col_count()):
|
||||
d[props[i]["name"]] = data[row * _col_count() + i]
|
||||
results.append(d)
|
||||
return results
|
||||
|
||||
func to_dict() -> Dictionary:
|
||||
return {
|
||||
"table_name": name,
|
||||
"props": props,
|
||||
"data": data,
|
||||
}
|
||||
|
||||
class DB:
|
||||
var version: String
|
||||
var db_name: String
|
||||
var tables: Dictionary = {}
|
||||
class DB extends RefCounted:
|
||||
var settings: SettingsData
|
||||
var levels: Array[LevelEntry] = []
|
||||
var scenes: Array[SceneEntry] = []
|
||||
var _path: String
|
||||
|
||||
func _init(path: String):
|
||||
const _SETTINGS_PROPS := [
|
||||
{"name": "langue", "type": "1", "auto_increment": "0"},
|
||||
{"name": "gyroscope", "type": "0", "auto_increment": "0"},
|
||||
{"name": "ambient_sound", "type": "0", "auto_increment": "0"},
|
||||
{"name": "resolution", "type": "3", "auto_increment": "0"},
|
||||
{"name": "fullscreen", "type": "0", "auto_increment": "0"},
|
||||
{"name": "version", "type": "0", "auto_increment": "0"},
|
||||
]
|
||||
const _LEVELS_PROPS := [
|
||||
{"name": "name", "type": "3", "auto_increment": "0"},
|
||||
{"name": "thumb", "type": "4", "auto_increment": "0"},
|
||||
]
|
||||
const _SCENES_PROPS := [
|
||||
{"name": "lock", "type": "0", "auto_increment": "0"},
|
||||
{"name": "label", "type": "3", "auto_increment": "0"},
|
||||
{"name": "key", "type": "3", "auto_increment": "0"},
|
||||
{"name": "level", "type": "table", "table_name": "levels", "auto_increment": "0"},
|
||||
{"name": "mesh", "type": "3", "auto_increment": "0"},
|
||||
{"name": "label_counter", "type": "1", "auto_increment": "0"},
|
||||
{"name": "counter", "type": "1", "auto_increment": "0"},
|
||||
]
|
||||
|
||||
func _init(path: String) -> void:
|
||||
_path = path
|
||||
var f = FileAccess.open(path, FileAccess.READ)
|
||||
var f := FileAccess.open(path, FileAccess.READ)
|
||||
if f == null:
|
||||
push_error("[Database] Cannot open " + path)
|
||||
return
|
||||
var raw = f.get_as_text()
|
||||
var doc = JSON.parse_string(f.get_as_text())
|
||||
f.close()
|
||||
var doc = JSON.parse_string(raw)
|
||||
if doc == null:
|
||||
if not (doc is Dictionary):
|
||||
push_error("[Database] Invalid JSON in " + path)
|
||||
return
|
||||
version = doc.get("GDDB_ver", "")
|
||||
db_name = doc.get("db_name", "")
|
||||
for t in doc.get("tables", []):
|
||||
var table = Table.new(t)
|
||||
tables[table.name] = table
|
||||
for table in doc.get("tables", []):
|
||||
match table.get("table_name", ""):
|
||||
"settings": settings = _load_settings(table.get("data", []))
|
||||
"levels": levels = _load_levels(table.get("data", []))
|
||||
"scenes": scenes = _load_scenes(table.get("data", []))
|
||||
|
||||
func get_table_by_name(name: String):
|
||||
return tables.get(name)
|
||||
func _load_settings(data: Array) -> SettingsData:
|
||||
var s := SettingsData.new()
|
||||
if data.size() >= 6:
|
||||
s.langue = int(data[0])
|
||||
s.gyroscope = bool(int(data[1]))
|
||||
s.ambient_sound = bool(int(data[2]))
|
||||
s.resolution = str(data[3])
|
||||
s.fullscreen = bool(int(data[4]))
|
||||
s.version = str(data[5])
|
||||
return s
|
||||
|
||||
func save_db() -> void:
|
||||
var doc = {
|
||||
"GDDB_ver": version,
|
||||
"db_name": db_name,
|
||||
"tables": [],
|
||||
func _load_levels(data: Array) -> Array[LevelEntry]:
|
||||
var result: Array[LevelEntry] = []
|
||||
const W := 2
|
||||
@warning_ignore("integer_division")
|
||||
for i in range(data.size() / W):
|
||||
var l := LevelEntry.new()
|
||||
l.index = i
|
||||
l.name = str(data[i * W + 0])
|
||||
l.thumb = str(data[i * W + 1])
|
||||
result.append(l)
|
||||
return result
|
||||
|
||||
func _load_scenes(data: Array) -> Array[SceneEntry]:
|
||||
var result: Array[SceneEntry] = []
|
||||
const W := 7
|
||||
@warning_ignore("integer_division")
|
||||
for i in range(data.size() / W):
|
||||
var s := SceneEntry.new()
|
||||
s.lock = bool(int(data[i * W + 0]))
|
||||
s.label = str(data[i * W + 1])
|
||||
s.key = str(data[i * W + 2])
|
||||
s.level = int(data[i * W + 3])
|
||||
s.mesh = str(data[i * W + 4])
|
||||
s.label_counter = str(data[i * W + 5])
|
||||
s.counter = int(data[i * W + 6])
|
||||
result.append(s)
|
||||
return result
|
||||
|
||||
func scenes_for_level(level_idx: int) -> Array[SceneEntry]:
|
||||
var result: Array[SceneEntry] = []
|
||||
for s in scenes:
|
||||
if s.level == level_idx:
|
||||
result.append(s)
|
||||
return result
|
||||
|
||||
func level_by_index(idx: int) -> LevelEntry:
|
||||
for l in levels:
|
||||
if l.index == idx:
|
||||
return l
|
||||
return null
|
||||
|
||||
func save() -> void:
|
||||
var doc := {
|
||||
"GDDB_ver": "2.0",
|
||||
"db_name": "ahog",
|
||||
"tables": [
|
||||
{"table_name": "settings", "props": _SETTINGS_PROPS, "data": _dump_settings()},
|
||||
{"table_name": "levels", "props": _LEVELS_PROPS, "data": _dump_levels()},
|
||||
{"table_name": "scenes", "props": _SCENES_PROPS, "data": _dump_scenes()},
|
||||
],
|
||||
}
|
||||
for tname in tables:
|
||||
doc["tables"].append(tables[tname].to_dict())
|
||||
var f = FileAccess.open(_path, FileAccess.WRITE)
|
||||
var f := FileAccess.open(_path, FileAccess.WRITE)
|
||||
if f == null:
|
||||
push_error("[Database] Cannot write " + _path)
|
||||
return
|
||||
f.store_string(JSON.stringify(doc))
|
||||
f.close()
|
||||
|
||||
func _dump_settings() -> Array:
|
||||
return [
|
||||
str(settings.langue),
|
||||
str(int(settings.gyroscope)),
|
||||
str(int(settings.ambient_sound)),
|
||||
settings.resolution,
|
||||
str(int(settings.fullscreen)),
|
||||
settings.version,
|
||||
]
|
||||
|
||||
func _dump_levels() -> Array:
|
||||
var out: Array = []
|
||||
for l in levels:
|
||||
out.append_array([l.name, l.thumb])
|
||||
return out
|
||||
|
||||
func _dump_scenes() -> Array:
|
||||
var out: Array = []
|
||||
for s in scenes:
|
||||
out.append_array([
|
||||
str(int(s.lock)),
|
||||
s.label,
|
||||
s.key,
|
||||
str(s.level),
|
||||
s.mesh,
|
||||
s.label_counter,
|
||||
str(s.counter),
|
||||
])
|
||||
return out
|
||||
|
||||
func initialize() -> DB:
|
||||
return DB.new(save_database_in())
|
||||
|
||||
@@ -141,8 +170,8 @@ func normal_path() -> String:
|
||||
func copy_database() -> void:
|
||||
if FileAccess.file_exists(android_path()):
|
||||
return
|
||||
var src = FileAccess.open(normal_path(), FileAccess.READ)
|
||||
var dst = FileAccess.open(android_path(), FileAccess.WRITE)
|
||||
var src := FileAccess.open(normal_path(), FileAccess.READ)
|
||||
var dst := FileAccess.open(android_path(), FileAccess.WRITE)
|
||||
dst.store_string(src.get_as_text())
|
||||
dst.close()
|
||||
src.close()
|
||||
|
||||
+23
-30
@@ -1,77 +1,70 @@
|
||||
extends Control
|
||||
|
||||
@onready var current_scene = null
|
||||
@onready var current_scene_int = null
|
||||
@onready var wait_frames = 1
|
||||
@onready var database = null
|
||||
@onready var loaded = false
|
||||
@onready var animation = Loading.get_node("AnimLoading")
|
||||
# Application root: async scene loading + reference to the loaded Database.
|
||||
|
||||
@onready var animation: AnimationPlayer = Loading.get_node("AnimLoading")
|
||||
|
||||
var current_scene: Node = null
|
||||
var current_scene_int: int = -1
|
||||
var wait_frames: int = 1
|
||||
var database: RefCounted = null
|
||||
var loaded: bool = false
|
||||
var _loading_path: String = ""
|
||||
|
||||
func _ready():
|
||||
func _ready() -> void:
|
||||
database = load("res://scripts/Database.gd").new().initialize()
|
||||
|
||||
_initialize_current_scene()
|
||||
_initialize_loading_scene()
|
||||
|
||||
func _initialize_loading_scene():
|
||||
func _initialize_loading_scene() -> void:
|
||||
animation.animation_started.connect(Event._loading_is_started)
|
||||
animation.animation_finished.connect(Event._loading_is_finished)
|
||||
|
||||
func goto_scene(path):
|
||||
print("[global#goto_scene] : load scene " + str(path))
|
||||
var err = ResourceLoader.load_threaded_request(path)
|
||||
func goto_scene(path: String) -> void:
|
||||
var err := ResourceLoader.load_threaded_request(path)
|
||||
if err != OK:
|
||||
print("Error loading ....")
|
||||
push_error("[Global] failed to start threaded load for " + path)
|
||||
return
|
||||
|
||||
_loading_path = path
|
||||
Loading.show()
|
||||
animation.play("BorderAnim")
|
||||
|
||||
set_process(true)
|
||||
current_scene.queue_free()
|
||||
wait_frames = 1
|
||||
Loading.get_node("LoadingBare/VBoxContainer/HBoxContainer/ProgressBar").set_max(1.0)
|
||||
|
||||
func _process(_delta):
|
||||
func _process(_delta: float) -> void:
|
||||
if _loading_path == "":
|
||||
set_process(false)
|
||||
return
|
||||
|
||||
if wait_frames > 0:
|
||||
wait_frames -= 1
|
||||
|
||||
if not loaded:
|
||||
return
|
||||
|
||||
var progress := []
|
||||
var status = ResourceLoader.load_threaded_get_status(_loading_path, progress)
|
||||
var progress: Array = []
|
||||
var status := ResourceLoader.load_threaded_get_status(_loading_path, progress)
|
||||
match status:
|
||||
ResourceLoader.THREAD_LOAD_IN_PROGRESS:
|
||||
_update_progress(progress[0] if progress.size() > 0 else 0.0)
|
||||
ResourceLoader.THREAD_LOAD_LOADED:
|
||||
_set_new_scene()
|
||||
ResourceLoader.THREAD_LOAD_FAILED, ResourceLoader.THREAD_LOAD_INVALID_RESOURCE:
|
||||
print("Error loading ....")
|
||||
push_error("[Global] failed to load " + _loading_path)
|
||||
_loading_path = ""
|
||||
|
||||
## PRIVATE
|
||||
func _initialize_current_scene():
|
||||
print("[global#_initialize_current_scene]")
|
||||
var root = get_tree().get_root()
|
||||
func _initialize_current_scene() -> void:
|
||||
var root := get_tree().get_root()
|
||||
current_scene = root.get_child(root.get_child_count() - 1)
|
||||
|
||||
if current_scene.name != "Main":
|
||||
get_node("/root/Loading").hide()
|
||||
Loading.hide()
|
||||
|
||||
func _update_progress(value: float):
|
||||
func _update_progress(value: float) -> void:
|
||||
Loading.visible = true
|
||||
Loading.get_node("LoadingBare/VBoxContainer/HBoxContainer/ProgressBar").set_value(value)
|
||||
|
||||
func _set_new_scene():
|
||||
var resource = ResourceLoader.load_threaded_get(_loading_path)
|
||||
func _set_new_scene() -> void:
|
||||
var resource: PackedScene = ResourceLoader.load_threaded_get(_loading_path)
|
||||
_loading_path = ""
|
||||
current_scene = resource.instantiate()
|
||||
get_node("/root").add_child(current_scene)
|
||||
|
||||
+44
-41
@@ -1,66 +1,69 @@
|
||||
extends Node
|
||||
|
||||
@onready var setting = load("res://db/MSetting.gd").new()
|
||||
# Reads / writes the SettingsData held by Global.database. Applies locale,
|
||||
# resolution, and fullscreen state on startup and on any setter call.
|
||||
|
||||
func _ready():
|
||||
func _ready() -> void:
|
||||
apply_language(translate_int_to_locale(get_setting_language()))
|
||||
apply_resolution()
|
||||
apply_fullscreen()
|
||||
|
||||
func apply_language(local):
|
||||
TranslationServer.set_locale(local)
|
||||
func apply_language(locale: String) -> void:
|
||||
TranslationServer.set_locale(locale)
|
||||
|
||||
func translate_int_to_locale(id):
|
||||
var lang = "en"
|
||||
func translate_int_to_locale(id: int) -> String:
|
||||
match id:
|
||||
0: return "en"
|
||||
1: return "fr"
|
||||
return "en"
|
||||
|
||||
if id == 0:
|
||||
lang = "en"
|
||||
func apply_resolution() -> void:
|
||||
var res := get_setting_resolution()
|
||||
get_window().content_scale_size = Vector2i(int(res[0]), int(res[1]))
|
||||
|
||||
if id == 1:
|
||||
lang = "fr"
|
||||
func apply_fullscreen() -> void:
|
||||
get_window().mode = Window.MODE_EXCLUSIVE_FULLSCREEN if get_setting_fullscreen() else Window.MODE_WINDOWED
|
||||
|
||||
return lang
|
||||
func _data() -> SettingsData:
|
||||
return Global.database.settings
|
||||
|
||||
func apply_resolution():
|
||||
var res = get_setting_resolution()
|
||||
var screen_size = Vector2i(int(res[0]), int(res[1]))
|
||||
get_window().content_scale_size = screen_size
|
||||
func get_setting_language() -> int:
|
||||
return _data().langue
|
||||
|
||||
func apply_fullscreen():
|
||||
get_window().mode = Window.MODE_EXCLUSIVE_FULLSCREEN if (get_setting_fullscreen()) else Window.MODE_WINDOWED
|
||||
|
||||
func get_setting_language():
|
||||
return setting.get_langue()
|
||||
|
||||
func set_setting_language(value):
|
||||
setting.set_langue(value)
|
||||
func set_setting_language(value: int) -> void:
|
||||
_data().langue = value
|
||||
Global.database.save()
|
||||
apply_language(translate_int_to_locale(value))
|
||||
|
||||
func get_setting_gyrosocpe():
|
||||
return setting.get_gyroscope()
|
||||
func get_setting_gyrosocpe() -> bool:
|
||||
return _data().gyroscope
|
||||
|
||||
func set_setting_gyroscope(value):
|
||||
setting.set_gyroscope(value)
|
||||
func set_setting_gyroscope(value: bool) -> void:
|
||||
_data().gyroscope = value
|
||||
Global.database.save()
|
||||
|
||||
func get_setting_ambient_sound():
|
||||
return setting.get_ambient_sound()
|
||||
func get_setting_ambient_sound() -> bool:
|
||||
return _data().ambient_sound
|
||||
|
||||
func set_setting_ambient_sound(value):
|
||||
setting.set_ambient_sound(value)
|
||||
func set_setting_ambient_sound(value: bool) -> void:
|
||||
_data().ambient_sound = value
|
||||
Global.database.save()
|
||||
|
||||
func get_setting_resolution():
|
||||
return setting.get_resolution()
|
||||
func get_setting_resolution() -> PackedStringArray:
|
||||
return _data().resolution_split()
|
||||
|
||||
func set_setting_resolution(value):
|
||||
setting.set_resolution(value)
|
||||
func set_setting_resolution(value: String) -> void:
|
||||
_data().resolution = value
|
||||
Global.database.save()
|
||||
apply_resolution()
|
||||
|
||||
func get_setting_fullscreen():
|
||||
return setting.get_fullscreen()
|
||||
func get_setting_fullscreen() -> bool:
|
||||
return _data().fullscreen
|
||||
|
||||
func set_setting_fullscreen(value):
|
||||
setting.set_fullscreen(value)
|
||||
func set_setting_fullscreen(value: bool) -> void:
|
||||
_data().fullscreen = value
|
||||
Global.database.save()
|
||||
apply_fullscreen()
|
||||
|
||||
func get_setting_version():
|
||||
return setting.get_version()
|
||||
func get_setting_version() -> String:
|
||||
return "v" + _data().version
|
||||
|
||||
+3
-3
@@ -22,12 +22,12 @@ static func _on_home_pressed() -> void:
|
||||
Global.current_scene_int = 1
|
||||
Global.goto_scene("res://scenes/levels/home/Home.tscn")
|
||||
|
||||
static func _on_reset_level(level, node: String, index: int, parent) -> void:
|
||||
static func _on_reset_level(level: LevelEntry, node: String, index: int, parent) -> void:
|
||||
Global.current_scene_int = index
|
||||
level.reset()
|
||||
parent.configure_reset(level, node, index, true)
|
||||
parent.configure_reset(level, node, true)
|
||||
parent.configure_counter(level, node)
|
||||
Global.current_scene_int = null
|
||||
Global.current_scene_int = -1
|
||||
|
||||
static func _on_main_scene_pressed() -> void:
|
||||
Global.goto_scene("res://scenes/Main.tscn")
|
||||
|
||||
Reference in New Issue
Block a user