Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 54bfc3c021 |
@@ -1,4 +1,4 @@
|
||||
[gd_scene load_steps=14 format=3 uid="uid://ceaa2qj2bmw43"]
|
||||
[gd_scene load_steps=13 format=3 uid="uid://ceaa2qj2bmw43"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://cssdu8viimwm6" path="res://scripts/CSharp/Common/SceneTransition.cs" id="1_c6eln"]
|
||||
[ext_resource type="Texture2D" uid="uid://cugtxcfuds31r" path="res://art/indoor/Babushka_bg_01.png" id="2_j25a2"]
|
||||
@@ -17,10 +17,6 @@ size = Vector2(3836, 1086)
|
||||
[sub_resource type="RectangleShape2D" id="RectangleShape2D_2spkc"]
|
||||
size = Vector2(238.25, 189.75)
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_phqdf"]
|
||||
resource_local_to_scene = true
|
||||
radius = 381.93
|
||||
|
||||
[sub_resource type="CircleShape2D" id="CircleShape2D_2spkc"]
|
||||
resource_local_to_scene = true
|
||||
radius = 509.071
|
||||
@@ -28,7 +24,7 @@ radius = 509.071
|
||||
[node name="VesnasRoom" type="Node2D"]
|
||||
y_sort_enabled = true
|
||||
script = ExtResource("1_c6eln")
|
||||
_sceneNamesToLoad = PackedStringArray("res://scenes/Babushka_scene_indoor_common_room.tscn", "res://scenes/Babushka_scene_fight_world_room.tscn")
|
||||
_sceneNamesToLoad = PackedStringArray("res://scenes/Babushka_scene_indoor_common_room.tscn", "res://scenes/Babushka_scene_forest_fight_1_2d.tscn")
|
||||
|
||||
[node name="Colliders" type="Node2D" parent="."]
|
||||
position = Vector2(1297, 5292)
|
||||
@@ -101,13 +97,10 @@ _followNode = NodePath("../Vesna/CharacterBody2D")
|
||||
[node name="CanvasLayer" parent="." instance=ExtResource("24_xwo8y")]
|
||||
|
||||
[node name="BedInteraction" parent="." instance=ExtResource("8_phqdf")]
|
||||
position = Vector2(-1415, 489)
|
||||
position = Vector2(-1429, 487)
|
||||
_useSprite = false
|
||||
_id = 1
|
||||
|
||||
[node name="CollisionShape3D" parent="BedInteraction/Area2D" index="0"]
|
||||
position = Vector2(-382, 9)
|
||||
shape = SubResource("CircleShape2D_phqdf")
|
||||
|
||||
[node name="QuestCompleter" type="Node" parent="BedInteraction"]
|
||||
script = ExtResource("8_j25a2")
|
||||
questResource = ExtResource("9_heyef")
|
||||
@@ -115,6 +108,7 @@ toStatus = 2
|
||||
|
||||
[node name="DoorInteraction" parent="." instance=ExtResource("8_phqdf")]
|
||||
position = Vector2(777, 201)
|
||||
_useSprite = false
|
||||
_id = 0
|
||||
|
||||
[node name="CollisionShape3D" parent="DoorInteraction/Area2D" index="0"]
|
||||
@@ -125,5 +119,4 @@ shape = SubResource("CircleShape2D_2spkc")
|
||||
[connection signal="Interacted" from="DoorInteraction" to="." method="LoadScene"]
|
||||
|
||||
[editable path="Vesna"]
|
||||
[editable path="BedInteraction"]
|
||||
[editable path="DoorInteraction"]
|
||||
|
||||
@@ -13,7 +13,7 @@ public partial class InteractionArea2D : Node2D
|
||||
[Export] private bool _useOutline = true;
|
||||
[Export] private ShaderMaterial _outlineMaterial;
|
||||
[Export] private CanvasItem? _spriteToOutline; // keep to not break old usages. TODO: remove later
|
||||
[Export] private CanvasItem[] _spritesToOutline = [];
|
||||
[Export] private CanvasItem[] _spritesToOutline;
|
||||
[Export] private bool _showLabel = true;
|
||||
[Export] private int _id = -1; // TODO: remove
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Babushka.scripts.CSharp.Common.Util;
|
||||
using Godot;
|
||||
|
||||
@@ -15,15 +16,14 @@ public partial class FightRoomSceneSetup : Node
|
||||
{
|
||||
var room = FightWorld.Instance.currentRoom!;
|
||||
|
||||
var i = 0;
|
||||
foreach (var availableParent in _enemyGroupSpawns.Shuffle())
|
||||
foreach (var (parent, group) in _enemyGroupSpawns.Zip(room.enemyGroups))
|
||||
{
|
||||
var enemyGroup = room.enemyGroups[i];
|
||||
if (group.AreAllDead())
|
||||
continue;
|
||||
|
||||
var roamingEnemyGroup = _roamingEnemyGroupPrefab.Instantiate<RoamingEnemyGroup>();
|
||||
roamingEnemyGroup.Initialize(enemyGroup, _fightSceneSwitcher);
|
||||
availableParent.AddChild(roamingEnemyGroup);
|
||||
if (i >= room.enemyGroups.Count - 1) break;
|
||||
i++;
|
||||
roamingEnemyGroup.Initialize(group, _fightSceneSwitcher);
|
||||
parent.AddChild(roamingEnemyGroup);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user