button de manipulation du model lors de la selection/creation de perso remplacer par des textureButton.

This commit is contained in:
osquallo 2018-08-24 12:19:15 +02:00
parent 5db82314fc
commit 15abde9870
10 changed files with 73 additions and 71 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 388 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 429 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 339 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 336 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 334 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 323 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 829 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 754 B

View file

@ -1,10 +1,18 @@
[gd_scene load_steps=7 format=2] [gd_scene load_steps=15 format=2]
[ext_resource path="res://login_scene/character_selection_menu.gd" type="Script" id=1] [ext_resource path="res://login_scene/character_selection_menu.gd" type="Script" id=1]
[ext_resource path="res://scenes/Game/Character/Character.tscn" type="PackedScene" id=2] [ext_resource path="res://scenes/Game/Character/Character.tscn" type="PackedScene" id=2]
[ext_resource path="res://assets/GUI/images/new_launcher_bg_0-1.png" type="Texture" id=3] [ext_resource path="res://assets/GUI/images/new_launcher_bg_0-1.png" type="Texture" id=3]
[ext_resource path="res://login_scene/character_slots.tscn" type="PackedScene" id=4] [ext_resource path="res://login_scene/character_slots.tscn" type="PackedScene" id=4]
[ext_resource path="res://login_scene/character_creation_box.tscn" type="PackedScene" id=5] [ext_resource path="res://login_scene/character_creation_box.tscn" type="PackedScene" id=5]
[ext_resource path="res://assets/GUI/images/button_turn_left_up.png" type="Texture" id=6]
[ext_resource path="res://assets/GUI/images/button_turn_left.png" type="Texture" id=7]
[ext_resource path="res://assets/GUI/images/button_zoom_out.png" type="Texture" id=8]
[ext_resource path="res://assets/GUI/images/button_zoom_in.png" type="Texture" id=9]
[ext_resource path="res://assets/GUI/images/button_turn_right_up.png" type="Texture" id=10]
[ext_resource path="res://assets/GUI/images/button_turn_right.png" type="Texture" id=11]
[ext_resource path="res://assets/GUI/images/button_light_off.png" type="Texture" id=12]
[ext_resource path="res://assets/GUI/images/button_light_on.png" type="Texture" id=13]
[sub_resource type="ViewportTexture" id=1] [sub_resource type="ViewportTexture" id=1]
@ -166,8 +174,8 @@ anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_left = 8.0 margin_left = 8.0
margin_top = 8.0 margin_top = 8.0
margin_right = 1124.0 margin_right = 1016.0
margin_bottom = 592.0 margin_bottom = 652.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
mouse_filter = 1 mouse_filter = 1
@ -179,21 +187,29 @@ _sections_unfolded = [ "Size Flags", "custom_constants" ]
[node name="character_slots" parent="margin_container/character_box" index="0" instance=ExtResource( 4 )] [node name="character_slots" parent="margin_container/character_box" index="0" instance=ExtResource( 4 )]
margin_top = 282.0 margin_top = 312.0
margin_bottom = 302.0 margin_bottom = 332.0
size_flags_vertical = 6 size_flags_vertical = 6
custom_constants/separation = 8 custom_constants/separation = 8
_sections_unfolded = [ "Size Flags", "custom_constants" ] _sections_unfolded = [ "Size Flags", "custom_constants" ]
[node name="v_box_container" type="VBoxContainer" parent="margin_container/character_box" index="1"] [node name="character_creation_box" parent="margin_container/character_box" index="1" instance=ExtResource( 5 )]
visible = false
margin_left = 58.0
margin_top = 183.0
margin_right = 600.0
margin_bottom = 401.0
[node name="v_box_container" type="VBoxContainer" parent="margin_container/character_box" index="2"]
anchor_left = 0.0 anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_left = 58.0 margin_left = 58.0
margin_right = 1116.0 margin_right = 1008.0
margin_bottom = 584.0 margin_bottom = 644.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
mouse_filter = 1 mouse_filter = 1
@ -209,8 +225,8 @@ anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_right = 1058.0 margin_right = 950.0
margin_bottom = 560.0 margin_bottom = 608.0
rect_min_size = Vector2( 512, 512 ) rect_min_size = Vector2( 512, 512 )
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
@ -229,10 +245,10 @@ anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_left = 468.0 margin_left = 387.0
margin_top = 564.0 margin_top = 612.0
margin_right = 590.0 margin_right = 563.0
margin_bottom = 584.0 margin_bottom = 644.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
mouse_filter = 1 mouse_filter = 1
@ -242,14 +258,14 @@ size_flags_vertical = 1
alignment = 0 alignment = 0
_sections_unfolded = [ "Size Flags" ] _sections_unfolded = [ "Size Flags" ]
[node name="turn_left" type="Button" parent="margin_container/character_box/v_box_container/h_box_container" index="0"] [node name="turn_left" type="TextureButton" parent="margin_container/character_box/v_box_container/h_box_container" index="0"]
anchor_left = 0.0 anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_right = 25.0 margin_right = 32.0
margin_bottom = 20.0 margin_bottom = 32.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
hint_tooltip = "Tourner le modele vers la gauche." hint_tooltip = "Tourner le modele vers la gauche."
@ -263,20 +279,19 @@ action_mode = 0
enabled_focus_mode = 2 enabled_focus_mode = 2
shortcut = null shortcut = null
group = null group = null
text = "<-" texture_normal = ExtResource( 6 )
flat = false texture_pressed = ExtResource( 7 )
align = 1 _sections_unfolded = [ "Hint", "Rect", "Textures" ]
_sections_unfolded = [ "Hint" ]
[node name="zoom_out" type="Button" parent="margin_container/character_box/v_box_container/h_box_container" index="1"] [node name="zoom_out" type="TextureButton" parent="margin_container/character_box/v_box_container/h_box_container" index="1"]
anchor_left = 0.0 anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_left = 29.0 margin_left = 36.0
margin_right = 46.0 margin_right = 68.0
margin_bottom = 20.0 margin_bottom = 32.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
hint_tooltip = "Zoom arrière." hint_tooltip = "Zoom arrière."
@ -289,20 +304,18 @@ toggle_mode = false
enabled_focus_mode = 2 enabled_focus_mode = 2
shortcut = null shortcut = null
group = null group = null
text = "-" texture_normal = ExtResource( 8 )
flat = false _sections_unfolded = [ "Hint", "Textures" ]
align = 1
_sections_unfolded = [ "Hint" ]
[node name="zoom_in" type="Button" parent="margin_container/character_box/v_box_container/h_box_container" index="2"] [node name="zoom_in" type="TextureButton" parent="margin_container/character_box/v_box_container/h_box_container" index="2"]
anchor_left = 0.0 anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_left = 50.0 margin_left = 72.0
margin_right = 70.0 margin_right = 104.0
margin_bottom = 20.0 margin_bottom = 32.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
hint_tooltip = "Zoom avant." hint_tooltip = "Zoom avant."
@ -315,20 +328,18 @@ toggle_mode = false
enabled_focus_mode = 2 enabled_focus_mode = 2
shortcut = null shortcut = null
group = null group = null
text = "+" texture_normal = ExtResource( 9 )
flat = false _sections_unfolded = [ "Hint", "Textures" ]
align = 1
_sections_unfolded = [ "Hint" ]
[node name="turn_right" type="Button" parent="margin_container/character_box/v_box_container/h_box_container" index="3"] [node name="turn_right" type="TextureButton" parent="margin_container/character_box/v_box_container/h_box_container" index="3"]
anchor_left = 0.0 anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_left = 74.0 margin_left = 108.0
margin_right = 99.0 margin_right = 140.0
margin_bottom = 20.0 margin_bottom = 32.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
hint_tooltip = "Tourner le modele vers la droite." hint_tooltip = "Tourner le modele vers la droite."
@ -342,20 +353,19 @@ action_mode = 0
enabled_focus_mode = 2 enabled_focus_mode = 2
shortcut = null shortcut = null
group = null group = null
text = "->" texture_normal = ExtResource( 10 )
flat = false texture_pressed = ExtResource( 11 )
align = 1 _sections_unfolded = [ "Hint", "Textures" ]
_sections_unfolded = [ "Hint" ]
[node name="lights" type="Button" parent="margin_container/character_box/v_box_container/h_box_container" index="4"] [node name="lights" type="TextureButton" parent="margin_container/character_box/v_box_container/h_box_container" index="4"]
anchor_left = 0.0 anchor_left = 0.0
anchor_top = 0.0 anchor_top = 0.0
anchor_right = 0.0 anchor_right = 0.0
anchor_bottom = 0.0 anchor_bottom = 0.0
margin_left = 103.0 margin_left = 144.0
margin_right = 122.0 margin_right = 176.0
margin_bottom = 20.0 margin_bottom = 32.0
rect_pivot_offset = Vector2( 0, 0 ) rect_pivot_offset = Vector2( 0, 0 )
rect_clip_content = false rect_clip_content = false
hint_tooltip = "Lumières ON/OFF" hint_tooltip = "Lumières ON/OFF"
@ -369,21 +379,20 @@ pressed = true
enabled_focus_mode = 2 enabled_focus_mode = 2
shortcut = null shortcut = null
group = null group = null
text = "L" texture_normal = ExtResource( 12 )
flat = false texture_pressed = ExtResource( 13 )
align = 1 _sections_unfolded = [ "Hint", "Textures" ]
_sections_unfolded = [ "Hint" ]
[node name="character_creation_box" parent="margin_container/character_box" index="2" instance=ExtResource( 5 )]
visible = false
margin_left = 58.0
margin_top = 183.0
margin_right = 600.0
margin_bottom = 401.0
[connection signal="return_button_pressed" from="margin_container/character_box/character_slots" to="." method="_on_character_slots_return_button_pressed"] [connection signal="return_button_pressed" from="margin_container/character_box/character_slots" to="." method="_on_character_slots_return_button_pressed"]
[connection signal="creation_button_pressed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_creation_button_pressed"]
[connection signal="return_button_pressed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_return_button_pressed"]
[connection signal="sex_bar_changed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_sex_bar_changed"]
[connection signal="size_bar_changed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_size_bar_changed"]
[connection signal="button_down" from="margin_container/character_box/v_box_container/h_box_container/turn_left" to="." method="_on_turn_left_button_down"] [connection signal="button_down" from="margin_container/character_box/v_box_container/h_box_container/turn_left" to="." method="_on_turn_left_button_down"]
[connection signal="button_up" from="margin_container/character_box/v_box_container/h_box_container/turn_left" to="." method="_on_turn_left_button_up"] [connection signal="button_up" from="margin_container/character_box/v_box_container/h_box_container/turn_left" to="." method="_on_turn_left_button_up"]
@ -402,12 +411,4 @@ margin_bottom = 401.0
[connection signal="toggled" from="margin_container/character_box/v_box_container/h_box_container/lights" to="." method="_on_lights_toggled"] [connection signal="toggled" from="margin_container/character_box/v_box_container/h_box_container/lights" to="." method="_on_lights_toggled"]
[connection signal="creation_button_pressed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_creation_button_pressed"]
[connection signal="return_button_pressed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_return_button_pressed"]
[connection signal="sex_bar_changed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_sex_bar_changed"]
[connection signal="size_bar_changed" from="margin_container/character_box/character_creation_box" to="." method="_on_character_creation_box_size_bar_changed"]

View file

@ -49,9 +49,9 @@ void fragment() {
render_priority = 0 render_priority = 0
shader = SubResource( 4 ) shader = SubResource( 4 )
shader_param/albedo = Color( 1, 1, 1, 1 ) shader_param/albedo = Color( 1, 1, 1, 1 )
shader_param/specular = 0.5 shader_param/specular = 0.0
shader_param/metallic = 0.0 shader_param/metallic = 0.0
shader_param/roughness = 0.0 shader_param/roughness = 1.0
shader_param/point_size = 1.0 shader_param/point_size = 1.0
shader_param/metallic_texture_channel = Plane( 1, 0, 0, 0 ) shader_param/metallic_texture_channel = Plane( 1, 0, 0, 0 )
shader_param/roughness_texture_channel = Plane( 1, 0, 0, 0 ) shader_param/roughness_texture_channel = Plane( 1, 0, 0, 0 )
@ -59,6 +59,7 @@ shader_param/uv1_scale = Vector3( 1, 1, 1 )
shader_param/uv1_offset = Vector3( 0, 0, 0 ) shader_param/uv1_offset = Vector3( 0, 0, 0 )
shader_param/uv2_scale = Vector3( 1, 1, 1 ) shader_param/uv2_scale = Vector3( 1, 1, 1 )
shader_param/uv2_offset = Vector3( 0, 0, 0 ) shader_param/uv2_offset = Vector3( 0, 0, 0 )
_sections_unfolded = [ "shader_param" ]
[sub_resource type="SphereShape" id=3] [sub_resource type="SphereShape" id=3]