Et toujours du dev pour la béta

* Evolution de l'histoire avec de nouveaux dialogues, une plus grande durée de vie du jeu, des nouvelles zones d'histoire...
* Suppression du mode infini
* Ajout d'un écran des mutations découvertes
* Ajout d'un nouveau mécanisme de respawn situé dans le vaissau
* Ajout de 2 nouveaux modificateurs de région
* Quatre nouveaux artefacts
* Visuel de la décontamination de la planète 3D en cours de la partie
* Ajout d'une annonce visuelle des scène du jeu
* Fix sur la mutation Généreux pour être en accord avec sa description
* Amélioration de l'effet de la mutation Purification
* Fix de la mutation sociale aux niveau supérieurs
* Ajout d'un effet visuel de réacteur sur le joueur 3D
* Fix sur l'annonce de nouveaux objets qui se déclenchaient à une nouvelle run
* Amélioration des animation et des informations données dans le vaisseau
* Correction mineure des traductions
This commit is contained in:
2026-04-28 23:41:36 +02:00
parent 7ae362a3a5
commit 91e266ec85
269 changed files with 4393 additions and 1699 deletions

View File

@@ -22,7 +22,7 @@ func stop_audio():
audio_player.stop()
func _on_mouse_entered():
if hover_animation_player:
if hover_animation_player and interactable:
hover_animation_player.play("hover")
if inspectable:
Pointer.inspect(self)

View File

@@ -0,0 +1,73 @@
[remap]
importer="scene"
importer_version=1
type="PackedScene"
uid="uid://bihsgpfqaiqml"
path="res://.godot/imported/orchid_saver.blend-2ed183e213d591791b3e5f1318afc991.scn"
[deps]
source_file="res://entities/interactable_3d/orchid_saver/assets/3d/orchid_saver.blend"
dest_files=["res://.godot/imported/orchid_saver.blend-2ed183e213d591791b3e5f1318afc991.scn"]
[params]
nodes/root_type=""
nodes/root_name=""
nodes/root_script=null
nodes/apply_root_scale=true
nodes/root_scale=1.0
nodes/import_as_skeleton_bones=false
nodes/use_name_suffixes=true
nodes/use_node_type_suffixes=true
meshes/ensure_tangents=true
meshes/generate_lods=true
meshes/create_shadow_meshes=true
meshes/light_baking=1
meshes/lightmap_texel_size=0.2
meshes/force_disable_compression=false
skins/use_named_skins=true
animation/import=true
animation/fps=30
animation/trimming=false
animation/remove_immutable_tracks=true
animation/import_rest_as_RESET=false
import_script/path=""
materials/extract=0
materials/extract_format=0
materials/extract_path=""
_subresources={
"materials": {
"Glass": {
"use_external/enabled": true,
"use_external/fallback_path": "res://common/assets/materials/glass_3d.tres",
"use_external/path": "uid://b5vlcdry8vtgi"
},
"Material": {
"use_external/enabled": true,
"use_external/fallback_path": "res://common/assets/materials/default_3d.tres",
"use_external/path": "uid://dvvi1k5c5iowc"
}
}
}
blender/nodes/visible=0
blender/nodes/active_collection_only=false
blender/nodes/punctual_lights=true
blender/nodes/cameras=true
blender/nodes/custom_properties=true
blender/nodes/modifiers=1
blender/meshes/colors=false
blender/meshes/uvs=true
blender/meshes/normals=true
blender/meshes/export_geometry_nodes_instances=false
blender/meshes/gpu_instances=false
blender/meshes/tangents=true
blender/meshes/skins=2
blender/meshes/export_bones_deforming_mesh_only=false
blender/materials/unpack_enabled=true
blender/materials/export_materials=1
blender/animation/limit_playback=true
blender/animation/always_sample=true
blender/animation/group_tracks=true
gltf/naming_version=2

View File

@@ -0,0 +1,96 @@
[gd_scene format=3 uid="uid://u3o5g8lmck74"]
[ext_resource type="PackedScene" uid="uid://bihsgpfqaiqml" path="res://entities/interactable_3d/orchid_saver/assets/3d/orchid_saver.blend" id="1_g6sgk"]
[ext_resource type="Script" uid="uid://1u4bxefehen8" path="res://entities/interactable_3d/orchid_saver/scripts/orchid_saver.gd" id="1_tiit5"]
[ext_resource type="FontFile" uid="uid://qt80w6o01q5s" path="res://gui/ressources/fonts/TitanOne-Regular.ttf" id="3_h5gyd"]
[sub_resource type="BoxShape3D" id="BoxShape3D_h5gyd"]
size = Vector3(0.20593262, 0.79333496, 0.93652344)
[sub_resource type="CylinderShape3D" id="CylinderShape3D_tiit5"]
height = 0.2626953
radius = 0.24365234
[sub_resource type="ViewportTexture" id="ViewportTexture_cqerb"]
viewport_path = NodePath("Screen/SubViewport")
[sub_resource type="LabelSettings" id="LabelSettings_cqerb"]
font = ExtResource("3_h5gyd")
font_size = 30
[node name="OrchidSaver" type="Area3D" unique_id=381308711]
script = ExtResource("1_tiit5")
screen_text = "Hello"
interactable = false
[node name="Model" parent="." unique_id=1027429202 instance=ExtResource("1_g6sgk")]
unique_name_in_owner = true
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.06540024, 0, 0.05925989)
[node name="Capsule" parent="Model" index="0" unique_id=1504808872]
visible = false
[node name="CollisionShape3D" type="CollisionShape3D" parent="." unique_id=397985169]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.72472906, 1.1686838, 0.095844865)
shape = SubResource("BoxShape3D_h5gyd")
[node name="PlayerDetector" type="Area3D" parent="." unique_id=1159653958]
unique_name_in_owner = true
[node name="CollisionShape3D" type="CollisionShape3D" parent="PlayerDetector" unique_id=2007025806]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.17858887, 0)
shape = SubResource("CylinderShape3D_tiit5")
[node name="Screen" type="Sprite3D" parent="." unique_id=947440245]
transform = Transform3D(-4.371139e-08, 0, 1, 0, 1, 0, -1, 0, -4.371139e-08, -0.66160196, 1.189235, 0.050924063)
pixel_size = 0.0018
texture = SubResource("ViewportTexture_cqerb")
[node name="SubViewport" type="SubViewport" parent="Screen" unique_id=241109082]
disable_3d = true
transparent_bg = true
size = Vector2i(429, 276)
[node name="TurnedOffBackground" type="ColorRect" parent="Screen/SubViewport" unique_id=448339240]
unique_name_in_owner = true
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
color = Color(0.0627451, 0.05882353, 0.16862746, 1)
[node name="MarginContainer" type="MarginContainer" parent="Screen/SubViewport" unique_id=411688632]
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
theme_override_constants/margin_left = 16
theme_override_constants/margin_top = 16
theme_override_constants/margin_right = 16
theme_override_constants/margin_bottom = 16
[node name="ScreenContent" type="VBoxContainer" parent="Screen/SubViewport/MarginContainer" unique_id=1667330208]
unique_name_in_owner = true
visible = false
layout_mode = 2
alignment = 1
[node name="ScreenIcon" type="TextureRect" parent="Screen/SubViewport/MarginContainer/ScreenContent" unique_id=87645401]
unique_name_in_owner = true
custom_minimum_size = Vector2(100, 100)
layout_mode = 2
expand_mode = 2
stretch_mode = 5
[node name="ScreenTitle" type="Label" parent="Screen/SubViewport/MarginContainer/ScreenContent" unique_id=2109180149]
unique_name_in_owner = true
layout_mode = 2
text = "Hello"
label_settings = SubResource("LabelSettings_cqerb")
horizontal_alignment = 1
vertical_alignment = 1
autowrap_mode = 3
[editable path="Model"]

View File

@@ -0,0 +1,52 @@
@tool
extends Interactable3D
class_name OrchidSaver
@export var screen_icon : Texture :
set(v):
screen_icon = v
update_screen()
@export var screen_text : String :
set(v):
screen_text = v
update_screen()
@export var screen_turned_on : bool = false :
set(v):
screen_turned_on = v
update_screen()
@onready var capsule_model : Node3D = %Model.find_child("Capsule")
var active = true
# Called when the node enters the scene tree for the first time.
func _ready():
capsule_model.hide()
interactable = false
%PlayerDetector.body_entered.connect(
func (body : Node3D):
if body is Player3D and active:
interactable = true
capsule_model.show()
screen_turned_on = true
AudioManager.play_sfx("HoloAppear")
)
%PlayerDetector.body_exited.connect(
func (body : Node3D):
if body is Player3D and active:
interactable = false
capsule_model.hide()
screen_turned_on = false
AudioManager.play_sfx("HoloDisappear")
)
update_screen()
func update_screen():
if is_node_ready():
%TurnedOffBackground.visible = not screen_turned_on
%ScreenContent.visible = screen_turned_on
%ScreenIcon.texture = screen_icon
%ScreenTitle.text = screen_text

View File

@@ -0,0 +1 @@
uid://1u4bxefehen8

View File

@@ -75,3 +75,4 @@ libraries/ = SubResource("AnimationLibrary_xa016")
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 5.9604645e-08, 1.0397238, -0.47173643)
light_color = Color(0.87551093, 0.72609586, 0.8473426, 1)
shadow_enabled = true
omni_range = 1.8928293

View File

@@ -113,13 +113,12 @@ fill_from = Vector2(0.5, 0.5)
fill_to = Vector2(1, 0.5)
[sub_resource type="CapsuleShape2D" id="CapsuleShape2D_6w4e0"]
radius = 29.70824
height = 62.292908
radius = 25.393593
height = 50.787186
[node name="Door" type="Area2D" unique_id=2053096538]
process_mode = 4
script = ExtResource("1_8kdwv")
icon = ExtResource("2_6w4e0")
default_interact_text = "ENTER"
available = false
metadata/_custom_type_script = "uid://dyprcd68fjstf"

View File

@@ -1,9 +1,7 @@
@tool
extends Interactable
class_name Door
@export var to_scene_id = ""
@export var icon : Texture : set = set_icon
@export var to_scene : Scene
@export var present : bool = false : set = set_present
@export var door_id : int
@@ -15,15 +13,15 @@ func _ready():
%AnimatedSprite2D.play("opened")
else:
%AnimatedSprite2D.play("closed")
set_icon()
set_present()
%Icon.texture = to_scene.get_scene_icon()
func interact(p : Player) -> bool:
if available and to_scene_id:
if available and to_scene:
p.region.data.entered_door = name
interacted.emit(p)
p.region.save()
SceneManager.change_to_scene_id(to_scene_id)
SceneManager.change_to_scene(to_scene)
return available
@@ -32,15 +30,12 @@ func set_available(v : bool):
if is_node_ready():
if available:
AudioManager.play_sfx("DoorOpen")
%AnimatedSprite2D.play("open")
get_tree().create_timer(0.5).timeout.connect(
func (): %AnimatedSprite2D.play("open")
)
else:
%AnimatedSprite2D.play("close")
func set_icon(i: Texture = icon):
icon = i
if is_node_ready():
%Icon.texture = icon
func set_present(p := present):
present = p
if present:

View File

@@ -22,5 +22,5 @@ func appear():
func interact(p : Player):
p.region.save()
SceneManager.change_to_scene_id("COCKPIT")
SceneManager.change_to_scene(CockpitScene.new())
return true

Binary file not shown.

Before

Width:  |  Height:  |  Size: 66 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://dmsls8siudy1u"
path="res://.godot/imported/growing.png-1974f3b5dd8b515f2458ee84afbec1aa.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/champ/growing.png"
dest_files=["res://.godot/imported/growing.png-1974f3b5dd8b515f2458ee84afbec1aa.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 138 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://crc4aop6ajiau"
path="res://.godot/imported/mature.png-44f597dc7980e7657c7418444db3823d.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/champ/mature.png"
dest_files=["res://.godot/imported/mature.png-44f597dc7980e7657c7418444db3823d.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://c7mp7tkkkk6o5"
path="res://.godot/imported/growing.png-c0d45a498c8bfc90776eb09d341d1579.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/chardi/growing.png"
dest_files=["res://.godot/imported/growing.png-c0d45a498c8bfc90776eb09d341d1579.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 149 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bupl1y0cfj21q"
path="res://.godot/imported/mature.png-a98b30ab80fe074a42994ef9926caee8.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/chardi/mature.png"
dest_files=["res://.godot/imported/mature.png-a98b30ab80fe074a42994ef9926caee8.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 150 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://ds1nf2876m6bh"
path="res://.godot/imported/growing.png-0397882e264ff91cc96e415be3ae1543.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/ferno/growing.png"
dest_files=["res://.godot/imported/growing.png-0397882e264ff91cc96e415be3ae1543.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 111 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bfj6wji21amgk"
path="res://.godot/imported/mature.png-e7dca043959ac892503be612a2dc85b8.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/ferno/mature.png"
dest_files=["res://.godot/imported/mature.png-e7dca043959ac892503be612a2dc85b8.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 56 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://dwr3c6r6piwaa"
path="res://.godot/imported/growing.png-7b76a9f596f5cec79fdd8685670b16b5.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/maias/growing.png"
dest_files=["res://.godot/imported/growing.png-7b76a9f596f5cec79fdd8685670b16b5.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 193 KiB

View File

@@ -1,41 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://d3apfwbqsg5ha"
path.s3tc="res://.godot/imported/mature.png-8766aea5da569488db27850c55c8418b.s3tc.ctex"
metadata={
"imported_formats": ["s3tc_bptc"],
"vram_texture": true
}
[deps]
source_file="res://entities/plants/assets/sprites/maias/mature.png"
dest_files=["res://.godot/imported/mature.png-8766aea5da569488db27850c55c8418b.s3tc.ctex"]
[params]
compress/mode=2
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=true
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=0

Binary file not shown.

Before

Width:  |  Height:  |  Size: 64 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://dna7x371cs0tu"
path="res://.godot/imported/growing.png-6680673773f3b22171cacdd2f4db1f47.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/philea/growing.png"
dest_files=["res://.godot/imported/growing.png-6680673773f3b22171cacdd2f4db1f47.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

Binary file not shown.

Before

Width:  |  Height:  |  Size: 357 KiB

View File

@@ -1,40 +0,0 @@
[remap]
importer="texture"
type="CompressedTexture2D"
uid="uid://bj801geprrhfu"
path="res://.godot/imported/mature.png-5a510079f351d9ec4d59ef93a0592812.ctex"
metadata={
"vram_texture": false
}
[deps]
source_file="res://entities/plants/assets/sprites/philea/mature.png"
dest_files=["res://.godot/imported/mature.png-5a510079f351d9ec4d59ef93a0592812.ctex"]
[params]
compress/mode=0
compress/high_quality=false
compress/lossy_quality=0.7
compress/uastc_level=0
compress/rdo_quality_loss=0.0
compress/hdr_compression=1
compress/normal_map=0
compress/channel_pack=0
mipmaps/generate=false
mipmaps/limit=-1
roughness/mode=0
roughness/src_normal=""
process/channel_remap/red=0
process/channel_remap/green=1
process/channel_remap/blue=2
process/channel_remap/alpha=3
process/fix_alpha_border=true
process/premult_alpha=false
process/normal_map_invert_y=false
process/hdr_as_srgb=false
process/hdr_clamp_exposure=false
process/size_limit=0
detect_3d/compress_to=1

View File

@@ -81,7 +81,7 @@ func get_score(state: State = get_state()) -> int:
for pd in nearby_plants:
score += pd.get_score_buff()
return max(0,score) * mult
return max(0,score) * max(0,mult)
func get_state() -> State:
if day >= get_lifetime():

View File

@@ -1,3 +1,4 @@
@abstract
extends Resource
class_name PlantMutation
@@ -15,16 +16,12 @@ func get_icon() -> Texture:
func get_base_rarity() -> int:
return 0
func get_mutation_id() -> String:
printerr("Classe abstraite PlantMutation appelée")
return ""
@abstract func get_mutation_id() -> String
func get_mutation_name() -> String:
return tr(get_mutation_id())
func get_mutation_description() -> String:
printerr("Classe abstraite PlantMutation appelée")
return ""
@abstract func get_mutation_description() -> String
func mutate_plant_data(_plant_data: PlantData):
pass

View File

@@ -17,9 +17,7 @@ func get_mutation_description() -> String:
})
func mutate_score_multiplier(plant_data: PlantData, multiplier: int) -> int:
if plant_data.get_state() == PlantData.State.MATURE:
return 0
return multiplier
return multiplier - 1
func mutate_score_buff(plant_data: PlantData, score_buff : int) -> int:
if plant_data.get_state() == PlantData.State.MATURE:

View File

@@ -23,4 +23,4 @@ func _start_maturation_effect(plant : Plant):
func get_purification_radius() -> int:
return level
return level * 2

View File

@@ -31,4 +31,4 @@ func get_near_plants_around():
return max(DEFAULT_PLANT_BY_POINT - level,1)
func get_score_increase():
return max(level - DEFAULT_PLANT_BY_POINT,1)
return max(level + 2 - DEFAULT_PLANT_BY_POINT,1)

View File

@@ -20,6 +20,8 @@ func current_is_tool() -> bool:
return current_item_ind <= len(tools)
func set_current_item(new_ind: int):
if new_ind < 0:
new_ind += (len(tools) + len(seeds))
if new_ind != current_item_ind:
current_item_ind = new_ind % (len(tools) + len(seeds))
updated.emit(self)

View File

@@ -1,8 +1,6 @@
extends Item
class_name Seed
const MUTATION_PROBABILITY = 0.3
const SHOVEL_ICON = preload("res://common/icons/shovel.svg")
const GROWING_ICON = preload("res://common/icons/chevrons-up.svg")
const SCORE_ICON = preload("res://common/icons/growth.svg")
@@ -21,10 +19,18 @@ func _init(
random_seed = randi()
static func generate_from_parent(plant_data : PlantData) -> Seed:
if randf() < MUTATION_PROBABILITY:
var mutations : Array[PlantMutation] = plant_data.mutations
var mutation_probability = GameInfo.game_data.current_run.plant_info.get_mutation_probability()
# Mutate for every time mutation probability exceed 1
while mutation_probability > 1:
mutations = mutate_mutations(plant_data.mutations)
mutation_probability -= 1
if randf() < GameInfo.game_data.current_run.plant_info.get_mutation_probability():
return Seed.new(
plant_data.plant_name,
mutate_mutations(plant_data)
mutate_mutations(mutations)
)
else :
return Seed.new(
@@ -144,19 +150,19 @@ static func generate_first_mutation(rarity := 0) -> PlantMutation:
return possible_mutation
static func mutate_mutations(parent : PlantData) -> Array[PlantMutation]:
static func mutate_mutations(mutations : Array[PlantMutation]) -> Array[PlantMutation]:
var mutation_possibility : Array[MutationPossibility] = [
AddMutation.new()
]
if (
len(parent.mutations) >= GameInfo.game_data.progression_data.max_mutations_by_plant
len(mutations) >= GameInfo.game_data.current_run.plant_info.get_mutation_max_number()
):
mutation_possibility = [
UpgradeMutation.new(),
]
elif len(parent.mutations) > 0:
elif len(mutations) > 0:
mutation_possibility = [
AddMutation.new(),
UpgradeMutation.new(),
@@ -164,20 +170,20 @@ static func mutate_mutations(parent : PlantData) -> Array[PlantMutation]:
var chosen_mutation_possibility = mutation_possibility.pick_random()
return chosen_mutation_possibility.mutate(parent)
return chosen_mutation_possibility.mutate(mutations)
class MutationPossibility:
func mutate(_parent : PlantData)-> Array[PlantMutation]:
func mutate(_mutations : Array[PlantMutation])-> Array[PlantMutation]:
return []
class AddMutation extends MutationPossibility:
func mutate(parent : PlantData)-> Array[PlantMutation]:
var new_mutations = parent.mutations.duplicate_deep()
func mutate(mutations : Array[PlantMutation])-> Array[PlantMutation]:
var new_mutations = mutations.duplicate_deep()
var possible_new_mutations = GameInfo.game_data.progression_data.available_mutations.duplicate_deep()
possible_new_mutations = possible_new_mutations.filter(
func (m : PlantMutation):
return parent.mutations.find_custom(func(m2: PlantMutation): return m2.name == m.name) == -1
return mutations.find_custom(func(m2: PlantMutation): return m2.name == m.name) == -1
)
if len(possible_new_mutations):
@@ -187,17 +193,17 @@ class AddMutation extends MutationPossibility:
class UpgradeMutation extends MutationPossibility:
func mutate(
parent : PlantData
mutations : Array[PlantMutation]
) -> Array[PlantMutation]:
var new_mutations = parent.mutations.duplicate_deep()
var new_mutations = mutations.duplicate_deep()
new_mutations.pick_random().level += 1
return new_mutations
class RemoveMutation extends MutationPossibility:
func mutate(parent : PlantData)-> Array[PlantMutation]:
var new_mutations = parent.mutations.duplicate_deep()
func mutate(mutations : Array[PlantMutation])-> Array[PlantMutation]:
var new_mutations = mutations.duplicate_deep()
var mut_to_remove = new_mutations.pick_random()
if mut_to_remove.level > 1:

View File

@@ -32,5 +32,5 @@ func use_text() -> String:
return tr("SHIP_TELEPORT_USE_TEXT")
func use(_player : Player, _zone: Player.ActionZone):
SceneManager.change_to_scene_id('COCKPIT')
SceneManager.change_to_scene(CockpitScene.new())
AudioManager.play_sfx("Teleportation")

View File

@@ -33,7 +33,7 @@ func _init(region : Region, pos : Vector2):
signals.append(
DetectorSignalIndividual.new(
(pos - e.global_position).normalized().angle(),
(e as Door).icon,
(e as Door).to_scene.get_scene_icon(),
Color("ffa617ff")
),
)

View File

@@ -135,6 +135,79 @@ tracks/0/keys = {
"update": 0,
"values": [Vector2(0.99999994, -17)]
}
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath("PlayerSprite:modulate:a")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
"values": [1.0]
}
tracks/2/type = "value"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("PlayerSprite/CPUParticles2D:emitting")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 1,
"values": [true]
}
tracks/3/type = "bezier"
tracks/3/imported = false
tracks/3/enabled = true
tracks/3/path = NodePath("PlayerSprite:position:y")
tracks/3/interp = 1
tracks/3/loop_wrap = true
tracks/3/keys = {
"handle_modes": PackedInt32Array(0),
"points": PackedFloat32Array(-17, -0.25, 0, 0.25, 0),
"times": PackedFloat32Array(0)
}
[sub_resource type="Animation" id="Animation_qiwj3"]
resource_name = "fall"
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("PlayerSprite:modulate:a")
tracks/0/interp = 2
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0.1, 0.43333334, 1),
"transitions": PackedFloat32Array(1, 1, 1),
"update": 0,
"values": [0.0, 1.0, 1.0]
}
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath("PlayerSprite/CPUParticles2D:emitting")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0.56666666, 0.7),
"transitions": PackedFloat32Array(1, 1),
"update": 1,
"values": [false, true]
}
tracks/2/type = "bezier"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("PlayerSprite:position:y")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"handle_modes": PackedInt32Array(0, 2, 1, 2),
"points": PackedFloat32Array(-181, -0.25, 0, 0.36666667, 89, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, -17, -0.16666669, -18, 0, 0),
"times": PackedFloat32Array(0.1, 0.5, 0.6666667, 1)
}
[sub_resource type="Animation" id="Animation_8fjmc"]
resource_name = "float"
@@ -156,6 +229,7 @@ tracks/0/keys = {
[sub_resource type="AnimationLibrary" id="AnimationLibrary_qiwj3"]
_data = {
&"RESET": SubResource("Animation_fkugw"),
&"fall": SubResource("Animation_qiwj3"),
&"float": SubResource("Animation_8fjmc")
}
@@ -213,6 +287,6 @@ stream = ExtResource("7_qiwj3")
volume_db = -3.0
bus = &"Sfx"
[node name="FloatAnimationPlayer" type="AnimationPlayer" parent="." unique_id=793749564]
[node name="AnimationPlayer" type="AnimationPlayer" parent="." unique_id=793749564]
unique_name_in_owner = true
libraries/ = SubResource("AnimationLibrary_qiwj3")
autoplay = &"float"

View File

@@ -17,7 +17,7 @@ var region : Region :
var data : PlayerData
var last_action_area_movement_timer : float = 100.
var controlling_player : bool = true :
var controlling_player : bool = false :
set(v):
controlling_player = v
velocity = Vector2.ZERO
@@ -34,6 +34,13 @@ func _ready():
Pointer.player = self
setup_preview_zone(data.inventory.get_item())
func appear(with_falling_animation = true):
if with_falling_animation:
%AnimationPlayer.play("fall")
await %AnimationPlayer.animation_finished
controlling_player = true
%AnimationPlayer.play("float")
func _input(_event) -> void:
if Input.is_action_pressed("change_item_left"):
data.inventory.change_current_item(1)

View File

@@ -0,0 +1,16 @@
[gd_scene format=3 uid="uid://b2tn4biidxwdo"]
[ext_resource type="PackedScene" uid="uid://111umh57ekg5" path="res://entities/player_3d/resources/3d_orchid.blend" id="1_4gn86"]
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_xuy43"]
radius = 0.42504883
height = 0.8718262
[node name="DeadOrchid" type="RigidBody3D" unique_id=1056532235]
transform = Transform3D(-0.98981106, 0, 0.14238709, 0, 1, 0, -0.14238709, 0, -0.98981106, 0, 0, 0)
[node name="3d_orchid" parent="." unique_id=1207424236 instance=ExtResource("1_4gn86")]
[node name="CollisionShape3D" type="CollisionShape3D" parent="." unique_id=195534146]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.20080566, 0)
shape = SubResource("CapsuleShape3D_xuy43")

View File

@@ -11,6 +11,38 @@ size = Vector2(2, 2)
radius = 0.5854492
height = 1.7342377
[sub_resource type="Gradient" id="Gradient_dqi2u"]
interpolation_mode = 1
offsets = PackedFloat32Array(0.7046632, 0.78238344, 1)
colors = PackedColorArray(1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0)
[sub_resource type="GradientTexture2D" id="GradientTexture2D_o44vi"]
gradient = SubResource("Gradient_dqi2u")
width = 300
height = 300
fill = 1
fill_from = Vector2(0.5, 0.5)
fill_to = Vector2(0.5, 0)
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_fcmrk"]
transparency = 1
shading_mode = 0
vertex_color_use_as_albedo = true
albedo_texture = SubResource("GradientTexture2D_o44vi")
[sub_resource type="PlaneMesh" id="PlaneMesh_0oeag"]
material = SubResource("StandardMaterial3D_fcmrk")
size = Vector2(1, 1)
[sub_resource type="Curve" id="Curve_3yrqc"]
_data = [Vector2(0, 0), 0.0, 3.0432534, 0, 0, Vector2(1, 1), 0.0, 0.0, 0, 0]
point_count = 2
[sub_resource type="Gradient" id="Gradient_r4vrj"]
interpolation_mode = 2
offsets = PackedFloat32Array(0, 0.87772924)
colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 0)
[node name="Player3D" type="CharacterBody3D" unique_id=549819967 node_paths=PackedStringArray("pointer_texture_rect")]
transform = Transform3D(-4.371139e-08, 0, 1, 0, 1, 0, -1, 0, -4.371139e-08, 0, 0, 0)
script = ExtResource("1_pvvbh")
@@ -19,10 +51,11 @@ pointer_texture_rect = NodePath("CanvasLayer/PointerTexture")
[node name="Camera3D" type="Camera3D" parent="." unique_id=2091917091]
unique_name_in_owner = true
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.19785136, 0)
current = true
near = 0.003
[node name="MeshInstance3D" type="MeshInstance3D" parent="Camera3D" unique_id=818458454]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.2)
[node name="MeshInstance3D" type="MeshInstance3D" parent="Camera3D" unique_id=1477584785]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 1.1755164e-08, 0, -0.46892682)
mesh = SubResource("QuadMesh_o44vi")
surface_material_override/0 = ExtResource("2_fcmrk")
@@ -30,6 +63,9 @@ surface_material_override/0 = ExtResource("2_fcmrk")
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.253273, 0)
shape = SubResource("CapsuleShape3D_eodxe")
[node name="OmniLight3D" type="OmniLight3D" parent="." unique_id=1818490710]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -2.7901894e-08, -0.25222805, 0.6383209)
[node name="CanvasLayer" type="CanvasLayer" parent="." unique_id=1210282091]
[node name="PointerTexture" type="TextureRect" parent="CanvasLayer" unique_id=99628184]
@@ -50,3 +86,11 @@ size_flags_horizontal = 4
size_flags_vertical = 4
texture = ExtResource("4_sbfo8")
expand_mode = 1
[node name="CPUParticles3D" type="CPUParticles3D" parent="." unique_id=1470634574]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.66324395, 0)
amount = 5
mesh = SubResource("PlaneMesh_0oeag")
gravity = Vector3(0, -1, 0)
scale_amount_curve = SubResource("Curve_3yrqc")
color_ramp = SubResource("Gradient_r4vrj")

Binary file not shown.

View File

@@ -0,0 +1,68 @@
[remap]
importer="scene"
importer_version=1
type="PackedScene"
uid="uid://111umh57ekg5"
path="res://.godot/imported/3d_orchid.blend-c6e0699727e8e74cab04ff8bc9d98505.scn"
[deps]
source_file="res://entities/player_3d/resources/3d_orchid.blend"
dest_files=["res://.godot/imported/3d_orchid.blend-c6e0699727e8e74cab04ff8bc9d98505.scn"]
[params]
nodes/root_type=""
nodes/root_name=""
nodes/root_script=null
nodes/apply_root_scale=true
nodes/root_scale=1.0
nodes/import_as_skeleton_bones=false
nodes/use_name_suffixes=true
nodes/use_node_type_suffixes=true
meshes/ensure_tangents=true
meshes/generate_lods=true
meshes/create_shadow_meshes=true
meshes/light_baking=1
meshes/lightmap_texel_size=0.2
meshes/force_disable_compression=false
skins/use_named_skins=true
animation/import=true
animation/fps=30
animation/trimming=false
animation/remove_immutable_tracks=true
animation/import_rest_as_RESET=false
import_script/path=""
materials/extract=0
materials/extract_format=0
materials/extract_path=""
_subresources={
"materials": {
"Default3D": {
"use_external/enabled": true,
"use_external/fallback_path": "res://common/assets/materials/default_3d.tres",
"use_external/path": "uid://dvvi1k5c5iowc"
}
}
}
blender/nodes/visible=0
blender/nodes/active_collection_only=false
blender/nodes/punctual_lights=true
blender/nodes/cameras=true
blender/nodes/custom_properties=true
blender/nodes/modifiers=1
blender/meshes/colors=false
blender/meshes/uvs=true
blender/meshes/normals=true
blender/meshes/export_geometry_nodes_instances=false
blender/meshes/gpu_instances=false
blender/meshes/tangents=true
blender/meshes/skins=2
blender/meshes/export_bones_deforming_mesh_only=false
blender/materials/unpack_enabled=true
blender/materials/export_materials=1
blender/animation/limit_playback=true
blender/animation/always_sample=true
blender/animation/group_tracks=true
gltf/naming_version=2

View File

@@ -9,6 +9,7 @@ const POINTER_ACTION_TEXTURE = preload("res://common/icons/hand-stop.svg")
@export var speed := 4.0
const MOUSE_SENSIVITY = 0.002
const RAY_LENGTH = 10.
const PUSH_FORCE = 0.6
var cockpit_action_hovered : Interactable3D = null
var query_mouse := false
@@ -67,6 +68,12 @@ func _physics_process(delta):
velocity += get_gravity() * delta
move_and_slide()
for i in get_slide_collision_count():
var collision = get_slide_collision(i)
if collision.get_collider() is RigidBody3D:
collision.get_collider().apply_central_impulse(
-collision.get_normal() * PUSH_FORCE
)
func update_mouse_hovered_cockpit_actions() -> void:

View File

@@ -3,7 +3,7 @@ class_name Entity
var terrain : Terrain
var region : Region :
get(): return terrain if terrain is Region else null
get(): return terrain if terrain is Region else null
func save() -> EntityData:
return null
return null