Initial commit

Un bout de jeu, qui fait pas grand chose mais on progresse.
This commit is contained in:
Thomas
2025-02-21 17:59:47 +01:00
commit fe463ad396
74 changed files with 59217 additions and 0 deletions

13
scenes/pathFollow.gd Normal file
View File

@@ -0,0 +1,13 @@
extends PathFollow2D
@export var speed = 0.1
var voiture
# Called when the node enters the scene tree for the first time.
func _ready() -> void:
voiture = (self.get_child(0) as Voiture)
voiture.updatePosition(position.x, position.y)
# Called every frame. 'delta' is the elapsed time since the previous frame.
func _process(delta: float) -> void:
progress_ratio += delta * speed;
voiture.updatePosition(position.x, position.y)

41
scenes/start.tscn Normal file
View File

@@ -0,0 +1,41 @@
[gd_scene load_steps=6 format=3 uid="uid://b4ydi1vv8dvwr"]
[ext_resource type="PackedScene" uid="uid://d1oqt6sbjvopi" path="res://cartes/monde.tscn" id="1_6vs81"]
[ext_resource type="PackedScene" uid="uid://vclpg4e4ql54" path="res://personages/joueur.tscn" id="2_5x6b5"]
[ext_resource type="PackedScene" uid="uid://cl201baro5y5" path="res://vehicules/voiture_pnj.tscn" id="3_yuakw"]
[sub_resource type="Curve2D" id="Curve2D_shblg"]
_data = {
"points": PackedVector2Array(0, 0, 0, 0, -411, 81, 0, 0, 0, 0, 37, 81, 0, 0, 0, 0, 37, -34, 0, 0, 0, 0, 2392, -33, 0, 0, 0, 0, 2395, 125, 0, 0, 0, 0, 2750, 126, 0, 0, 0, 0, 2750, -313, 0, 0, 0, 0, 2391, -314, 0, 0, 0, 0, 2390, -149, 0, 0, 0, 0, 39, -144, 0, 0, 0, 0, 39, -293, 0, 0, 0, 0, -398, -289, 0, 0, 0, 0, -409, -310, 0, 0, 0, 0, -414, 78)
}
point_count = 14
[sub_resource type="Curve2D" id="Curve2D_nircx"]
_data = {
"points": PackedVector2Array(0, 0, 0, 0, 803, 1569, 0, 0, 0, 0, 910, 1573, 0, 0, 0, 0, 913, 1368, 0, 0, 0, 0, 1926, 1371, 0, 0, 0, 0, 1931, 342, 0, 0, 0, 0, 2082, 333, 0, 0, 0, 0, 2060, -140, 0, 0, 0, 0, 1718, -143, 0, 0, 0, 0, 1724, 20, 0, 0, 0, 0, 900, 30, 0, 0, 0, 0, 904, -1165, 0, 0, 0, 0, -890, -1162, 0, 0, 0, 0, -886, -119, 0, 0, 0, 0, -1062, -106, 0, 0, 0, 0, -1079, 264, 0, 0, 0, 0, -630, 271, 0, 0, 0, 0, -616, 161, 0, 0, 0, 0, 786, 152, 0, 0, 0, 0, 806, 1560)
}
point_count = 19
[node name="scene1" type="Node2D"]
[node name="monde" parent="." instance=ExtResource("1_6vs81")]
[node name="movibles" type="Node2D" parent="."]
[node name="Area2D" parent="movibles" instance=ExtResource("2_5x6b5")]
position = Vector2(87, 74)
[node name="voitures" type="Node" parent="movibles"]
[node name="Path2D" type="Path2D" parent="movibles/voitures"]
position = Vector2(-664, 181)
curve = SubResource("Curve2D_shblg")
[node name="voiture_pnj" parent="movibles/voitures/Path2D" instance=ExtResource("3_yuakw")]
[node name="Path2D2" type="Path2D" parent="movibles/voitures"]
curve = SubResource("Curve2D_nircx")
[node name="voiture_pnj" parent="movibles/voitures/Path2D2" instance=ExtResource("3_yuakw")]
position = Vector2(803, 1569)
speed = 0.05