Merge pull request 'feature/menus' (#4) from feature/menus into dev
Reviewed-on: Athena/game-source#4
This commit is contained in:
@@ -57,3 +57,7 @@ $RECYCLE.BIN/
|
|||||||
*.lnk
|
*.lnk
|
||||||
|
|
||||||
# End of https://www.toptal.com/developers/gitignore/api/godot,linux,windows
|
# End of https://www.toptal.com/developers/gitignore/api/godot,linux,windows
|
||||||
|
|
||||||
|
|
||||||
|
# Ignore files releases
|
||||||
|
releases
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 27 KiB |
@@ -0,0 +1,34 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="StreamTexture"
|
||||||
|
path="res://.import/warcraft.jpg-e4725d0d4db6fd36f05286ac31e934ad.stex"
|
||||||
|
metadata={
|
||||||
|
"vram_texture": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://assets/levels/warcraft.jpg"
|
||||||
|
dest_files=[ "res://.import/warcraft.jpg-e4725d0d4db6fd36f05286ac31e934ad.stex" ]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=0
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
compress/hdr_mode=0
|
||||||
|
compress/bptc_ldr=0
|
||||||
|
compress/normal_map=0
|
||||||
|
flags/repeat=0
|
||||||
|
flags/filter=true
|
||||||
|
flags/mipmaps=false
|
||||||
|
flags/anisotropic=false
|
||||||
|
flags/srgb=2
|
||||||
|
process/fix_alpha_border=true
|
||||||
|
process/premult_alpha=false
|
||||||
|
process/HDR_as_SRGB=false
|
||||||
|
process/invert_color=false
|
||||||
|
stream=false
|
||||||
|
size_limit=0
|
||||||
|
detect_3d=true
|
||||||
|
svg/scale=1.0
|
||||||
@@ -14,6 +14,11 @@ config/name="Athena-Hidden-Object"
|
|||||||
run/main_scene="res://scenes/main.tscn"
|
run/main_scene="res://scenes/main.tscn"
|
||||||
config/icon="res://icon.png"
|
config/icon="res://icon.png"
|
||||||
|
|
||||||
|
[display]
|
||||||
|
|
||||||
|
window/size/borderless=true
|
||||||
|
window/stretch/mode="2d"
|
||||||
|
|
||||||
[physics]
|
[physics]
|
||||||
|
|
||||||
common/enable_pause_aware_picking=true
|
common/enable_pause_aware_picking=true
|
||||||
|
|||||||
@@ -1,9 +0,0 @@
|
|||||||
extends Node
|
|
||||||
|
|
||||||
|
|
||||||
# Called when the node enters the scene tree for the first time.
|
|
||||||
func _ready():
|
|
||||||
pass # Replace with function body.
|
|
||||||
|
|
||||||
func _on_Return_pressed():
|
|
||||||
get_tree().change_scene("res://scenes/main.tscn")
|
|
||||||
+16
-16
@@ -1,14 +1,24 @@
|
|||||||
[gd_scene load_steps=2 format=2]
|
[gd_scene load_steps=2 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://scenes/UI/About.gd" type="Script" id=1]
|
[sub_resource type="GDScript" id=1]
|
||||||
|
script/source = "extends Node
|
||||||
|
|
||||||
|
|
||||||
|
# Called when the node enters the scene tree for the first time.
|
||||||
|
func _ready():
|
||||||
|
pass # Replace with function body.
|
||||||
|
|
||||||
|
func _on_Return_pressed():
|
||||||
|
get_tree().change_scene(\"res://scenes/main.tscn\")
|
||||||
|
"
|
||||||
|
|
||||||
[node name="About" type="Node"]
|
[node name="About" type="Node"]
|
||||||
script = ExtResource( 1 )
|
script = SubResource( 1 )
|
||||||
|
|
||||||
[node name="GRem" type="Label" parent="."]
|
[node name="GRem" type="Label" parent="."]
|
||||||
margin_left = 150.0
|
margin_left = 350.0
|
||||||
margin_top = 150.0
|
margin_top = 150.0
|
||||||
margin_right = 416.0
|
margin_right = 616.0
|
||||||
margin_bottom = 181.0
|
margin_bottom = 181.0
|
||||||
text = "Lead Develop : GRem -- VAILLANT Jérémy
|
text = "Lead Develop : GRem -- VAILLANT Jérémy
|
||||||
"
|
"
|
||||||
@@ -17,21 +27,11 @@ __meta__ = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
[node name="Stilobique" type="Label" parent="."]
|
[node name="Stilobique" type="Label" parent="."]
|
||||||
margin_left = 300.0
|
margin_left = 500.0
|
||||||
margin_top = 300.0
|
margin_top = 300.0
|
||||||
margin_right = 583.0
|
margin_right = 783.0
|
||||||
margin_bottom = 331.0
|
margin_bottom = 331.0
|
||||||
text = "Lead Artist : Stilobique -- VAILLANT Aurelien"
|
text = "Lead Artist : Stilobique -- VAILLANT Aurelien"
|
||||||
__meta__ = {
|
__meta__ = {
|
||||||
"_edit_use_anchors_": false
|
"_edit_use_anchors_": false
|
||||||
}
|
}
|
||||||
|
|
||||||
[node name="Return" type="LinkButton" parent="."]
|
|
||||||
margin_right = 40.0
|
|
||||||
margin_bottom = 14.0
|
|
||||||
text = "back"
|
|
||||||
__meta__ = {
|
|
||||||
"_edit_use_anchors_": false
|
|
||||||
}
|
|
||||||
|
|
||||||
[connection signal="pressed" from="Return" to="." method="_on_Return_pressed"]
|
|
||||||
|
|||||||
@@ -1,7 +1,4 @@
|
|||||||
extends Control
|
extends Control
|
||||||
|
|
||||||
func _on_Return_pressed():
|
|
||||||
get_tree().change_scene("res://scenes/main.tscn")
|
|
||||||
|
|
||||||
func _on_WarCraft_pressed():
|
func _on_WarCraft_pressed():
|
||||||
get_tree().change_scene("res://scenes/levels/WarCraft.tscn")
|
get_tree().change_scene("res://scenes/levels/WarCraft.tscn")
|
||||||
|
|||||||
+12
-14
@@ -1,32 +1,30 @@
|
|||||||
[gd_scene load_steps=2 format=2]
|
[gd_scene load_steps=3 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://scenes/UI/ChooseScene.gd" type="Script" id=1]
|
[ext_resource path="res://scenes/UI/ChooseScene.gd" type="Script" id=1]
|
||||||
|
[ext_resource path="res://assets/levels/warcraft.jpg" type="Texture" id=2]
|
||||||
|
|
||||||
[node name="ChooseScene" type="Control"]
|
[node name="ChooseScene" type="Control"]
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
anchor_bottom = 1.0
|
anchor_bottom = 1.0
|
||||||
|
margin_left = 200.0
|
||||||
script = ExtResource( 1 )
|
script = ExtResource( 1 )
|
||||||
__meta__ = {
|
__meta__ = {
|
||||||
"_edit_use_anchors_": false
|
"_edit_use_anchors_": false
|
||||||
}
|
}
|
||||||
|
|
||||||
[node name="GridContainer" type="GridContainer" parent="."]
|
[node name="GridContainer" type="GridContainer" parent="."]
|
||||||
margin_right = 1024.0
|
margin_left = 25.0
|
||||||
margin_bottom = 600.0
|
margin_top = 26.2599
|
||||||
|
margin_right = 824.0
|
||||||
|
margin_bottom = 601.26
|
||||||
__meta__ = {
|
__meta__ = {
|
||||||
"_edit_use_anchors_": false
|
"_edit_use_anchors_": false
|
||||||
}
|
}
|
||||||
|
|
||||||
[node name="Return" type="LinkButton" parent="GridContainer"]
|
[node name="WarCraft" type="TextureButton" parent="GridContainer"]
|
||||||
margin_right = 54.0
|
margin_right = 150.0
|
||||||
margin_bottom = 14.0
|
margin_bottom = 150.0
|
||||||
text = "back"
|
mouse_default_cursor_shape = 2
|
||||||
|
texture_normal = ExtResource( 2 )
|
||||||
|
|
||||||
[node name="WarCraft" type="LinkButton" parent="GridContainer"]
|
|
||||||
margin_top = 18.0
|
|
||||||
margin_right = 54.0
|
|
||||||
margin_bottom = 32.0
|
|
||||||
text = "WarCraft"
|
|
||||||
|
|
||||||
[connection signal="pressed" from="GridContainer/Return" to="." method="_on_Return_pressed"]
|
|
||||||
[connection signal="pressed" from="GridContainer/WarCraft" to="." method="_on_WarCraft_pressed"]
|
[connection signal="pressed" from="GridContainer/WarCraft" to="." method="_on_WarCraft_pressed"]
|
||||||
|
|||||||
+17
-2
@@ -1,13 +1,28 @@
|
|||||||
extends Node
|
extends Node
|
||||||
|
|
||||||
|
export (PackedScene) var about = load("res://scenes/UI/About.tscn")
|
||||||
|
export (PackedScene) var scenes = load("res://scenes/UI/ChooseScene.tscn")
|
||||||
|
|
||||||
|
var scene
|
||||||
|
|
||||||
# Quit the game
|
# Quit the game
|
||||||
func _on_Quit_pressed():
|
func _on_Quit_pressed():
|
||||||
get_tree().quit(0)
|
get_tree().quit(0)
|
||||||
|
|
||||||
# Load scene about
|
# Load scene about
|
||||||
func _on_About_pressed():
|
func _on_About_pressed():
|
||||||
get_tree().change_scene("res://scenes/UI/About.tscn")
|
_prepare_change_scene()
|
||||||
|
scene = about.instance()
|
||||||
|
add_child(scene)
|
||||||
|
|
||||||
# Load scene for select game
|
# Load scene for select game
|
||||||
func _on_New_pressed():
|
func _on_New_pressed():
|
||||||
get_tree().change_scene("res://scenes/UI/ChooseScene.tscn")
|
_prepare_change_scene()
|
||||||
|
scene = scenes.instance()
|
||||||
|
add_child(scene)
|
||||||
|
|
||||||
|
## PRIVATE
|
||||||
|
func _prepare_change_scene():
|
||||||
|
if (scene != null):
|
||||||
|
remove_child(scene)
|
||||||
|
scene.call_deferred("free")
|
||||||
|
|||||||
+76
-22
@@ -1,6 +1,7 @@
|
|||||||
[gd_scene load_steps=3 format=2]
|
[gd_scene load_steps=4 format=2]
|
||||||
|
|
||||||
[ext_resource path="res://scenes/main.gd" type="Script" id=1]
|
[ext_resource path="res://scenes/main.gd" type="Script" id=1]
|
||||||
|
[ext_resource path="res://icon.png" type="Texture" id=2]
|
||||||
|
|
||||||
[sub_resource type="GDScript" id=1]
|
[sub_resource type="GDScript" id=1]
|
||||||
script/source = "extends LinkButton
|
script/source = "extends LinkButton
|
||||||
@@ -11,6 +12,14 @@ script/source = "extends LinkButton
|
|||||||
[node name="Main" type="Node"]
|
[node name="Main" type="Node"]
|
||||||
script = ExtResource( 1 )
|
script = ExtResource( 1 )
|
||||||
|
|
||||||
|
[node name="ColorRect" type="ColorRect" parent="."]
|
||||||
|
margin_right = 1024.0
|
||||||
|
margin_bottom = 600.0
|
||||||
|
color = Color( 0.156863, 0.00392157, 0.0156863, 1 )
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
[node name="Grid" type="GridContainer" parent="."]
|
[node name="Grid" type="GridContainer" parent="."]
|
||||||
margin_left = -1.33484
|
margin_left = -1.33484
|
||||||
margin_right = 1022.67
|
margin_right = 1022.67
|
||||||
@@ -19,39 +28,84 @@ __meta__ = {
|
|||||||
"_edit_use_anchors_": false
|
"_edit_use_anchors_": false
|
||||||
}
|
}
|
||||||
|
|
||||||
[node name="Title" type="Label" parent="Grid"]
|
[node name="Menu" type="Panel" parent="Grid"]
|
||||||
margin_right = 151.0
|
|
||||||
margin_bottom = 14.0
|
[node name="Banner" type="Panel" parent="Grid/Menu"]
|
||||||
text = "Athena - Hidden Object"
|
margin_right = 150.0
|
||||||
|
margin_bottom = 150.0
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[node name="ColorRect" type="ColorRect" parent="Grid/Menu/Banner"]
|
||||||
|
margin_right = 150.0
|
||||||
|
margin_bottom = 150.0
|
||||||
|
color = Color( 0.992157, 0.705882, 0, 1 )
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[node name="Title" type="Label" parent="Grid/Menu/Banner/ColorRect"]
|
||||||
|
margin_right = 150.0
|
||||||
|
margin_bottom = 150.0
|
||||||
|
text = "Loki
|
||||||
|
"
|
||||||
align = 1
|
align = 1
|
||||||
valign = 1
|
valign = 2
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
[node name="New" type="LinkButton" parent="Grid"]
|
[node name="TextureRect" type="TextureRect" parent="Grid/Menu/Banner/ColorRect/Title"]
|
||||||
margin_top = 18.0
|
margin_left = 48.0
|
||||||
margin_right = 151.0
|
margin_right = 176.0
|
||||||
margin_bottom = 32.0
|
margin_bottom = 128.0
|
||||||
|
rect_scale = Vector2( 0.5, 0.5 )
|
||||||
|
texture = ExtResource( 2 )
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[node name="Action" type="Panel" parent="Grid/Menu"]
|
||||||
|
margin_top = 150.0
|
||||||
|
margin_right = 150.0
|
||||||
|
margin_bottom = 600.0
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[node name="New" type="LinkButton" parent="Grid/Menu/Action"]
|
||||||
|
margin_top = 30.0
|
||||||
|
margin_right = 150.0
|
||||||
|
margin_bottom = 44.0
|
||||||
text = "Nouveau"
|
text = "Nouveau"
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
[node name="Continue" type="LinkButton" parent="Grid"]
|
[node name="Continue" type="LinkButton" parent="Grid/Menu/Action"]
|
||||||
margin_top = 36.0
|
margin_top = 70.0
|
||||||
margin_right = 151.0
|
margin_right = 151.0
|
||||||
margin_bottom = 50.0
|
margin_bottom = 74.0
|
||||||
disabled = true
|
disabled = true
|
||||||
text = "Reprendre"
|
text = "Reprendre"
|
||||||
|
|
||||||
[node name="About" type="LinkButton" parent="Grid"]
|
[node name="About" type="LinkButton" parent="Grid/Menu/Action"]
|
||||||
margin_top = 54.0
|
margin_top = 110.0
|
||||||
margin_right = 151.0
|
margin_right = 151.0
|
||||||
margin_bottom = 68.0
|
margin_bottom = 80.0
|
||||||
text = "Credit"
|
text = "Credit"
|
||||||
|
|
||||||
[node name="Quit" type="LinkButton" parent="Grid"]
|
[node name="Quit" type="LinkButton" parent="Grid/Menu/Action"]
|
||||||
margin_top = 72.0
|
margin_top = 400.0
|
||||||
margin_right = 151.0
|
margin_right = 151.0
|
||||||
margin_bottom = 86.0
|
margin_bottom = 98.0
|
||||||
text = "Quitter"
|
text = "Quitter"
|
||||||
script = SubResource( 1 )
|
script = SubResource( 1 )
|
||||||
|
__meta__ = {
|
||||||
|
"_edit_use_anchors_": false
|
||||||
|
}
|
||||||
|
|
||||||
[connection signal="pressed" from="Grid/New" to="." method="_on_New_pressed"]
|
[connection signal="pressed" from="Grid/Menu/Action/New" to="." method="_on_New_pressed"]
|
||||||
[connection signal="pressed" from="Grid/About" to="." method="_on_About_pressed"]
|
[connection signal="pressed" from="Grid/Menu/Action/About" to="." method="_on_About_pressed"]
|
||||||
[connection signal="pressed" from="Grid/Quit" to="." method="_on_Quit_pressed"]
|
[connection signal="pressed" from="Grid/Menu/Action/Quit" to="." method="_on_Quit_pressed"]
|
||||||
|
|||||||
Reference in New Issue
Block a user