Clean up
This commit is contained in:
@@ -12,8 +12,6 @@ public partial class InGameAudio : Node
|
||||
|
||||
[Dependency] public IAppRepo AppRepo => this.DependOn<IAppRepo>();
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] public IGameEventDepot GameEventDepot => this.DependOn<IGameEventDepot>();
|
||||
|
||||
#region BGM Nodes
|
||||
@@ -55,7 +53,6 @@ public partial class InGameAudio : Node
|
||||
public void OnResolved()
|
||||
{
|
||||
InGameAudioLogic.Set(AppRepo);
|
||||
InGameAudioLogic.Set(GameRepo);
|
||||
InGameAudioLogic.Set(GameEventDepot);
|
||||
|
||||
InGameAudioBinding = InGameAudioLogic.Bind();
|
||||
|
||||
@@ -32,8 +32,6 @@ public partial class Boss : CharacterBody3D, IBoss, IProvide<IBossLogic>
|
||||
|
||||
public BossLogic.IBinding BossBinding { get; set; } = default!;
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] public IGameEventDepot GameEventDepot => this.DependOn<IGameEventDepot>();
|
||||
|
||||
[Dependency] public IGame Game => this.DependOn<IGame>();
|
||||
@@ -58,7 +56,6 @@ public partial class Boss : CharacterBody3D, IBoss, IProvide<IBossLogic>
|
||||
{
|
||||
BossLogic = new BossLogic();
|
||||
BossLogic.Set(this as IBoss);
|
||||
BossLogic.Set(GameRepo);
|
||||
|
||||
SetPhysicsProcess(false);
|
||||
Hide();
|
||||
|
||||
@@ -20,8 +20,6 @@ public partial class Enemy : RigidBody3D, IEnemy, IProvide<IEnemyLogic>
|
||||
|
||||
#region Dependencies
|
||||
|
||||
[Dependency] IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] IGameEventDepot GameEventDepot => this.DependOn<IGameEventDepot>();
|
||||
|
||||
[Dependency] IPlayer Player => this.DependOn<IPlayer>();
|
||||
|
||||
@@ -11,8 +11,6 @@ public partial class OxFace : Node3D
|
||||
|
||||
[Node] public AnimationTree AnimationTree { get; set; } = default!;
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] public IPlayer Player => this.DependOn<IPlayer>();
|
||||
|
||||
[Node] public Timer AttackTimer { get; set; } = default!;
|
||||
|
||||
@@ -23,8 +23,6 @@ public partial class ItemSlot : HBoxContainer, IItemSlot
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] public IPlayer Player => this.DependOn<IPlayer>();
|
||||
|
||||
//[Node] public Label EquipBonus { get; set; } = default!;
|
||||
|
||||
@@ -11,8 +11,6 @@ public partial class Accessory : Node3D, IEquipableItem
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] public IGameEventDepot GameEventDepot => this.DependOn<IGameEventDepot>();
|
||||
|
||||
[Dependency] public IPlayer Player => this.DependOn<IPlayer>();
|
||||
|
||||
@@ -1,19 +1,6 @@
|
||||
[gd_scene load_steps=5 format=3 uid="uid://c6w7dpk0hurj0"]
|
||||
[gd_scene load_steps=3 format=3 uid="uid://c6w7dpk0hurj0"]
|
||||
|
||||
[ext_resource type="Script" path="res://src/items/consumable/ConsumableItem.cs" id="1_26bad"]
|
||||
[ext_resource type="Script" path="res://src/items/consumable/ConsumableItemStats.cs" id="2_g3oo3"]
|
||||
|
||||
[sub_resource type="Resource" id="Resource_33w5s"]
|
||||
script = ExtResource("2_g3oo3")
|
||||
RaiseHPAmount = 0
|
||||
RaiseVTAmount = 0
|
||||
Name = ""
|
||||
Description = ""
|
||||
SpawnRate = 0.5
|
||||
ThrowSpeed = 12.0
|
||||
HealHPAmount = 0
|
||||
HealVTAmount = 0
|
||||
ThrowDamage = 5
|
||||
[ext_resource type="Script" uid="uid://cyqibeq07rjr" path="res://src/items/consumable/ConsumableItem.cs" id="1_26bad"]
|
||||
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_7mh0f"]
|
||||
size = Vector3(0.778381, 0.929947, 0.731567)
|
||||
@@ -21,7 +8,6 @@ size = Vector3(0.778381, 0.929947, 0.731567)
|
||||
[node name="ConsumableItem" type="Node3D"]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -1.75, 0)
|
||||
script = ExtResource("1_26bad")
|
||||
ConsumableItemInfo = SubResource("Resource_33w5s")
|
||||
|
||||
[node name="Pickup" type="Area3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
@@ -31,7 +17,7 @@ collision_mask = 4
|
||||
[node name="Sprite" type="Sprite3D" parent="Pickup"]
|
||||
unique_name_in_owner = true
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.0322805, 0)
|
||||
pixel_size = 0.0005
|
||||
pixel_size = 0.0015
|
||||
billboard = 2
|
||||
shaded = true
|
||||
double_sided = false
|
||||
|
||||
@@ -15,8 +15,6 @@ public partial class DroppedItem : RigidBody3D, IDroppedItem
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] public IGame Game => this.DependOn<IGame>();
|
||||
|
||||
[Dependency] public IPlayer Player => this.DependOn<IPlayer>();
|
||||
|
||||
@@ -9,7 +9,6 @@ public partial class Restorative : Node3D
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
[Dependency] public IGameEventDepot GameEventDepot => this.DependOn<IGameEventDepot>();
|
||||
|
||||
[Node] public Area3D Pickup { get; set; } = default!;
|
||||
|
||||
@@ -10,8 +10,6 @@ public partial class BossRoom : Node3D, IDungeonRoom
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Node] public Marker3D PlayerSpawn { get; set; } = default!;
|
||||
|
||||
[Node] public Marker3D TeleportSpawn { get; set; } = default!;
|
||||
|
||||
@@ -17,8 +17,6 @@ public partial class DungeonRoom : Node3D, IDungeonRoom
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Node] public Marker3D PlayerSpawn { get; set; } = default!;
|
||||
|
||||
[Node] public Marker3D TeleportSpawn { get; set; } = default!;
|
||||
|
||||
@@ -8,9 +8,6 @@ public partial class Overworld : Node3D, IDungeonFloor
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency]
|
||||
public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Node] public Marker3D PlayerSpawnPoint { get; set; } = default!;
|
||||
|
||||
[Node] public Marker3D ExitSpawnPoint { get; set; } = default!;
|
||||
|
||||
@@ -325,6 +325,9 @@ public partial class Player : CharacterBody3D, IPlayer
|
||||
|
||||
private void OnHealthTimerTimeout()
|
||||
{
|
||||
if (Stats.CurrentHP.Value <= 0)
|
||||
return;
|
||||
|
||||
if (Stats.CurrentVT.Value > 0)
|
||||
{
|
||||
if (Inventory.EquippedAccessory.Value.AccessoryTags.Contains(AccessoryTag.HalfVTConsumption))
|
||||
|
||||
@@ -23,9 +23,6 @@ public partial class FloorClearMenu : Control, IFloorClearMenu
|
||||
{
|
||||
public override void _Notification(int what) => this.Notify(what);
|
||||
|
||||
[Dependency]
|
||||
public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Node] public IAnimationPlayer AnimationPlayer { get; set; } = default!;
|
||||
|
||||
[Node] public Button ContinueButton { get; set; } = default!;
|
||||
|
||||
@@ -27,8 +27,6 @@ public partial class PlayerInfoUI : Control, IPlayerInfoUI
|
||||
[Node] public Label VTNumber { get; set; } = default!;
|
||||
#endregion
|
||||
|
||||
[Dependency] public IGameRepo GameRepo => this.DependOn<IGameRepo>();
|
||||
|
||||
[Dependency] public IPlayer Player => this.DependOn<IPlayer>();
|
||||
|
||||
public void OnResolved()
|
||||
|
||||
Reference in New Issue
Block a user