ajout d'un 'jukebox' fesan aparaitre la fnetre music si on s'en approche.
This commit is contained in:
parent
fca412affc
commit
83dc298a86
7 changed files with 465 additions and 3 deletions
BIN
assets/Game/jukebox/jukebox_colorgrid_tex.png
Normal file
BIN
assets/Game/jukebox/jukebox_colorgrid_tex.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 76 KiB |
|
@ -986,7 +986,6 @@ _sections_unfolded = [ "Rect", "Size Flags", "custom_constants" ]
|
||||||
|
|
||||||
[node name="RichTextLabel" type="RichTextLabel" parent="Windows/Music/VBoxContainer/Content" index="0"]
|
[node name="RichTextLabel" type="RichTextLabel" parent="Windows/Music/VBoxContainer/Content" index="0"]
|
||||||
|
|
||||||
visible = false
|
|
||||||
anchor_left = 0.0
|
anchor_left = 0.0
|
||||||
anchor_top = 0.0
|
anchor_top = 0.0
|
||||||
anchor_right = 0.0
|
anchor_right = 0.0
|
||||||
|
@ -1017,6 +1016,7 @@ _sections_unfolded = [ "BBCode", "Rect", "Size Flags" ]
|
||||||
|
|
||||||
[node name="Music" parent="Windows/Music/VBoxContainer/Content" index="1" instance=ExtResource( 8 )]
|
[node name="Music" parent="Windows/Music/VBoxContainer/Content" index="1" instance=ExtResource( 8 )]
|
||||||
|
|
||||||
|
visible = false
|
||||||
margin_left = 8.0
|
margin_left = 8.0
|
||||||
margin_top = 8.0
|
margin_top = 8.0
|
||||||
margin_right = 121.0
|
margin_right = 121.0
|
||||||
|
@ -1087,6 +1087,7 @@ _sections_unfolded = [ "Mouse", "Size Flags", "Textures" ]
|
||||||
|
|
||||||
[node name="Music" parent="." index="3" instance=ExtResource( 8 )]
|
[node name="Music" parent="." index="3" instance=ExtResource( 8 )]
|
||||||
|
|
||||||
|
visible = false
|
||||||
margin_left = 942.0
|
margin_left = 942.0
|
||||||
margin_top = 0.0
|
margin_top = 0.0
|
||||||
margin_right = 1024.0
|
margin_right = 1024.0
|
||||||
|
@ -1097,6 +1098,7 @@ _sections_unfolded = [ "Size Flags" ]
|
||||||
|
|
||||||
[node name="Jauges" type="VBoxContainer" parent="." index="4"]
|
[node name="Jauges" type="VBoxContainer" parent="." index="4"]
|
||||||
|
|
||||||
|
editor/display_folded = true
|
||||||
anchor_left = 0.0
|
anchor_left = 0.0
|
||||||
anchor_top = 0.0
|
anchor_top = 0.0
|
||||||
anchor_right = 0.0
|
anchor_right = 0.0
|
||||||
|
|
|
@ -15,7 +15,7 @@ radial_segments = 64
|
||||||
rings = 32
|
rings = 32
|
||||||
is_hemisphere = false
|
is_hemisphere = false
|
||||||
|
|
||||||
[node name="Character" type="KinematicBody" index="0"]
|
[node name="Character" type="KinematicBody"]
|
||||||
|
|
||||||
transform = Transform( 1, 0, 0, 0, 0.589355, 0, 0, 0, 1, -0.0409546, 1.06519, 6.02408 )
|
transform = Transform( 1, 0, 0, 0, 0.589355, 0, 0, 0, 1, -0.0409546, 1.06519, 6.02408 )
|
||||||
input_ray_pickable = true
|
input_ray_pickable = true
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
[gd_scene load_steps=40 format=2]
|
[gd_scene load_steps=41 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://scenes/Game/Character/Character.tscn" type="PackedScene" id=1]
|
[ext_resource path="res://scenes/Game/Character/Character.tscn" type="PackedScene" id=1]
|
||||||
[ext_resource path="res://scenes/Game/Terrain/Terrain.tscn" type="PackedScene" id=2]
|
[ext_resource path="res://scenes/Game/Terrain/Terrain.tscn" type="PackedScene" id=2]
|
||||||
|
@ -12,6 +12,7 @@
|
||||||
[ext_resource path="res://scenes/Game/firecamp.tscn" type="PackedScene" id=10]
|
[ext_resource path="res://scenes/Game/firecamp.tscn" type="PackedScene" id=10]
|
||||||
[ext_resource path="res://assets/Game/textures/fire_01.png" type="Texture" id=11]
|
[ext_resource path="res://assets/Game/textures/fire_01.png" type="Texture" id=11]
|
||||||
[ext_resource path="res://assets/Game/textures/fire_02.png" type="Texture" id=12]
|
[ext_resource path="res://assets/Game/textures/fire_02.png" type="Texture" id=12]
|
||||||
|
[ext_resource path="res://scenes/Game/jukebox/jukebox.tscn" type="PackedScene" id=13]
|
||||||
|
|
||||||
[sub_resource type="GDScript" id=1]
|
[sub_resource type="GDScript" id=1]
|
||||||
|
|
||||||
|
@ -1134,6 +1135,11 @@ draw_passes = 2
|
||||||
draw_pass_1 = SubResource( 25 )
|
draw_pass_1 = SubResource( 25 )
|
||||||
draw_pass_2 = SubResource( 27 )
|
draw_pass_2 = SubResource( 27 )
|
||||||
|
|
||||||
|
[node name="jukebox" parent="." index="2" instance=ExtResource( 13 )]
|
||||||
|
|
||||||
|
transform = Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, -7.67816, 0, 0 )
|
||||||
|
music_window = "../../GUI/HUD/Music"
|
||||||
|
|
||||||
[connection signal="sleeping_state_changed" from="World/Box" to="World/Box" method="_on_Box_sleeping_state_changed"]
|
[connection signal="sleeping_state_changed" from="World/Box" to="World/Box" method="_on_Box_sleeping_state_changed"]
|
||||||
|
|
||||||
[connection signal="sleeping_state_changed" from="World/Box3" to="World/Box3" method="_on_Box_sleeping_state_changed"]
|
[connection signal="sleeping_state_changed" from="World/Box3" to="World/Box3" method="_on_Box_sleeping_state_changed"]
|
||||||
|
|
71
scenes/Game/jukebox/jukebox.escn
Normal file
71
scenes/Game/jukebox/jukebox.escn
Normal file
File diff suppressed because one or more lines are too long
17
scenes/Game/jukebox/jukebox.gd
Normal file
17
scenes/Game/jukebox/jukebox.gd
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
extends Spatial
|
||||||
|
|
||||||
|
export( String ) var music_window = ""
|
||||||
|
|
||||||
|
|
||||||
|
func _on_Area_body_entered(body):
|
||||||
|
print( "jukebox entered: " +str(body.name) )
|
||||||
|
if not music_window == "" and get_node( music_window ) and body.name == "Character":
|
||||||
|
get_node( music_window ).show()
|
||||||
|
print( "test entered" )
|
||||||
|
|
||||||
|
|
||||||
|
func _on_Area_body_exited(body):
|
||||||
|
print( "jukebox exited: " +str(body.name) )
|
||||||
|
if not music_window == "" and get_node( music_window ) and body.name == "Character":
|
||||||
|
get_node( music_window ).hide()
|
||||||
|
print( "test exited" )
|
366
scenes/Game/jukebox/jukebox.tscn
Normal file
366
scenes/Game/jukebox/jukebox.tscn
Normal file
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue