#46 ajout d'une borne de recharge et changements mineurs du gameplay
This commit is contained in:
parent
dbb6855585
commit
3d0104ed4a
@ -0,0 +1,88 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||||
|
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||||
|
|
||||||
|
<svg
|
||||||
|
width="65.888519mm"
|
||||||
|
height="56.356422mm"
|
||||||
|
viewBox="0 0 65.888519 56.356422"
|
||||||
|
version="1.1"
|
||||||
|
id="svg1"
|
||||||
|
inkscape:version="1.3.2 (091e20e, 2023-11-25, custom)"
|
||||||
|
sodipodi:docname="recharge_station.svg"
|
||||||
|
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||||
|
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||||
|
xmlns="http://www.w3.org/2000/svg"
|
||||||
|
xmlns:svg="http://www.w3.org/2000/svg">
|
||||||
|
<sodipodi:namedview
|
||||||
|
id="namedview1"
|
||||||
|
pagecolor="#505050"
|
||||||
|
bordercolor="#ffffff"
|
||||||
|
borderopacity="1"
|
||||||
|
inkscape:showpageshadow="0"
|
||||||
|
inkscape:pageopacity="0"
|
||||||
|
inkscape:pagecheckerboard="1"
|
||||||
|
inkscape:deskcolor="#505050"
|
||||||
|
inkscape:document-units="mm"
|
||||||
|
inkscape:zoom="1.5821549"
|
||||||
|
inkscape:cx="45.82358"
|
||||||
|
inkscape:cy="147.89955"
|
||||||
|
inkscape:window-width="1920"
|
||||||
|
inkscape:window-height="1009"
|
||||||
|
inkscape:window-x="-8"
|
||||||
|
inkscape:window-y="-8"
|
||||||
|
inkscape:window-maximized="1"
|
||||||
|
inkscape:current-layer="layer1" />
|
||||||
|
<defs
|
||||||
|
id="defs1" />
|
||||||
|
<g
|
||||||
|
inkscape:label="Calque 1"
|
||||||
|
inkscape:groupmode="layer"
|
||||||
|
id="layer1"
|
||||||
|
transform="translate(-72.05574,-18.228039)">
|
||||||
|
<rect
|
||||||
|
style="fill:#d1d1d1;fill-opacity:1;stroke-width:0.264583;stroke-linecap:square"
|
||||||
|
id="rect1"
|
||||||
|
width="16.054054"
|
||||||
|
height="35.392433"
|
||||||
|
x="96.972969"
|
||||||
|
y="18.228039"
|
||||||
|
rx="5"
|
||||||
|
ry="5" />
|
||||||
|
<ellipse
|
||||||
|
style="fill:#ffffff;stroke-width:0.264583;stroke-linecap:square"
|
||||||
|
id="path1"
|
||||||
|
cx="105"
|
||||||
|
cy="60.537163"
|
||||||
|
rx="32.94426"
|
||||||
|
ry="14.047297" />
|
||||||
|
<ellipse
|
||||||
|
style="fill:#d1d1d1;fill-opacity:1;stroke-width:0.264583;stroke-linecap:square"
|
||||||
|
id="ellipse1"
|
||||||
|
cx="105"
|
||||||
|
cy="60.537163"
|
||||||
|
rx="16.221287"
|
||||||
|
ry="6.9166899" />
|
||||||
|
<circle
|
||||||
|
style="fill:#ffffff;fill-opacity:1;stroke-width:0.264583;stroke-linecap:square"
|
||||||
|
id="path2"
|
||||||
|
cx="105"
|
||||||
|
cy="26.171452"
|
||||||
|
r="5.685811" />
|
||||||
|
<g
|
||||||
|
id="g3"
|
||||||
|
transform="translate(0.20904541)">
|
||||||
|
<circle
|
||||||
|
style="fill:#d1d1d1;fill-opacity:1;stroke-width:0.264583;stroke-linecap:square"
|
||||||
|
id="circle2"
|
||||||
|
cx="102.61697"
|
||||||
|
cy="26.171452"
|
||||||
|
r="1.5050678" />
|
||||||
|
<circle
|
||||||
|
style="fill:#d1d1d1;fill-opacity:1;stroke-width:0.264583;stroke-linecap:square"
|
||||||
|
id="circle3"
|
||||||
|
cx="106.96494"
|
||||||
|
cy="26.171452"
|
||||||
|
r="1.5050678" />
|
||||||
|
</g>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 2.5 KiB |
@ -0,0 +1,37 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="CompressedTexture2D"
|
||||||
|
uid="uid://c82ljr3in67am"
|
||||||
|
path="res://.godot/imported/recharge_station.svg-e388da7bbc5335a093731cd3d5c6eb67.ctex"
|
||||||
|
metadata={
|
||||||
|
"vram_texture": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://entities/interactables/recharge_station/assets/sprites/recharge_station.svg"
|
||||||
|
dest_files=["res://.godot/imported/recharge_station.svg-e388da7bbc5335a093731cd3d5c6eb67.ctex"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
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/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
|
||||||
|
svg/scale=1.0
|
||||||
|
editor/scale_with_editor_scale=false
|
||||||
|
editor/convert_colors_with_editor_theme=false
|
||||||
@ -0,0 +1,23 @@
|
|||||||
|
[gd_scene load_steps=4 format=3 uid="uid://d324mlmgls4fs"]
|
||||||
|
|
||||||
|
[ext_resource type="Script" uid="uid://bsrn3gd2a532q" path="res://entities/interactables/recharge_station/scripts/recharge_station.gd" id="1_2ffjo"]
|
||||||
|
[ext_resource type="Texture2D" uid="uid://c82ljr3in67am" path="res://entities/interactables/recharge_station/assets/sprites/recharge_station.svg" id="2_58ax0"]
|
||||||
|
|
||||||
|
[sub_resource type="CapsuleShape2D" id="CapsuleShape2D_bjhct"]
|
||||||
|
radius = 15.0
|
||||||
|
height = 72.0
|
||||||
|
|
||||||
|
[node name="RechargeStation" type="Area2D"]
|
||||||
|
modulate = Color(0.615686, 0.501961, 0.270588, 1)
|
||||||
|
script = ExtResource("1_2ffjo")
|
||||||
|
metadata/_custom_type_script = "uid://dyprcd68fjstf"
|
||||||
|
|
||||||
|
[node name="RechargeStation" type="Sprite2D" parent="."]
|
||||||
|
position = Vector2(0, -17)
|
||||||
|
scale = Vector2(0.3, 0.3)
|
||||||
|
texture = ExtResource("2_58ax0")
|
||||||
|
|
||||||
|
[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
|
||||||
|
position = Vector2(1, -1)
|
||||||
|
rotation = -1.5708
|
||||||
|
shape = SubResource("CapsuleShape2D_bjhct")
|
||||||
@ -0,0 +1,13 @@
|
|||||||
|
extends Interactable
|
||||||
|
class_name RechargeStation
|
||||||
|
|
||||||
|
var planet : Planet # mis à jour par la classe Planet
|
||||||
|
|
||||||
|
func interact(_p: Player) -> bool:
|
||||||
|
|
||||||
|
planet.pass_day()
|
||||||
|
|
||||||
|
return true
|
||||||
|
|
||||||
|
func interact_text():
|
||||||
|
return "Recharge"
|
||||||
@ -0,0 +1 @@
|
|||||||
|
uid://bsrn3gd2a532q
|
||||||
@ -6,9 +6,6 @@ var available : bool = true
|
|||||||
func can_interact(_p : Player) -> bool:
|
func can_interact(_p : Player) -> bool:
|
||||||
return true
|
return true
|
||||||
|
|
||||||
func interact_requirement_text() -> String:
|
|
||||||
return ""
|
|
||||||
|
|
||||||
func interact(_p : Player) -> bool:
|
func interact(_p : Player) -> bool:
|
||||||
printerr("Interact function called on abstract Interactable class")
|
printerr("Interact function called on abstract Interactable class")
|
||||||
return false
|
return false
|
||||||
|
|||||||
@ -9,7 +9,7 @@
|
|||||||
|
|
||||||
[sub_resource type="Resource" id="Resource_q68uy"]
|
[sub_resource type="Resource" id="Resource_q68uy"]
|
||||||
script = ExtResource("2_cky1j")
|
script = ExtResource("2_cky1j")
|
||||||
impact_radius = 100
|
impact_radius = 150
|
||||||
metadata/_custom_type_script = "uid://cgscbuxe4dawb"
|
metadata/_custom_type_script = "uid://cgscbuxe4dawb"
|
||||||
|
|
||||||
[sub_resource type="AtlasTexture" id="AtlasTexture_qt76e"]
|
[sub_resource type="AtlasTexture" id="AtlasTexture_qt76e"]
|
||||||
@ -19,7 +19,7 @@ region = Rect2(1140, 345, 141, 128)
|
|||||||
[resource]
|
[resource]
|
||||||
script = ExtResource("1_moyj3")
|
script = ExtResource("1_moyj3")
|
||||||
name = "Chardi"
|
name = "Chardi"
|
||||||
description = "This plant reduce contamination around when it becomes mature."
|
description = "This plant remove a lot of contamination around when it becomes mature."
|
||||||
growing_time = 1
|
growing_time = 1
|
||||||
seed_texture = SubResource("AtlasTexture_qt76e")
|
seed_texture = SubResource("AtlasTexture_qt76e")
|
||||||
planted_texture = ExtResource("4_2s6re")
|
planted_texture = ExtResource("4_2s6re")
|
||||||
|
|||||||
@ -1,11 +1,17 @@
|
|||||||
[gd_resource type="Resource" script_class="PlantType" load_steps=7 format=3 uid="uid://dsctivn1vrem2"]
|
[gd_resource type="Resource" script_class="PlantType" load_steps=9 format=3 uid="uid://dsctivn1vrem2"]
|
||||||
|
|
||||||
[ext_resource type="Script" uid="uid://jnye5pe1bgqw" path="res://entities/plants/scripts/plant_type.gd" id="1_eqtut"]
|
[ext_resource type="Script" uid="uid://jnye5pe1bgqw" path="res://entities/plants/scripts/plant_type.gd" id="1_eqtut"]
|
||||||
[ext_resource type="Texture2D" uid="uid://dwr3c6r6piwaa" path="res://entities/plants/assets/sprites/maias/growing.png" id="1_vyplc"]
|
[ext_resource type="Texture2D" uid="uid://dwr3c6r6piwaa" path="res://entities/plants/assets/sprites/maias/growing.png" id="1_vyplc"]
|
||||||
|
[ext_resource type="Script" path="res://entities/plants/scripts/plant_effects/decontaminate_terrain_effect.gd" id="2_vyplc"]
|
||||||
[ext_resource type="Texture2D" uid="uid://d3apfwbqsg5ha" path="res://entities/plants/assets/sprites/maias/mature.png" id="3_pi4ie"]
|
[ext_resource type="Texture2D" uid="uid://d3apfwbqsg5ha" path="res://entities/plants/assets/sprites/maias/mature.png" id="3_pi4ie"]
|
||||||
[ext_resource type="Texture2D" uid="uid://cpx7bkrvttasr" path="res://entities/plants/assets/sprites/maias/planted.png" id="4_iqcy2"]
|
[ext_resource type="Texture2D" uid="uid://cpx7bkrvttasr" path="res://entities/plants/assets/sprites/maias/planted.png" id="4_iqcy2"]
|
||||||
[ext_resource type="Texture2D" uid="uid://pltmnkqd5ut2" path="res://entities/plants/assets/sprites/seeds/grille_seeds.png" id="6_mwrj8"]
|
[ext_resource type="Texture2D" uid="uid://pltmnkqd5ut2" path="res://entities/plants/assets/sprites/seeds/grille_seeds.png" id="6_mwrj8"]
|
||||||
|
|
||||||
|
[sub_resource type="Resource" id="Resource_q4pje"]
|
||||||
|
script = ExtResource("2_vyplc")
|
||||||
|
impact_radius = 20
|
||||||
|
metadata/_custom_type_script = "uid://cgscbuxe4dawb"
|
||||||
|
|
||||||
[sub_resource type="AtlasTexture" id="AtlasTexture_sri3b"]
|
[sub_resource type="AtlasTexture" id="AtlasTexture_sri3b"]
|
||||||
atlas = ExtResource("6_mwrj8")
|
atlas = ExtResource("6_mwrj8")
|
||||||
region = Rect2(1697, 331, 125, 158)
|
region = Rect2(1697, 331, 125, 158)
|
||||||
@ -13,12 +19,13 @@ region = Rect2(1697, 331, 125, 158)
|
|||||||
[resource]
|
[resource]
|
||||||
script = ExtResource("1_eqtut")
|
script = ExtResource("1_eqtut")
|
||||||
name = "Maias"
|
name = "Maias"
|
||||||
description = "This gorgeous flower has no effect, but produce a lot of seeds."
|
description = "This gorgeous flower produce a lot of seeds."
|
||||||
growing_time = 1
|
growing_time = 1
|
||||||
seed_texture = SubResource("AtlasTexture_sri3b")
|
seed_texture = SubResource("AtlasTexture_sri3b")
|
||||||
planted_texture = ExtResource("4_iqcy2")
|
planted_texture = ExtResource("4_iqcy2")
|
||||||
growing_texture = ExtResource("1_vyplc")
|
growing_texture = ExtResource("1_vyplc")
|
||||||
mature_texture = ExtResource("3_pi4ie")
|
mature_texture = ExtResource("3_pi4ie")
|
||||||
|
mature_effect = SubResource("Resource_q4pje")
|
||||||
harvest_types_path = Array[String](["uid://b04vho33bl52b", "uid://dsctivn1vrem2"])
|
harvest_types_path = Array[String](["uid://b04vho33bl52b", "uid://dsctivn1vrem2"])
|
||||||
harvest_number = Array[int]([3, 4])
|
harvest_number = Array[int]([3, 4])
|
||||||
metadata/_custom_type_script = "uid://jnye5pe1bgqw"
|
metadata/_custom_type_script = "uid://jnye5pe1bgqw"
|
||||||
|
|||||||
@ -4,7 +4,7 @@ class_name Plant
|
|||||||
const PLANT_AREA_WIDTH = 20
|
const PLANT_AREA_WIDTH = 20
|
||||||
const HARVESTED_SEED_POSITION_RANGE = 100
|
const HARVESTED_SEED_POSITION_RANGE = 100
|
||||||
|
|
||||||
const RANDOM_MAX_GROW_INTERVAL = 0.4
|
const RANDOM_MAX_GROW_INTERVAL = Planet.PASS_DAY_ANIMATION_TIME/2. - 0.1
|
||||||
|
|
||||||
const SPRITE_SCENE : PackedScene = preload("res://entities/plants/plant_sprite.tscn")
|
const SPRITE_SCENE : PackedScene = preload("res://entities/plants/plant_sprite.tscn")
|
||||||
|
|
||||||
|
|||||||
@ -48,23 +48,22 @@ func _ready():
|
|||||||
Pointer.player = self
|
Pointer.player = self
|
||||||
|
|
||||||
# Méthode déclenchée par la classe planet
|
# Méthode déclenchée par la classe planet
|
||||||
func _pass_day():
|
func _start_pass_day():
|
||||||
energy = max_energy
|
controlling_player = false
|
||||||
target_interactable = null
|
target_interactable = null
|
||||||
|
|
||||||
|
# Méthode déclenchée par la classe planet
|
||||||
|
func _pass_day():
|
||||||
|
recharge()
|
||||||
|
|
||||||
|
# Méthode déclenchée par la classe planet
|
||||||
|
func _end_pass_day():
|
||||||
|
controlling_player = true
|
||||||
|
|
||||||
func _process(_delta):
|
func _process(_delta):
|
||||||
get_input()
|
get_input()
|
||||||
move_and_slide()
|
move_and_slide()
|
||||||
|
|
||||||
func _on_root_gui_day_pass_pressed():
|
|
||||||
controlling_player = false
|
|
||||||
|
|
||||||
func _on_root_gui_day_pass_finished():
|
|
||||||
controlling_player = true
|
|
||||||
|
|
||||||
func _on_root_gui_game_click():
|
|
||||||
try_use_item()
|
|
||||||
|
|
||||||
func _on_inventory_updated(_inventory: Inventory):
|
func _on_inventory_updated(_inventory: Inventory):
|
||||||
emit_signal("player_updated", self)
|
emit_signal("player_updated", self)
|
||||||
|
|
||||||
@ -162,6 +161,9 @@ func upgrade():
|
|||||||
energy += 1
|
energy += 1
|
||||||
upgraded.emit()
|
upgraded.emit()
|
||||||
|
|
||||||
|
func recharge(amount : int = max_energy):
|
||||||
|
energy = min(energy + amount, max_energy)
|
||||||
|
|
||||||
func play_sfx(sound : String):
|
func play_sfx(sound : String):
|
||||||
match sound:
|
match sound:
|
||||||
"dig":
|
"dig":
|
||||||
|
|||||||
19
game.tscn
19
game.tscn
@ -1,4 +1,4 @@
|
|||||||
[gd_scene load_steps=20 format=3 uid="uid://d28cp7a21kwou"]
|
[gd_scene load_steps=21 format=3 uid="uid://d28cp7a21kwou"]
|
||||||
|
|
||||||
[ext_resource type="PackedScene" uid="uid://12nak7amd1uq" path="res://gui/game/game_gui.tscn" id="1_iotsf"]
|
[ext_resource type="PackedScene" uid="uid://12nak7amd1uq" path="res://gui/game/game_gui.tscn" id="1_iotsf"]
|
||||||
[ext_resource type="PackedScene" uid="uid://csiacsndm62ll" path="res://gui/game/pause/pause.tscn" id="2_215e1"]
|
[ext_resource type="PackedScene" uid="uid://csiacsndm62ll" path="res://gui/game/pause/pause.tscn" id="2_215e1"]
|
||||||
@ -9,6 +9,7 @@
|
|||||||
[ext_resource type="Resource" uid="uid://ddqalo1k30i5x" path="res://common/inventory/resources/items/default_shovel.tres" id="6_lc2xo"]
|
[ext_resource type="Resource" uid="uid://ddqalo1k30i5x" path="res://common/inventory/resources/items/default_shovel.tres" id="6_lc2xo"]
|
||||||
[ext_resource type="PackedScene" uid="uid://bkwh1ntvgkkrt" path="res://entities/interactables/compost/compost.tscn" id="7_215e1"]
|
[ext_resource type="PackedScene" uid="uid://bkwh1ntvgkkrt" path="res://entities/interactables/compost/compost.tscn" id="7_215e1"]
|
||||||
[ext_resource type="Script" uid="uid://bq7admu4ahs5r" path="res://common/inventory/scripts/item.gd" id="7_rvswv"]
|
[ext_resource type="Script" uid="uid://bq7admu4ahs5r" path="res://common/inventory/scripts/item.gd" id="7_rvswv"]
|
||||||
|
[ext_resource type="PackedScene" uid="uid://d324mlmgls4fs" path="res://entities/interactables/recharge_station/recharge_station.tscn" id="8_7sc4i"]
|
||||||
[ext_resource type="Texture2D" uid="uid://pltmnkqd5ut2" path="res://entities/plants/assets/sprites/seeds/grille_seeds.png" id="8_boyg6"]
|
[ext_resource type="Texture2D" uid="uid://pltmnkqd5ut2" path="res://entities/plants/assets/sprites/seeds/grille_seeds.png" id="8_boyg6"]
|
||||||
[ext_resource type="Resource" uid="uid://b04vho33bl52b" path="res://entities/plants/resources/plants/default.tres" id="9_e36ub"]
|
[ext_resource type="Resource" uid="uid://b04vho33bl52b" path="res://entities/plants/resources/plants/default.tres" id="9_e36ub"]
|
||||||
[ext_resource type="Script" uid="uid://bypjcvlc15gsm" path="res://common/inventory/scripts/items/seed.gd" id="10_hb5m1"]
|
[ext_resource type="Script" uid="uid://bypjcvlc15gsm" path="res://common/inventory/scripts/items/seed.gd" id="10_hb5m1"]
|
||||||
@ -23,7 +24,7 @@ region = Rect2(1140, 345, 141, 128)
|
|||||||
script = ExtResource("10_hb5m1")
|
script = ExtResource("10_hb5m1")
|
||||||
plant_type = ExtResource("9_e36ub")
|
plant_type = ExtResource("9_e36ub")
|
||||||
name = "Chardi"
|
name = "Chardi"
|
||||||
description = "This plant reduce contamination around when it becomes mature."
|
description = "This plant remove a lot of contamination around when it becomes mature."
|
||||||
icon = SubResource("AtlasTexture_qt76e")
|
icon = SubResource("AtlasTexture_qt76e")
|
||||||
metadata/_custom_type_script = "uid://bypjcvlc15gsm"
|
metadata/_custom_type_script = "uid://bypjcvlc15gsm"
|
||||||
|
|
||||||
@ -31,7 +32,7 @@ metadata/_custom_type_script = "uid://bypjcvlc15gsm"
|
|||||||
script = ExtResource("10_hb5m1")
|
script = ExtResource("10_hb5m1")
|
||||||
plant_type = ExtResource("9_e36ub")
|
plant_type = ExtResource("9_e36ub")
|
||||||
name = "Chardi"
|
name = "Chardi"
|
||||||
description = "This plant reduce contamination around when it becomes mature."
|
description = "This plant remove a lot of contamination around when it becomes mature."
|
||||||
icon = SubResource("AtlasTexture_qt76e")
|
icon = SubResource("AtlasTexture_qt76e")
|
||||||
metadata/_custom_type_script = "uid://bypjcvlc15gsm"
|
metadata/_custom_type_script = "uid://bypjcvlc15gsm"
|
||||||
|
|
||||||
@ -43,7 +44,7 @@ region = Rect2(1697, 331, 125, 158)
|
|||||||
script = ExtResource("10_hb5m1")
|
script = ExtResource("10_hb5m1")
|
||||||
plant_type = ExtResource("11_x5p1p")
|
plant_type = ExtResource("11_x5p1p")
|
||||||
name = "Maias"
|
name = "Maias"
|
||||||
description = "This gorgeous flower has no effect, but produce a lot of seeds."
|
description = "This gorgeous flower produce a lot of seeds."
|
||||||
icon = SubResource("AtlasTexture_sri3b")
|
icon = SubResource("AtlasTexture_sri3b")
|
||||||
metadata/_custom_type_script = "uid://bypjcvlc15gsm"
|
metadata/_custom_type_script = "uid://bypjcvlc15gsm"
|
||||||
|
|
||||||
@ -76,6 +77,9 @@ metadata/_custom_type_script = "uid://dedg615xudpoq"
|
|||||||
[node name="Compost" parent="Entities" instance=ExtResource("7_215e1")]
|
[node name="Compost" parent="Entities" instance=ExtResource("7_215e1")]
|
||||||
position = Vector2(3, 458)
|
position = Vector2(3, 458)
|
||||||
|
|
||||||
|
[node name="RechargeStation" parent="Entities" instance=ExtResource("8_7sc4i")]
|
||||||
|
position = Vector2(0, -154)
|
||||||
|
|
||||||
[node name="Planet" parent="." node_paths=PackedStringArray("import_entities_from_node") instance=ExtResource("6_e8heu")]
|
[node name="Planet" parent="." node_paths=PackedStringArray("import_entities_from_node") instance=ExtResource("6_e8heu")]
|
||||||
loot_items = Array[ExtResource("7_rvswv")]([SubResource("Resource_lc2xo"), SubResource("Resource_215e1"), SubResource("Resource_7sc4i")])
|
loot_items = Array[ExtResource("7_rvswv")]([SubResource("Resource_lc2xo"), SubResource("Resource_215e1"), SubResource("Resource_7sc4i")])
|
||||||
import_entities_from_node = NodePath("../Entities")
|
import_entities_from_node = NodePath("../Entities")
|
||||||
@ -84,15 +88,12 @@ import_entities_from_node = NodePath("../Entities")
|
|||||||
position = Vector2(2.22, 0)
|
position = Vector2(2.22, 0)
|
||||||
following = NodePath("../Entities/Player")
|
following = NodePath("../Entities/Player")
|
||||||
|
|
||||||
[connection signal="day_pass_finished" from="CanvasLayer/RootGui" to="Entities/Player" method="_on_root_gui_day_pass_finished"]
|
|
||||||
[connection signal="day_pass_finished" from="CanvasLayer/RootGui" to="Planet" method="_on_root_gui_day_pass_finished"]
|
|
||||||
[connection signal="day_pass_pressed" from="CanvasLayer/RootGui" to="Entities/Player" method="_on_root_gui_day_pass_pressed"]
|
|
||||||
[connection signal="day_pass_proceed" from="CanvasLayer/RootGui" to="Planet" method="_on_root_gui_day_pass_proceed"]
|
|
||||||
[connection signal="game_click" from="CanvasLayer/RootGui" to="Entities/Player" method="_on_root_gui_game_click"]
|
|
||||||
[connection signal="pause_asked" from="CanvasLayer/RootGui" to="CanvasLayer/Pause" method="_on_root_gui_pause_asked"]
|
[connection signal="pause_asked" from="CanvasLayer/RootGui" to="CanvasLayer/Pause" method="_on_root_gui_pause_asked"]
|
||||||
[connection signal="action_not_permitted" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_action_not_permitted"]
|
[connection signal="action_not_permitted" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_action_not_permitted"]
|
||||||
[connection signal="action_tried_without_energy" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_action_tried_without_energy"]
|
[connection signal="action_tried_without_energy" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_action_tried_without_energy"]
|
||||||
[connection signal="player_updated" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_updated"]
|
[connection signal="player_updated" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_updated"]
|
||||||
[connection signal="upgraded" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_upgraded"]
|
[connection signal="upgraded" from="Entities/Player" to="CanvasLayer/RootGui" method="_on_player_upgraded"]
|
||||||
[connection signal="day_limit_exceed" from="Planet" to="CanvasLayer/Win" method="_on_planet_day_limit_exceed"]
|
[connection signal="day_limit_exceed" from="Planet" to="CanvasLayer/Win" method="_on_planet_day_limit_exceed"]
|
||||||
|
[connection signal="pass_day_ended" from="Planet" to="CanvasLayer/RootGui" method="_on_planet_pass_day_ended"]
|
||||||
|
[connection signal="pass_day_started" from="Planet" to="CanvasLayer/RootGui" method="_on_planet_pass_day_started"]
|
||||||
[connection signal="planet_updated" from="Planet" to="CanvasLayer/RootGui" method="_on_planet_updated"]
|
[connection signal="planet_updated" from="Planet" to="CanvasLayer/RootGui" method="_on_planet_updated"]
|
||||||
|
|||||||
@ -1,13 +1,13 @@
|
|||||||
[gd_scene load_steps=22 format=3 uid="uid://12nak7amd1uq"]
|
[gd_scene load_steps=21 format=3 uid="uid://12nak7amd1uq"]
|
||||||
|
|
||||||
[ext_resource type="Script" uid="uid://cqao7n800qy40" path="res://gui/game/scripts/game_gui.gd" id="1_udau0"]
|
[ext_resource type="Script" uid="uid://cqao7n800qy40" path="res://gui/game/scripts/game_gui.gd" id="1_udau0"]
|
||||||
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/game/ressources/default_theme.tres" id="2_nq5i2"]
|
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/ressources/default_theme.tres" id="2_nq5i2"]
|
||||||
[ext_resource type="Texture2D" uid="uid://cm3ehinvvj52i" path="res://gui/game/assets/texture/Interface sans boutons.png" id="3_n4kem"]
|
[ext_resource type="Texture2D" uid="uid://cm3ehinvvj52i" path="res://gui/game/assets/texture/Interface sans boutons.png" id="3_n4kem"]
|
||||||
[ext_resource type="Texture2D" uid="uid://dcgnamu7sb3ov" path="res://gui/game/assets/icons/bolt.svg" id="4_k4juk"]
|
[ext_resource type="Texture2D" uid="uid://dcgnamu7sb3ov" path="res://gui/game/assets/icons/bolt.svg" id="4_k4juk"]
|
||||||
[ext_resource type="LabelSettings" uid="uid://dqwayi8yjwau2" path="res://gui/game/ressources/default_label_settings.tres" id="4_ujg5r"]
|
[ext_resource type="LabelSettings" uid="uid://dqwayi8yjwau2" path="res://gui/ressources/title_label_settings.tres" id="4_ujg5r"]
|
||||||
[ext_resource type="Texture2D" uid="uid://c2pgaklnj5w3d" path="res://gui/game/assets/texture/Tablette info.png" id="6_fovlv"]
|
[ext_resource type="Texture2D" uid="uid://c2pgaklnj5w3d" path="res://gui/game/assets/texture/Tablette info.png" id="6_fovlv"]
|
||||||
[ext_resource type="Texture2D" uid="uid://pltmnkqd5ut2" path="res://entities/plants/assets/sprites/seeds/grille_seeds.png" id="7_n4kem"]
|
[ext_resource type="Texture2D" uid="uid://pltmnkqd5ut2" path="res://entities/plants/assets/sprites/seeds/grille_seeds.png" id="7_n4kem"]
|
||||||
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/game/ressources/fonts/spincycle_ot.otf" id="8_n4kem"]
|
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/ressources/fonts/spincycle_ot.otf" id="8_n4kem"]
|
||||||
[ext_resource type="Texture2D" uid="uid://b5cuxgisrsfgt" path="res://gui/game/pause/assets/icons/player-pause.svg" id="9_2wykm"]
|
[ext_resource type="Texture2D" uid="uid://b5cuxgisrsfgt" path="res://gui/game/pause/assets/icons/player-pause.svg" id="9_2wykm"]
|
||||||
|
|
||||||
[sub_resource type="AtlasTexture" id="AtlasTexture_ek73b"]
|
[sub_resource type="AtlasTexture" id="AtlasTexture_ek73b"]
|
||||||
@ -26,72 +26,48 @@ length = 0.001
|
|||||||
tracks/0/type = "value"
|
tracks/0/type = "value"
|
||||||
tracks/0/imported = false
|
tracks/0/imported = false
|
||||||
tracks/0/enabled = true
|
tracks/0/enabled = true
|
||||||
tracks/0/path = NodePath("RechargeFade:color")
|
tracks/0/path = NodePath("PassDayFade:color")
|
||||||
tracks/0/interp = 1
|
tracks/0/interp = 1
|
||||||
tracks/0/loop_wrap = true
|
tracks/0/loop_wrap = true
|
||||||
tracks/0/keys = {
|
tracks/0/keys = {
|
||||||
"times": PackedFloat32Array(0),
|
"times": PackedFloat32Array(0),
|
||||||
"transitions": PackedFloat32Array(1),
|
"transitions": PackedFloat32Array(1),
|
||||||
"update": 0,
|
"update": 0,
|
||||||
"values": [Color(0, 0, 0, 0)]
|
"values": [Color(0.0627451, 0.0588235, 0.168627, 0)]
|
||||||
}
|
}
|
||||||
tracks/1/type = "value"
|
tracks/1/type = "value"
|
||||||
tracks/1/imported = false
|
tracks/1/imported = false
|
||||||
tracks/1/enabled = true
|
tracks/1/enabled = true
|
||||||
tracks/1/path = NodePath("RechargeFade:visible")
|
tracks/1/path = NodePath("MarginContainer/PlayerInfo/EnergyInfo:offset_left")
|
||||||
tracks/1/interp = 1
|
tracks/1/interp = 1
|
||||||
tracks/1/loop_wrap = true
|
tracks/1/loop_wrap = true
|
||||||
tracks/1/keys = {
|
tracks/1/keys = {
|
||||||
"times": PackedFloat32Array(0),
|
"times": PackedFloat32Array(0),
|
||||||
"transitions": PackedFloat32Array(1),
|
"transitions": PackedFloat32Array(1),
|
||||||
"update": 1,
|
"update": 0,
|
||||||
"values": [false]
|
"values": [-44.0]
|
||||||
}
|
}
|
||||||
tracks/2/type = "value"
|
tracks/2/type = "value"
|
||||||
tracks/2/imported = false
|
tracks/2/imported = false
|
||||||
tracks/2/enabled = true
|
tracks/2/enabled = true
|
||||||
tracks/2/path = NodePath("MarginContainer/PlayerInfo/EnergyInfo:offset_left")
|
tracks/2/path = NodePath("Effect:modulate")
|
||||||
tracks/2/interp = 1
|
tracks/2/interp = 1
|
||||||
tracks/2/loop_wrap = true
|
tracks/2/loop_wrap = true
|
||||||
tracks/2/keys = {
|
tracks/2/keys = {
|
||||||
"times": PackedFloat32Array(0),
|
"times": PackedFloat32Array(0),
|
||||||
"transitions": PackedFloat32Array(1),
|
"transitions": PackedFloat32Array(1),
|
||||||
"update": 0,
|
"update": 0,
|
||||||
"values": [-44.0]
|
"values": [Color(1, 1, 1, 0)]
|
||||||
}
|
}
|
||||||
tracks/3/type = "value"
|
tracks/3/type = "value"
|
||||||
tracks/3/imported = false
|
tracks/3/imported = false
|
||||||
tracks/3/enabled = true
|
tracks/3/enabled = true
|
||||||
tracks/3/path = NodePath("Effect:visible")
|
tracks/3/path = NodePath("MarginContainer/PlayerInfo/EnergyInfo:offset_bottom")
|
||||||
tracks/3/interp = 1
|
tracks/3/interp = 1
|
||||||
tracks/3/loop_wrap = true
|
tracks/3/loop_wrap = true
|
||||||
tracks/3/keys = {
|
tracks/3/keys = {
|
||||||
"times": PackedFloat32Array(0),
|
"times": PackedFloat32Array(0),
|
||||||
"transitions": PackedFloat32Array(1),
|
"transitions": PackedFloat32Array(1),
|
||||||
"update": 1,
|
|
||||||
"values": [false]
|
|
||||||
}
|
|
||||||
tracks/4/type = "value"
|
|
||||||
tracks/4/imported = false
|
|
||||||
tracks/4/enabled = true
|
|
||||||
tracks/4/path = NodePath("Effect:modulate")
|
|
||||||
tracks/4/interp = 1
|
|
||||||
tracks/4/loop_wrap = true
|
|
||||||
tracks/4/keys = {
|
|
||||||
"times": PackedFloat32Array(0),
|
|
||||||
"transitions": PackedFloat32Array(1),
|
|
||||||
"update": 0,
|
|
||||||
"values": [Color(1, 1, 1, 1)]
|
|
||||||
}
|
|
||||||
tracks/5/type = "value"
|
|
||||||
tracks/5/imported = false
|
|
||||||
tracks/5/enabled = true
|
|
||||||
tracks/5/path = NodePath("MarginContainer/PlayerInfo/EnergyInfo:offset_bottom")
|
|
||||||
tracks/5/interp = 1
|
|
||||||
tracks/5/loop_wrap = true
|
|
||||||
tracks/5/keys = {
|
|
||||||
"times": PackedFloat32Array(0),
|
|
||||||
"transitions": PackedFloat32Array(1),
|
|
||||||
"update": 0,
|
"update": 0,
|
||||||
"values": [12.5]
|
"values": [12.5]
|
||||||
}
|
}
|
||||||
@ -114,22 +90,10 @@ tracks/0/keys = {
|
|||||||
tracks/1/type = "value"
|
tracks/1/type = "value"
|
||||||
tracks/1/imported = false
|
tracks/1/imported = false
|
||||||
tracks/1/enabled = true
|
tracks/1/enabled = true
|
||||||
tracks/1/path = NodePath("Effect:visible")
|
tracks/1/path = NodePath("Effect:modulate")
|
||||||
tracks/1/interp = 1
|
tracks/1/interp = 1
|
||||||
tracks/1/loop_wrap = true
|
tracks/1/loop_wrap = true
|
||||||
tracks/1/keys = {
|
tracks/1/keys = {
|
||||||
"times": PackedFloat32Array(0, 0.5),
|
|
||||||
"transitions": PackedFloat32Array(1, 1),
|
|
||||||
"update": 1,
|
|
||||||
"values": [true, false]
|
|
||||||
}
|
|
||||||
tracks/2/type = "value"
|
|
||||||
tracks/2/imported = false
|
|
||||||
tracks/2/enabled = true
|
|
||||||
tracks/2/path = NodePath("Effect:modulate")
|
|
||||||
tracks/2/interp = 1
|
|
||||||
tracks/2/loop_wrap = true
|
|
||||||
tracks/2/keys = {
|
|
||||||
"times": PackedFloat32Array(0, 0.1, 0.266667),
|
"times": PackedFloat32Array(0, 0.1, 0.266667),
|
||||||
"transitions": PackedFloat32Array(1, 1, 1),
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
"update": 0,
|
"update": 0,
|
||||||
@ -142,80 +106,29 @@ length = 0.5
|
|||||||
tracks/0/type = "value"
|
tracks/0/type = "value"
|
||||||
tracks/0/imported = false
|
tracks/0/imported = false
|
||||||
tracks/0/enabled = true
|
tracks/0/enabled = true
|
||||||
tracks/0/path = NodePath("Effect:visible")
|
tracks/0/path = NodePath("Effect:modulate")
|
||||||
tracks/0/interp = 1
|
tracks/0/interp = 1
|
||||||
tracks/0/loop_wrap = true
|
tracks/0/loop_wrap = true
|
||||||
tracks/0/keys = {
|
tracks/0/keys = {
|
||||||
"times": PackedFloat32Array(0, 0.5),
|
|
||||||
"transitions": PackedFloat32Array(1, 1),
|
|
||||||
"update": 1,
|
|
||||||
"values": [true, false]
|
|
||||||
}
|
|
||||||
tracks/1/type = "value"
|
|
||||||
tracks/1/imported = false
|
|
||||||
tracks/1/enabled = true
|
|
||||||
tracks/1/path = NodePath("Effect:modulate")
|
|
||||||
tracks/1/interp = 1
|
|
||||||
tracks/1/loop_wrap = true
|
|
||||||
tracks/1/keys = {
|
|
||||||
"times": PackedFloat32Array(0, 0.1, 0.266667),
|
"times": PackedFloat32Array(0, 0.1, 0.266667),
|
||||||
"transitions": PackedFloat32Array(1, 1, 1),
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
"update": 0,
|
"update": 0,
|
||||||
"values": [Color(0.866667, 0.152941, 0.337255, 0), Color(0.866667, 0.152941, 0.337255, 0.392157), Color(0.866667, 0.152941, 0.337255, 0)]
|
"values": [Color(0.866667, 0.152941, 0.337255, 0), Color(0.866667, 0.152941, 0.337255, 0.392157), Color(0.866667, 0.152941, 0.337255, 0)]
|
||||||
}
|
}
|
||||||
|
|
||||||
[sub_resource type="Animation" id="Animation_k4juk"]
|
[sub_resource type="Animation" id="Animation_ykapk"]
|
||||||
resource_name = "recharge_fade_in"
|
resource_name = "pass_day"
|
||||||
tracks/0/type = "value"
|
tracks/0/type = "value"
|
||||||
tracks/0/imported = false
|
tracks/0/imported = false
|
||||||
tracks/0/enabled = true
|
tracks/0/enabled = true
|
||||||
tracks/0/path = NodePath("RechargeFade:color")
|
tracks/0/path = NodePath("PassDayFade:color")
|
||||||
tracks/0/interp = 1
|
tracks/0/interp = 2
|
||||||
tracks/0/loop_wrap = true
|
tracks/0/loop_wrap = true
|
||||||
tracks/0/keys = {
|
tracks/0/keys = {
|
||||||
"times": PackedFloat32Array(0, 1),
|
"times": PackedFloat32Array(0, 0.4, 0.6, 1),
|
||||||
"transitions": PackedFloat32Array(1, 1),
|
"transitions": PackedFloat32Array(1, 1, 1, 1),
|
||||||
"update": 0,
|
"update": 0,
|
||||||
"values": [Color(0, 0, 0, 0), Color(0, 0, 0, 1)]
|
"values": [Color(0.0627451, 0.0588235, 0.168627, 0), Color(0.0627451, 0.0588235, 0.168627, 1), Color(0.0627451, 0.0588235, 0.168627, 1), Color(0.0627451, 0.0588235, 0.168627, 0)]
|
||||||
}
|
|
||||||
tracks/1/type = "value"
|
|
||||||
tracks/1/imported = false
|
|
||||||
tracks/1/enabled = true
|
|
||||||
tracks/1/path = NodePath("RechargeFade:visible")
|
|
||||||
tracks/1/interp = 1
|
|
||||||
tracks/1/loop_wrap = true
|
|
||||||
tracks/1/keys = {
|
|
||||||
"times": PackedFloat32Array(0),
|
|
||||||
"transitions": PackedFloat32Array(1),
|
|
||||||
"update": 1,
|
|
||||||
"values": [true]
|
|
||||||
}
|
|
||||||
|
|
||||||
[sub_resource type="Animation" id="Animation_fovlv"]
|
|
||||||
resource_name = "recharge_fade_out"
|
|
||||||
tracks/0/type = "value"
|
|
||||||
tracks/0/imported = false
|
|
||||||
tracks/0/enabled = true
|
|
||||||
tracks/0/path = NodePath("RechargeFade:color")
|
|
||||||
tracks/0/interp = 1
|
|
||||||
tracks/0/loop_wrap = true
|
|
||||||
tracks/0/keys = {
|
|
||||||
"times": PackedFloat32Array(0.166667, 1),
|
|
||||||
"transitions": PackedFloat32Array(1, 1),
|
|
||||||
"update": 0,
|
|
||||||
"values": [Color(0, 0, 0, 1), Color(0, 0, 0, 0)]
|
|
||||||
}
|
|
||||||
tracks/1/type = "value"
|
|
||||||
tracks/1/imported = false
|
|
||||||
tracks/1/enabled = true
|
|
||||||
tracks/1/path = NodePath("RechargeFade:visible")
|
|
||||||
tracks/1/interp = 1
|
|
||||||
tracks/1/loop_wrap = true
|
|
||||||
tracks/1/keys = {
|
|
||||||
"times": PackedFloat32Array(1),
|
|
||||||
"transitions": PackedFloat32Array(1),
|
|
||||||
"update": 1,
|
|
||||||
"values": [false]
|
|
||||||
}
|
}
|
||||||
|
|
||||||
[sub_resource type="Animation" id="Animation_2wykm"]
|
[sub_resource type="Animation" id="Animation_2wykm"]
|
||||||
@ -224,34 +137,22 @@ length = 0.5
|
|||||||
tracks/0/type = "value"
|
tracks/0/type = "value"
|
||||||
tracks/0/imported = false
|
tracks/0/imported = false
|
||||||
tracks/0/enabled = true
|
tracks/0/enabled = true
|
||||||
tracks/0/path = NodePath("Effect:visible")
|
tracks/0/path = NodePath("Effect:modulate")
|
||||||
tracks/0/interp = 1
|
tracks/0/interp = 2
|
||||||
tracks/0/loop_wrap = true
|
tracks/0/loop_wrap = true
|
||||||
tracks/0/keys = {
|
tracks/0/keys = {
|
||||||
"times": PackedFloat32Array(0, 0.5),
|
|
||||||
"transitions": PackedFloat32Array(1, 1),
|
|
||||||
"update": 1,
|
|
||||||
"values": [true, false]
|
|
||||||
}
|
|
||||||
tracks/1/type = "value"
|
|
||||||
tracks/1/imported = false
|
|
||||||
tracks/1/enabled = true
|
|
||||||
tracks/1/path = NodePath("Effect:modulate")
|
|
||||||
tracks/1/interp = 2
|
|
||||||
tracks/1/loop_wrap = true
|
|
||||||
tracks/1/keys = {
|
|
||||||
"times": PackedFloat32Array(0, 0.133333, 0.5),
|
"times": PackedFloat32Array(0, 0.133333, 0.5),
|
||||||
"transitions": PackedFloat32Array(1, 1, 1),
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
"update": 0,
|
"update": 0,
|
||||||
"values": [Color(0.67451, 0.52549, 0.203922, 0), Color(0.67451, 0.52549, 0.203922, 0.572549), Color(0.67451, 0.52549, 0.203922, 0)]
|
"values": [Color(0.67451, 0.52549, 0.203922, 0), Color(0.67451, 0.52549, 0.203922, 0.572549), Color(0.67451, 0.52549, 0.203922, 0)]
|
||||||
}
|
}
|
||||||
tracks/2/type = "value"
|
tracks/1/type = "value"
|
||||||
tracks/2/imported = false
|
tracks/1/imported = false
|
||||||
tracks/2/enabled = true
|
tracks/1/enabled = true
|
||||||
tracks/2/path = NodePath("MarginContainer/PlayerInfo/EnergyInfo:offset_bottom")
|
tracks/1/path = NodePath("MarginContainer/PlayerInfo/EnergyInfo:offset_bottom")
|
||||||
tracks/2/interp = 2
|
tracks/1/interp = 2
|
||||||
tracks/2/loop_wrap = true
|
tracks/1/loop_wrap = true
|
||||||
tracks/2/keys = {
|
tracks/1/keys = {
|
||||||
"times": PackedFloat32Array(0, 0.233333, 0.5),
|
"times": PackedFloat32Array(0, 0.233333, 0.5),
|
||||||
"transitions": PackedFloat32Array(1, 1, 1),
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
"update": 0,
|
"update": 0,
|
||||||
@ -263,8 +164,7 @@ _data = {
|
|||||||
&"RESET": SubResource("Animation_iyvkh"),
|
&"RESET": SubResource("Animation_iyvkh"),
|
||||||
&"no_energy_left": SubResource("Animation_n4kem"),
|
&"no_energy_left": SubResource("Animation_n4kem"),
|
||||||
&"not_permitted": SubResource("Animation_id0t5"),
|
&"not_permitted": SubResource("Animation_id0t5"),
|
||||||
&"recharge_fade_in": SubResource("Animation_k4juk"),
|
&"pass_day": SubResource("Animation_ykapk"),
|
||||||
&"recharge_fade_out": SubResource("Animation_fovlv"),
|
|
||||||
&"upgrade": SubResource("Animation_2wykm")
|
&"upgrade": SubResource("Animation_2wykm")
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -360,16 +260,6 @@ label_settings = ExtResource("4_ujg5r")
|
|||||||
horizontal_alignment = 1
|
horizontal_alignment = 1
|
||||||
vertical_alignment = 1
|
vertical_alignment = 1
|
||||||
|
|
||||||
[node name="DayPass" type="Button" parent="MarginContainer"]
|
|
||||||
layout_mode = 2
|
|
||||||
size_flags_horizontal = 8
|
|
||||||
size_flags_vertical = 8
|
|
||||||
focus_mode = 0
|
|
||||||
mouse_filter = 1
|
|
||||||
theme = ExtResource("2_nq5i2")
|
|
||||||
text = "Recharge"
|
|
||||||
icon = ExtResource("4_k4juk")
|
|
||||||
|
|
||||||
[node name="ItemInfo" type="TextureRect" parent="MarginContainer"]
|
[node name="ItemInfo" type="TextureRect" parent="MarginContainer"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
custom_minimum_size = Vector2(0, 300)
|
custom_minimum_size = Vector2(0, 300)
|
||||||
@ -444,16 +334,16 @@ focus_mode = 0
|
|||||||
mouse_filter = 1
|
mouse_filter = 1
|
||||||
icon = ExtResource("9_2wykm")
|
icon = ExtResource("9_2wykm")
|
||||||
|
|
||||||
[node name="RechargeFade" type="ColorRect" parent="."]
|
[node name="PassDayFade" type="ColorRect" parent="."]
|
||||||
physics_interpolation_mode = 0
|
physics_interpolation_mode = 0
|
||||||
visible = false
|
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
anchors_preset = 15
|
anchors_preset = 15
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
anchor_bottom = 1.0
|
anchor_bottom = 1.0
|
||||||
grow_horizontal = 2
|
grow_horizontal = 2
|
||||||
grow_vertical = 2
|
grow_vertical = 2
|
||||||
color = Color(0, 0, 0, 0)
|
mouse_filter = 2
|
||||||
|
color = Color(0.0627451, 0.0588235, 0.168627, 0)
|
||||||
|
|
||||||
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
|
||||||
libraries = {
|
libraries = {
|
||||||
@ -466,7 +356,7 @@ offset_right = 40.0
|
|||||||
offset_bottom = 40.0
|
offset_bottom = 40.0
|
||||||
|
|
||||||
[node name="Effect" type="TextureRect" parent="."]
|
[node name="Effect" type="TextureRect" parent="."]
|
||||||
visible = false
|
modulate = Color(1, 1, 1, 0)
|
||||||
layout_mode = 1
|
layout_mode = 1
|
||||||
anchors_preset = 15
|
anchors_preset = 15
|
||||||
anchor_right = 1.0
|
anchor_right = 1.0
|
||||||
@ -476,5 +366,4 @@ grow_vertical = 2
|
|||||||
mouse_filter = 2
|
mouse_filter = 2
|
||||||
texture = SubResource("GradientTexture2D_id0t5")
|
texture = SubResource("GradientTexture2D_id0t5")
|
||||||
|
|
||||||
[connection signal="pressed" from="MarginContainer/DayPass" to="." method="_on_day_pass_pressed"]
|
|
||||||
[connection signal="pressed" from="MarginContainer/TopRightContent/Pause" to="." method="_on_pause_pressed"]
|
[connection signal="pressed" from="MarginContainer/TopRightContent/Pause" to="." method="_on_pause_pressed"]
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
[gd_scene load_steps=9 format=3 uid="uid://csiacsndm62ll"]
|
[gd_scene load_steps=9 format=3 uid="uid://csiacsndm62ll"]
|
||||||
|
|
||||||
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/game/ressources/default_theme.tres" id="1_51ks3"]
|
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/ressources/default_theme.tres" id="1_51ks3"]
|
||||||
[ext_resource type="Script" uid="uid://crt2d4m5ba25i" path="res://gui/game/pause/scripts/pause.gd" id="1_he4ox"]
|
[ext_resource type="Script" uid="uid://crt2d4m5ba25i" path="res://gui/game/pause/scripts/pause.gd" id="1_he4ox"]
|
||||||
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/game/ressources/fonts/spincycle_ot.otf" id="2_8d1kg"]
|
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/ressources/fonts/spincycle_ot.otf" id="2_8d1kg"]
|
||||||
[ext_resource type="LabelSettings" uid="uid://dqwayi8yjwau2" path="res://gui/game/ressources/default_label_settings.tres" id="3_0pdto"]
|
[ext_resource type="LabelSettings" uid="uid://dqwayi8yjwau2" path="res://gui/ressources/title_label_settings.tres" id="3_0pdto"]
|
||||||
[ext_resource type="Texture2D" uid="uid://vmsn54d1ptih" path="res://gui/game/pause/assets/icons/player-play.svg" id="5_apjlw"]
|
[ext_resource type="Texture2D" uid="uid://vmsn54d1ptih" path="res://gui/game/pause/assets/icons/player-play.svg" id="5_apjlw"]
|
||||||
[ext_resource type="Texture2D" uid="uid://bewr0t1wi8pff" path="res://gui/game/pause/assets/icons/rotate.svg" id="6_58dya"]
|
[ext_resource type="Texture2D" uid="uid://bewr0t1wi8pff" path="res://gui/game/pause/assets/icons/rotate.svg" id="6_58dya"]
|
||||||
[ext_resource type="Texture2D" uid="uid://dex283rx00fjb" path="res://gui/game/pause/assets/icons/logout.svg" id="7_yj6f1"]
|
[ext_resource type="Texture2D" uid="uid://dex283rx00fjb" path="res://gui/game/pause/assets/icons/logout.svg" id="7_yj6f1"]
|
||||||
|
|||||||
@ -1,10 +1,6 @@
|
|||||||
extends Control
|
extends Control
|
||||||
class_name GameGui
|
class_name GameGui
|
||||||
|
|
||||||
signal game_click
|
|
||||||
signal day_pass_pressed
|
|
||||||
signal day_pass_proceed
|
|
||||||
signal day_pass_finished
|
|
||||||
signal pause_asked
|
signal pause_asked
|
||||||
|
|
||||||
func _on_player_updated(player:Player):
|
func _on_player_updated(player:Player):
|
||||||
@ -19,16 +15,10 @@ func _on_player_updated(player:Player):
|
|||||||
%ItemDesc.text = item.description
|
%ItemDesc.text = item.description
|
||||||
|
|
||||||
func _on_day_pass_pressed():
|
func _on_day_pass_pressed():
|
||||||
day_pass_pressed.emit()
|
|
||||||
$AnimationPlayer.play("recharge_fade_in")
|
|
||||||
await $AnimationPlayer.animation_finished
|
await $AnimationPlayer.animation_finished
|
||||||
day_pass_proceed.emit()
|
|
||||||
$AnimationPlayer.play("recharge_fade_out")
|
$AnimationPlayer.play("recharge_fade_out")
|
||||||
await $AnimationPlayer.animation_finished
|
await $AnimationPlayer.animation_finished
|
||||||
day_pass_finished.emit()
|
|
||||||
|
|
||||||
func _on_game_action_button_down():
|
|
||||||
game_click.emit()
|
|
||||||
|
|
||||||
func _on_planet_updated(planet:Planet):
|
func _on_planet_updated(planet:Planet):
|
||||||
%DayCount.text = "Day " + str(planet.day)
|
%DayCount.text = "Day " + str(planet.day)
|
||||||
@ -49,3 +39,9 @@ func _on_player_upgraded():
|
|||||||
|
|
||||||
func _on_player_action_not_permitted():
|
func _on_player_action_not_permitted():
|
||||||
$AnimationPlayer.play("not_permitted")
|
$AnimationPlayer.play("not_permitted")
|
||||||
|
|
||||||
|
func _on_planet_pass_day_started(planet):
|
||||||
|
$AnimationPlayer.speed_scale = 1/(planet.PASS_DAY_ANIMATION_TIME)
|
||||||
|
$AnimationPlayer.play("pass_day")
|
||||||
|
await $AnimationPlayer.animation_finished
|
||||||
|
$AnimationPlayer.speed_scale = 1
|
||||||
|
|||||||
@ -1,9 +1,9 @@
|
|||||||
[gd_scene load_steps=8 format=3 uid="uid://v41hfc7haaye"]
|
[gd_scene load_steps=8 format=3 uid="uid://v41hfc7haaye"]
|
||||||
|
|
||||||
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/game/ressources/default_theme.tres" id="1_cl67j"]
|
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/ressources/default_theme.tres" id="1_cl67j"]
|
||||||
[ext_resource type="Script" uid="uid://b3wuxv04clyed" path="res://gui/game/win/scripts/win.gd" id="1_sehw2"]
|
[ext_resource type="Script" uid="uid://b3wuxv04clyed" path="res://gui/game/win/scripts/win.gd" id="1_sehw2"]
|
||||||
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/game/ressources/fonts/spincycle_ot.otf" id="2_sehw2"]
|
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/ressources/fonts/spincycle_ot.otf" id="2_sehw2"]
|
||||||
[ext_resource type="LabelSettings" uid="uid://dqwayi8yjwau2" path="res://gui/game/ressources/default_label_settings.tres" id="3_0b3c6"]
|
[ext_resource type="LabelSettings" uid="uid://dqwayi8yjwau2" path="res://gui/ressources/title_label_settings.tres" id="3_0b3c6"]
|
||||||
[ext_resource type="Texture2D" uid="uid://bewr0t1wi8pff" path="res://gui/game/pause/assets/icons/rotate.svg" id="4_8p3aj"]
|
[ext_resource type="Texture2D" uid="uid://bewr0t1wi8pff" path="res://gui/game/pause/assets/icons/rotate.svg" id="4_8p3aj"]
|
||||||
[ext_resource type="Texture2D" uid="uid://dex283rx00fjb" path="res://gui/game/pause/assets/icons/logout.svg" id="5_j3wid"]
|
[ext_resource type="Texture2D" uid="uid://dex283rx00fjb" path="res://gui/game/pause/assets/icons/logout.svg" id="5_j3wid"]
|
||||||
|
|
||||||
|
|||||||
1
gui/menu/assets/icons/users-group.svg
Normal file
1
gui/menu/assets/icons/users-group.svg
Normal file
@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="#ffffff" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="icon icon-tabler icons-tabler-outline icon-tabler-users-group"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M10 13a2 2 0 1 0 4 0a2 2 0 0 0 -4 0" /><path d="M8 21v-1a2 2 0 0 1 2 -2h4a2 2 0 0 1 2 2v1" /><path d="M15 5a2 2 0 1 0 4 0a2 2 0 0 0 -4 0" /><path d="M17 10h2a2 2 0 0 1 2 2v1" /><path d="M5 5a2 2 0 1 0 4 0a2 2 0 0 0 -4 0" /><path d="M3 13v-1a2 2 0 0 1 2 -2h2" /></svg>
|
||||||
|
After Width: | Height: | Size: 583 B |
37
gui/menu/assets/icons/users-group.svg.import
Normal file
37
gui/menu/assets/icons/users-group.svg.import
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
[remap]
|
||||||
|
|
||||||
|
importer="texture"
|
||||||
|
type="CompressedTexture2D"
|
||||||
|
uid="uid://b38hdpsvqcwg8"
|
||||||
|
path="res://.godot/imported/users-group.svg-65aad5cfa47be548675b81fab7ab9db6.ctex"
|
||||||
|
metadata={
|
||||||
|
"vram_texture": false
|
||||||
|
}
|
||||||
|
|
||||||
|
[deps]
|
||||||
|
|
||||||
|
source_file="res://gui/menu/assets/icons/users-group.svg"
|
||||||
|
dest_files=["res://.godot/imported/users-group.svg-65aad5cfa47be548675b81fab7ab9db6.ctex"]
|
||||||
|
|
||||||
|
[params]
|
||||||
|
|
||||||
|
compress/mode=0
|
||||||
|
compress/high_quality=false
|
||||||
|
compress/lossy_quality=0.7
|
||||||
|
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/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
|
||||||
|
svg/scale=1.0
|
||||||
|
editor/scale_with_editor_scale=false
|
||||||
|
editor/convert_colors_with_editor_theme=false
|
||||||
|
Before Width: | Height: | Size: 285 KiB After Width: | Height: | Size: 285 KiB |
@ -3,15 +3,15 @@
|
|||||||
importer="texture"
|
importer="texture"
|
||||||
type="CompressedTexture2D"
|
type="CompressedTexture2D"
|
||||||
uid="uid://qx75h1k3wmm1"
|
uid="uid://qx75h1k3wmm1"
|
||||||
path="res://.godot/imported/Tablette info.png-b4fbef928a773f595b589d989235c266.ctex"
|
path="res://.godot/imported/Tablette info.png-e89cd3fdb4a303341f3bbad730de279c.ctex"
|
||||||
metadata={
|
metadata={
|
||||||
"vram_texture": false
|
"vram_texture": false
|
||||||
}
|
}
|
||||||
|
|
||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://gui/game/ressources/Tablette info.png"
|
source_file="res://gui/ressources/Tablette info.png"
|
||||||
dest_files=["res://.godot/imported/Tablette info.png-b4fbef928a773f595b589d989235c266.ctex"]
|
dest_files=["res://.godot/imported/Tablette info.png-e89cd3fdb4a303341f3bbad730de279c.ctex"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
@ -1,6 +1,6 @@
|
|||||||
[gd_resource type="Theme" load_steps=5 format=3 uid="uid://bgcmd213j6gk1"]
|
[gd_resource type="Theme" load_steps=5 format=3 uid="uid://bgcmd213j6gk1"]
|
||||||
|
|
||||||
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/game/ressources/fonts/spincycle_ot.otf" id="1_hv6r3"]
|
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/ressources/fonts/spincycle_ot.otf" id="1_hv6r3"]
|
||||||
|
|
||||||
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_hv6r3"]
|
[sub_resource type="StyleBoxFlat" id="StyleBoxFlat_hv6r3"]
|
||||||
bg_color = Color(0.976471, 0.741176, 0.4, 1)
|
bg_color = Color(0.976471, 0.741176, 0.4, 1)
|
||||||
@ -3,12 +3,12 @@
|
|||||||
importer="font_data_dynamic"
|
importer="font_data_dynamic"
|
||||||
type="FontFile"
|
type="FontFile"
|
||||||
uid="uid://byyfovm1ha5ya"
|
uid="uid://byyfovm1ha5ya"
|
||||||
path="res://.godot/imported/AtomicMd-3zXDZ.ttf-72972057c8e238d8e668e97b2f9f70c6.fontdata"
|
path="res://.godot/imported/AtomicMd-3zXDZ.ttf-0d8ee2c5d0b5b97084be121e0cf9710b.fontdata"
|
||||||
|
|
||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://gui/game/ressources/fonts/AtomicMd-3zXDZ.ttf"
|
source_file="res://gui/ressources/fonts/AtomicMd-3zXDZ.ttf"
|
||||||
dest_files=["res://.godot/imported/AtomicMd-3zXDZ.ttf-72972057c8e238d8e668e97b2f9f70c6.fontdata"]
|
dest_files=["res://.godot/imported/AtomicMd-3zXDZ.ttf-0d8ee2c5d0b5b97084be121e0cf9710b.fontdata"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
@ -3,12 +3,12 @@
|
|||||||
importer="font_data_dynamic"
|
importer="font_data_dynamic"
|
||||||
type="FontFile"
|
type="FontFile"
|
||||||
uid="uid://c8xf3tfnpufk3"
|
uid="uid://c8xf3tfnpufk3"
|
||||||
path="res://.godot/imported/spincycle_3d_ot.otf-21ea869159b3b8db074d7006cdac52ac.fontdata"
|
path="res://.godot/imported/spincycle_3d_ot.otf-f71d33fbaded9da2ba85d0eb20bfd1e1.fontdata"
|
||||||
|
|
||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://gui/game/ressources/fonts/spincycle_3d_ot.otf"
|
source_file="res://gui/ressources/fonts/spincycle_3d_ot.otf"
|
||||||
dest_files=["res://.godot/imported/spincycle_3d_ot.otf-21ea869159b3b8db074d7006cdac52ac.fontdata"]
|
dest_files=["res://.godot/imported/spincycle_3d_ot.otf-f71d33fbaded9da2ba85d0eb20bfd1e1.fontdata"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
@ -3,12 +3,12 @@
|
|||||||
importer="font_data_dynamic"
|
importer="font_data_dynamic"
|
||||||
type="FontFile"
|
type="FontFile"
|
||||||
uid="uid://cpnsnrqhfkj3k"
|
uid="uid://cpnsnrqhfkj3k"
|
||||||
path="res://.godot/imported/spincycle_ot.otf-27679d167ed7a37649e3338357150952.fontdata"
|
path="res://.godot/imported/spincycle_ot.otf-be21809daa8fde21c00f1cf664ce2342.fontdata"
|
||||||
|
|
||||||
[deps]
|
[deps]
|
||||||
|
|
||||||
source_file="res://gui/game/ressources/fonts/spincycle_ot.otf"
|
source_file="res://gui/ressources/fonts/spincycle_ot.otf"
|
||||||
dest_files=["res://.godot/imported/spincycle_ot.otf-27679d167ed7a37649e3338357150952.fontdata"]
|
dest_files=["res://.godot/imported/spincycle_ot.otf-be21809daa8fde21c00f1cf664ce2342.fontdata"]
|
||||||
|
|
||||||
[params]
|
[params]
|
||||||
|
|
||||||
@ -1,6 +1,6 @@
|
|||||||
[gd_resource type="LabelSettings" load_steps=2 format=3 uid="uid://dqwayi8yjwau2"]
|
[gd_resource type="LabelSettings" load_steps=2 format=3 uid="uid://dqwayi8yjwau2"]
|
||||||
|
|
||||||
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/game/ressources/fonts/spincycle_ot.otf" id="1_w0wva"]
|
[ext_resource type="FontFile" uid="uid://cpnsnrqhfkj3k" path="res://gui/ressources/fonts/spincycle_ot.otf" id="1_w0wva"]
|
||||||
|
|
||||||
[resource]
|
[resource]
|
||||||
font = ExtResource("1_w0wva")
|
font = ExtResource("1_w0wva")
|
||||||
@ -12,7 +12,7 @@ config_version=5
|
|||||||
|
|
||||||
config/name="Seeding Planets"
|
config/name="Seeding Planets"
|
||||||
config/description="Seeding planets is a survival, managment and cosy game in which you play a little gardener robot."
|
config/description="Seeding planets is a survival, managment and cosy game in which you play a little gardener robot."
|
||||||
config/version="proto-1.1"
|
config/version="proto-1.2"
|
||||||
run/main_scene="uid://c5bruelvqbm1k"
|
run/main_scene="uid://c5bruelvqbm1k"
|
||||||
config/features=PackedStringArray("4.4", "Forward Plus")
|
config/features=PackedStringArray("4.4", "Forward Plus")
|
||||||
config/icon="uid://df0y0s666ui4h"
|
config/icon="uid://df0y0s666ui4h"
|
||||||
|
|||||||
111
root.tscn
111
root.tscn
@ -1,18 +1,20 @@
|
|||||||
[gd_scene load_steps=8 format=3 uid="uid://c5bruelvqbm1k"]
|
[gd_scene load_steps=9 format=3 uid="uid://c5bruelvqbm1k"]
|
||||||
|
|
||||||
[ext_resource type="Script" uid="uid://c54457tbocdwk" path="res://gui/menu/scripts/menu.gd" id="1_bf3um"]
|
[ext_resource type="Script" uid="uid://c54457tbocdwk" path="res://gui/menu/scripts/menu.gd" id="1_bf3um"]
|
||||||
[ext_resource type="Texture2D" uid="uid://bnrjnvceprxfn" path="res://stages/terrain/planet/assets/textures/sol_gamejam_normal.png" id="2_huihk"]
|
[ext_resource type="Texture2D" uid="uid://bnrjnvceprxfn" path="res://stages/terrain/planet/assets/textures/sol_gamejam_normal.png" id="2_huihk"]
|
||||||
[ext_resource type="Texture2D" uid="uid://dcn4cq53h1qiy" path="res://stages/terrain/planet/resources/textures/sol_gamejam_fleurs_transp.png" id="3_tw3kd"]
|
[ext_resource type="Texture2D" uid="uid://dcn4cq53h1qiy" path="res://stages/terrain/planet/resources/textures/sol_gamejam_fleurs_transp.png" id="3_tw3kd"]
|
||||||
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/game/ressources/default_theme.tres" id="4_gd4vy"]
|
[ext_resource type="Theme" uid="uid://bgcmd213j6gk1" path="res://gui/ressources/default_theme.tres" id="4_gd4vy"]
|
||||||
[ext_resource type="Texture2D" uid="uid://nx4wxpr6mk8l" path="res://gui/menu/assets/texture/SeedingPlanetsLogo.png" id="5_qw60f"]
|
[ext_resource type="Texture2D" uid="uid://nx4wxpr6mk8l" path="res://gui/menu/assets/texture/SeedingPlanetsLogo.png" id="5_qw60f"]
|
||||||
[ext_resource type="Texture2D" uid="uid://03ijmo6xlytu" path="res://gui/menu/assets/texture/abre1glow.png" id="6_eji0w"]
|
[ext_resource type="Texture2D" uid="uid://03ijmo6xlytu" path="res://gui/menu/assets/texture/abre1glow.png" id="6_eji0w"]
|
||||||
[ext_resource type="Texture2D" uid="uid://dcgnamu7sb3ov" path="res://gui/game/assets/icons/bolt.svg" id="7_qwhpj"]
|
[ext_resource type="Texture2D" uid="uid://dcgnamu7sb3ov" path="res://gui/game/assets/icons/bolt.svg" id="7_qwhpj"]
|
||||||
|
[ext_resource type="LabelSettings" uid="uid://dqwayi8yjwau2" path="res://gui/ressources/title_label_settings.tres" id="8_bf3um"]
|
||||||
|
|
||||||
[node name="Root" type="Node2D"]
|
[node name="Root" type="Node2D"]
|
||||||
script = ExtResource("1_bf3um")
|
script = ExtResource("1_bf3um")
|
||||||
start_scene_path = "uid://d28cp7a21kwou"
|
start_scene_path = "uid://d28cp7a21kwou"
|
||||||
|
|
||||||
[node name="CanvasLayer" type="CanvasLayer" parent="."]
|
[node name="CanvasLayer" type="CanvasLayer" parent="."]
|
||||||
|
process_mode = 3
|
||||||
|
|
||||||
[node name="Background1" type="TextureRect" parent="CanvasLayer"]
|
[node name="Background1" type="TextureRect" parent="CanvasLayer"]
|
||||||
z_index = -1
|
z_index = -1
|
||||||
@ -44,17 +46,8 @@ grow_horizontal = 2
|
|||||||
grow_vertical = 2
|
grow_vertical = 2
|
||||||
theme = ExtResource("4_gd4vy")
|
theme = ExtResource("4_gd4vy")
|
||||||
|
|
||||||
[node name="Logo" type="TextureRect" parent="CanvasLayer/MarginContainer"]
|
|
||||||
z_index = 2
|
|
||||||
custom_minimum_size = Vector2(500, 0)
|
|
||||||
layout_mode = 2
|
|
||||||
size_flags_horizontal = 0
|
|
||||||
size_flags_vertical = 0
|
|
||||||
texture = ExtResource("5_qw60f")
|
|
||||||
expand_mode = 5
|
|
||||||
stretch_mode = 4
|
|
||||||
|
|
||||||
[node name="Tree" type="TextureRect" parent="CanvasLayer/MarginContainer"]
|
[node name="Tree" type="TextureRect" parent="CanvasLayer/MarginContainer"]
|
||||||
|
z_index = -1
|
||||||
custom_minimum_size = Vector2(500, 0)
|
custom_minimum_size = Vector2(500, 0)
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
size_flags_horizontal = 4
|
size_flags_horizontal = 4
|
||||||
@ -63,15 +56,6 @@ texture = ExtResource("6_eji0w")
|
|||||||
expand_mode = 4
|
expand_mode = 4
|
||||||
stretch_mode = 4
|
stretch_mode = 4
|
||||||
|
|
||||||
[node name="Start" type="Button" parent="CanvasLayer/MarginContainer"]
|
|
||||||
layout_mode = 2
|
|
||||||
size_flags_horizontal = 8
|
|
||||||
size_flags_vertical = 8
|
|
||||||
theme = ExtResource("4_gd4vy")
|
|
||||||
theme_override_font_sizes/font_size = 33
|
|
||||||
text = "Start"
|
|
||||||
icon = ExtResource("7_qwhpj")
|
|
||||||
|
|
||||||
[node name="Version" type="Label" parent="CanvasLayer/MarginContainer"]
|
[node name="Version" type="Label" parent="CanvasLayer/MarginContainer"]
|
||||||
unique_name_in_owner = true
|
unique_name_in_owner = true
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
@ -79,19 +63,84 @@ size_flags_horizontal = 8
|
|||||||
size_flags_vertical = 0
|
size_flags_vertical = 0
|
||||||
text = "Version"
|
text = "Version"
|
||||||
|
|
||||||
[node name="Credits" type="Label" parent="CanvasLayer/MarginContainer"]
|
[node name="GridContainer" type="HBoxContainer" parent="CanvasLayer/MarginContainer"]
|
||||||
layout_mode = 2
|
layout_mode = 2
|
||||||
size_flags_horizontal = 0
|
alignment = 1
|
||||||
size_flags_vertical = 8
|
|
||||||
text = "Art
|
[node name="VBoxContainer" type="VBoxContainer" parent="CanvasLayer/MarginContainer/GridContainer"]
|
||||||
Céline Ferrand / Lunarde
|
layout_mode = 2
|
||||||
|
size_flags_horizontal = 3
|
||||||
|
size_flags_vertical = 4
|
||||||
|
theme_override_constants/separation = 20
|
||||||
|
alignment = 1
|
||||||
|
|
||||||
|
[node name="Logo" type="TextureRect" parent="CanvasLayer/MarginContainer/GridContainer/VBoxContainer"]
|
||||||
|
z_index = 2
|
||||||
|
custom_minimum_size = Vector2(600, 0)
|
||||||
|
layout_mode = 2
|
||||||
|
size_flags_horizontal = 4
|
||||||
|
size_flags_vertical = 0
|
||||||
|
texture = ExtResource("5_qw60f")
|
||||||
|
expand_mode = 5
|
||||||
|
stretch_mode = 5
|
||||||
|
|
||||||
|
[node name="Start" type="Button" parent="CanvasLayer/MarginContainer/GridContainer/VBoxContainer"]
|
||||||
|
unique_name_in_owner = true
|
||||||
|
z_index = 1
|
||||||
|
layout_mode = 2
|
||||||
|
size_flags_horizontal = 4
|
||||||
|
size_flags_vertical = 4
|
||||||
|
theme = ExtResource("4_gd4vy")
|
||||||
|
theme_override_font_sizes/font_size = 33
|
||||||
|
text = "Start"
|
||||||
|
icon = ExtResource("7_qwhpj")
|
||||||
|
|
||||||
|
[node name="Credits" type="VBoxContainer" parent="CanvasLayer/MarginContainer/GridContainer"]
|
||||||
|
layout_mode = 2
|
||||||
|
size_flags_horizontal = 3
|
||||||
|
size_flags_vertical = 4
|
||||||
|
|
||||||
|
[node name="ArtTitle" type="Label" parent="CanvasLayer/MarginContainer/GridContainer/Credits"]
|
||||||
|
layout_mode = 2
|
||||||
|
size_flags_horizontal = 3
|
||||||
|
theme = ExtResource("4_gd4vy")
|
||||||
|
text = "Art"
|
||||||
|
label_settings = ExtResource("8_bf3um")
|
||||||
|
horizontal_alignment = 1
|
||||||
|
|
||||||
|
[node name="ArtText" type="Label" parent="CanvasLayer/MarginContainer/GridContainer/Credits"]
|
||||||
|
layout_mode = 2
|
||||||
|
text = "Céline Ferrand / Lunarde
|
||||||
Camille Fleury
|
Camille Fleury
|
||||||
|
"
|
||||||
|
horizontal_alignment = 1
|
||||||
|
|
||||||
Development / Game Design
|
[node name="DevTitle" type="Label" parent="CanvasLayer/MarginContainer/GridContainer/Credits"]
|
||||||
Zacharie Guet / Zink
|
layout_mode = 2
|
||||||
|
size_flags_horizontal = 3
|
||||||
|
theme = ExtResource("4_gd4vy")
|
||||||
|
text = "Development / Game Design"
|
||||||
|
label_settings = ExtResource("8_bf3um")
|
||||||
|
horizontal_alignment = 1
|
||||||
|
|
||||||
|
[node name="DevText" type="Label" parent="CanvasLayer/MarginContainer/GridContainer/Credits"]
|
||||||
|
layout_mode = 2
|
||||||
|
text = "Zacharie Guet / Zink
|
||||||
Victor Robert Jaunet / Altaezio
|
Victor Robert Jaunet / Altaezio
|
||||||
|
"
|
||||||
|
horizontal_alignment = 1
|
||||||
|
|
||||||
Music
|
[node name="MusicTitle" type="Label" parent="CanvasLayer/MarginContainer/GridContainer/Credits"]
|
||||||
Niels / Nilou"
|
layout_mode = 2
|
||||||
|
size_flags_horizontal = 3
|
||||||
|
theme = ExtResource("4_gd4vy")
|
||||||
|
text = "Music"
|
||||||
|
label_settings = ExtResource("8_bf3um")
|
||||||
|
horizontal_alignment = 1
|
||||||
|
|
||||||
[connection signal="pressed" from="CanvasLayer/MarginContainer/Start" to="." method="_on_start_pressed"]
|
[node name="MusicText" type="Label" parent="CanvasLayer/MarginContainer/GridContainer/Credits"]
|
||||||
|
layout_mode = 2
|
||||||
|
text = "Niels / Nilou"
|
||||||
|
horizontal_alignment = 1
|
||||||
|
|
||||||
|
[connection signal="pressed" from="CanvasLayer/MarginContainer/GridContainer/VBoxContainer/Start" to="." method="_on_start_pressed"]
|
||||||
|
|||||||
@ -3,7 +3,11 @@ class_name Planet
|
|||||||
|
|
||||||
signal planet_updated(planet : Planet)
|
signal planet_updated(planet : Planet)
|
||||||
signal day_limit_exceed(planet : Planet)
|
signal day_limit_exceed(planet : Planet)
|
||||||
|
signal pass_day_started(planet : Planet)
|
||||||
|
signal pass_day_proceeded(planet : Planet)
|
||||||
|
signal pass_day_ended(planet : Planet)
|
||||||
|
|
||||||
|
const PASS_DAY_ANIMATION_TIME : float = 1.5
|
||||||
const DAY_LIMIT : int = 10
|
const DAY_LIMIT : int = 10
|
||||||
const PLANET_TEXTURE_SCALE : float = 5.0
|
const PLANET_TEXTURE_SCALE : float = 5.0
|
||||||
|
|
||||||
@ -115,11 +119,28 @@ func is_there_contamination(point : Vector2) -> bool:
|
|||||||
return terrainData.get_contamination(point) < 0.5
|
return terrainData.get_contamination(point) < 0.5
|
||||||
|
|
||||||
func pass_day():
|
func pass_day():
|
||||||
|
for e : Node2D in entityContainer.get_children():
|
||||||
|
if e.has_method("_start_pass_day"):
|
||||||
|
e._start_pass_day()
|
||||||
|
pass_day_started.emit(self)
|
||||||
|
await get_tree().create_timer(PASS_DAY_ANIMATION_TIME/2.).timeout
|
||||||
|
|
||||||
|
generate_loot()
|
||||||
|
pass_day_proceeded.emit(self)
|
||||||
day += 1
|
day += 1
|
||||||
for e : Node2D in entityContainer.get_children():
|
for e : Node2D in entityContainer.get_children():
|
||||||
if e.has_method("_pass_day"):
|
if e.has_method("_pass_day"):
|
||||||
e._pass_day()
|
e._pass_day()
|
||||||
generate_loot()
|
|
||||||
|
pass_day_ended.emit(self)
|
||||||
|
await get_tree().create_timer(PASS_DAY_ANIMATION_TIME/2.).timeout
|
||||||
|
for e : Node2D in entityContainer.get_children():
|
||||||
|
if e.has_method("_end_pass_day"):
|
||||||
|
e._end_pass_day()
|
||||||
|
|
||||||
|
decontamination_coverage = terrainData.get_decontamination_coverage()
|
||||||
|
if day + 1 > DAY_LIMIT:
|
||||||
|
day_limit_exceed.emit(self)
|
||||||
|
|
||||||
func generate_loot(number : int = loot_number.pick_random()):
|
func generate_loot(number : int = loot_number.pick_random()):
|
||||||
for i in range(number):
|
for i in range(number):
|
||||||
@ -137,11 +158,3 @@ func generate_loot(number : int = loot_number.pick_random()):
|
|||||||
)
|
)
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
func _on_root_gui_day_pass_proceed():
|
|
||||||
pass_day()
|
|
||||||
|
|
||||||
func _on_root_gui_day_pass_finished():
|
|
||||||
decontamination_coverage = terrainData.get_decontamination_coverage()
|
|
||||||
if day + 1 > DAY_LIMIT:
|
|
||||||
day_limit_exceed.emit(self)
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user