From de2c6261b0551497043a90d225fbede13c0c3471 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=A4=D1=91=D0=B4=D0=BE=D1=80=20=D0=92=D0=B5=D1=81=D0=B5?= =?UTF-8?q?=D0=BB=D0=BE=D0=B2?= Date: Sun, 29 Sep 2024 15:06:51 +0500 Subject: [PATCH] Moved scripts to namespaces --- scenes/entities/plants/pea.tscn | 2 +- scripts/Cursor.cs | 2 ++ scripts/LevelButton.cs | 2 ++ scripts/LevelController.cs | 2 ++ scripts/Sun.cs | 5 ++++- scripts/Utility.cs | 2 ++ scripts/components/FlashComponent.cs | 2 ++ scripts/components/IEntity.cs | 2 ++ scripts/components/IProjectile.cs | 2 ++ scripts/components/LevelGUIElements.cs | 2 ++ scripts/{ => components}/LinearProjectile.cs | 2 ++ scripts/components/gui/FastForwardButton.cs | 3 ++- scripts/components/gui/ShovelButton.cs | 5 ++++- scripts/components/gui/SunCounter.cs | 4 +++- scripts/components/gui/VeilResizer.cs | 3 ++- scripts/components/gui/choose_your_seeds/GridLoader.cs | 4 +++- scripts/components/gui/choose_your_seeds/LevelRunButton.cs | 3 +++ scripts/components/gui/seedpackets/ChoosableHandler.cs | 2 ++ scripts/components/gui/seedpackets/HotbarHandler.cs | 6 ++++-- scripts/components/gui/seedpackets/HotbarPregameHandler.cs | 5 ++++- scripts/components/gui/seedpackets/ISeedpacketPress.cs | 2 ++ scripts/components/gui/seedpackets/ISeedpacketProcess.cs | 2 ++ scripts/components/gui/seedpackets/ISeedpacketUnfocus.cs | 2 ++ scripts/components/gui/seedpackets/Seedpacket.cs | 3 ++- scripts/components/gui/seedpackets/SeedpacketHandler.cs | 2 ++ scripts/components/level/PlantField.cs | 6 +++++- scripts/components/level/PoolContainer.cs | 2 ++ scripts/components/level/RuntimeLevelData.cs | 3 ++- scripts/components/level/SunSpawner.cs | 3 ++- scripts/components/plants/AreaAttack.cs | 4 +++- scripts/components/plants/ExplosionComponent.cs | 3 +++ scripts/components/plants/Eyesight.cs | 2 ++ scripts/components/plants/PlantEyesightLimiter.cs | 3 ++- scripts/components/plants/PlantSunSpawner.cs | 4 +++- scripts/components/plants/RuntimePlantData.cs | 4 +++- scripts/components/plants/Shooter.cs | 3 +++ scripts/components/plants/behaviours/PeashooterBehaviour.cs | 3 ++- scripts/components/plants/behaviours/PotatomineBehaviour.cs | 2 ++ scripts/components/plants/behaviours/SpikeweedBehaviour.cs | 3 ++- scripts/components/plants/behaviours/SunflowerBehaviour.cs | 3 ++- scripts/components/plants/behaviours/WallnutBehaviour.cs | 3 ++- scripts/components/zombies/AudioDamage.cs | 3 ++- scripts/components/zombies/EatBox.cs | 5 ++++- scripts/components/zombies/RuntimeZombieData.cs | 3 ++- scripts/components/zombies/ZombieMover.cs | 3 ++- .../components/zombies/behaviours/BasicZombieBehaviour.cs | 3 ++- scripts/debug/Cheats.cs | 5 ++++- scripts/debug/Clock.cs | 2 ++ scripts/resources/PlantResource.cs | 3 ++- scripts/systems/effects/Effect.cs | 2 ++ scripts/systems/effects/IEffectHandler.cs | 6 ++++++ 51 files changed, 128 insertions(+), 29 deletions(-) rename scripts/{ => components}/LinearProjectile.cs (96%) create mode 100644 scripts/systems/effects/IEffectHandler.cs diff --git a/scenes/entities/plants/pea.tscn b/scenes/entities/plants/pea.tscn index 9f6ba2e..c880e8b 100644 --- a/scenes/entities/plants/pea.tscn +++ b/scenes/entities/plants/pea.tscn @@ -1,6 +1,6 @@ [gd_scene load_steps=4 format=3 uid="uid://b2hrv0aqbui7u"] -[ext_resource type="Script" path="res://scripts/LinearProjectile.cs" id="1_3kc4s"] +[ext_resource type="Script" path="res://scripts/components/LinearProjectile.cs" id="1_3kc4s"] [ext_resource type="Texture2D" uid="uid://dq0mul65hevtt" path="res://assets/sprites/plants/pea.tres" id="2_26q5x"] [sub_resource type="CircleShape2D" id="CircleShape2D_ix1sk"] diff --git a/scripts/Cursor.cs b/scripts/Cursor.cs index 2e96119..6d384bb 100644 --- a/scripts/Cursor.cs +++ b/scripts/Cursor.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon; + public partial class Cursor : Node { public static Cursor Instance { get; private set; } diff --git a/scripts/LevelButton.cs b/scripts/LevelButton.cs index 96637a1..600120e 100644 --- a/scripts/LevelButton.cs +++ b/scripts/LevelButton.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon; + // // Button that contains level to load // diff --git a/scripts/LevelController.cs b/scripts/LevelController.cs index d80d4b6..6cd3090 100644 --- a/scripts/LevelController.cs +++ b/scripts/LevelController.cs @@ -1,5 +1,7 @@ using Godot; +namespace Newlon; + // // Class that gives access to level data, pools and etc. // diff --git a/scripts/Sun.cs b/scripts/Sun.cs index 5c966e8..ef3053a 100644 --- a/scripts/Sun.cs +++ b/scripts/Sun.cs @@ -1,5 +1,8 @@ using Godot; -using System; +using Newlon.Components.Level; + + +namespace Newlon; public partial class Sun : Area2D { diff --git a/scripts/Utility.cs b/scripts/Utility.cs index 7fc941b..9abaf30 100644 --- a/scripts/Utility.cs +++ b/scripts/Utility.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon; + // // Class for general-used constants and utility tools // diff --git a/scripts/components/FlashComponent.cs b/scripts/components/FlashComponent.cs index 201ce43..65eb6eb 100644 --- a/scripts/components/FlashComponent.cs +++ b/scripts/components/FlashComponent.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon.Components; + public partial class FlashComponent : CanvasGroup { [Export] private float _flashDuration = 0.1f; diff --git a/scripts/components/IEntity.cs b/scripts/components/IEntity.cs index fb481a8..cf39179 100644 --- a/scripts/components/IEntity.cs +++ b/scripts/components/IEntity.cs @@ -1,3 +1,5 @@ +namespace Newlon.Components; + // // Base interface for entities // diff --git a/scripts/components/IProjectile.cs b/scripts/components/IProjectile.cs index a7ca6bb..19b212c 100644 --- a/scripts/components/IProjectile.cs +++ b/scripts/components/IProjectile.cs @@ -1,3 +1,5 @@ +namespace Newlon.Components; + // // Base interface for entities // diff --git a/scripts/components/LevelGUIElements.cs b/scripts/components/LevelGUIElements.cs index 098b986..8d74ea1 100644 --- a/scripts/components/LevelGUIElements.cs +++ b/scripts/components/LevelGUIElements.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon.Components; + public partial class LevelGUIElements : Control { public static LevelGUIElements Instance; diff --git a/scripts/LinearProjectile.cs b/scripts/components/LinearProjectile.cs similarity index 96% rename from scripts/LinearProjectile.cs rename to scripts/components/LinearProjectile.cs index dc9a29d..27d73f9 100644 --- a/scripts/LinearProjectile.cs +++ b/scripts/components/LinearProjectile.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon.Components; + // // Projectile that travels from left to right // diff --git a/scripts/components/gui/FastForwardButton.cs b/scripts/components/gui/FastForwardButton.cs index f686256..20bb321 100644 --- a/scripts/components/gui/FastForwardButton.cs +++ b/scripts/components/gui/FastForwardButton.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.GUI; public partial class FastForwardButton : Button { diff --git a/scripts/components/gui/ShovelButton.cs b/scripts/components/gui/ShovelButton.cs index 423a5ee..2b21c8b 100644 --- a/scripts/components/gui/ShovelButton.cs +++ b/scripts/components/gui/ShovelButton.cs @@ -1,5 +1,8 @@ using Godot; -using System; +using Newlon.Components.Plants; +using Newlon.Components.Level; + +namespace Newlon.Components.GUI; public partial class ShovelButton : TextureButton { diff --git a/scripts/components/gui/SunCounter.cs b/scripts/components/gui/SunCounter.cs index f840303..fa7c11f 100644 --- a/scripts/components/gui/SunCounter.cs +++ b/scripts/components/gui/SunCounter.cs @@ -1,5 +1,7 @@ using Godot; -using System; +using Newlon.Components.Level; + +namespace Newlon.Components.GUI; public partial class SunCounter : Label { diff --git a/scripts/components/gui/VeilResizer.cs b/scripts/components/gui/VeilResizer.cs index 7ec5506..c7c5a44 100644 --- a/scripts/components/gui/VeilResizer.cs +++ b/scripts/components/gui/VeilResizer.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.GUI; public partial class VeilResizer : TextureProgressBar { diff --git a/scripts/components/gui/choose_your_seeds/GridLoader.cs b/scripts/components/gui/choose_your_seeds/GridLoader.cs index 8b9a52c..fe9e145 100644 --- a/scripts/components/gui/choose_your_seeds/GridLoader.cs +++ b/scripts/components/gui/choose_your_seeds/GridLoader.cs @@ -1,5 +1,7 @@ using Godot; -using System; +using Newlon.Components.GUI.Seedpackets; + +namespace Newlon.Components.GUI; public partial class GridLoader : GridContainer { diff --git a/scripts/components/gui/choose_your_seeds/LevelRunButton.cs b/scripts/components/gui/choose_your_seeds/LevelRunButton.cs index 4919d81..6b58495 100644 --- a/scripts/components/gui/choose_your_seeds/LevelRunButton.cs +++ b/scripts/components/gui/choose_your_seeds/LevelRunButton.cs @@ -1,4 +1,7 @@ using Godot; +using Newlon.Components.Level; + +namespace Newlon.Components.GUI; public partial class LevelRunButton : Button { diff --git a/scripts/components/gui/seedpackets/ChoosableHandler.cs b/scripts/components/gui/seedpackets/ChoosableHandler.cs index 99c5d09..68d8a39 100644 --- a/scripts/components/gui/seedpackets/ChoosableHandler.cs +++ b/scripts/components/gui/seedpackets/ChoosableHandler.cs @@ -1,3 +1,5 @@ +namespace Newlon.Components.GUI.Seedpackets; + public class ChoosableHandler : SeedpacketHandler, ISeedpacketPress { public ChoosableHandler(Seedpacket owner) : base(owner) diff --git a/scripts/components/gui/seedpackets/HotbarHandler.cs b/scripts/components/gui/seedpackets/HotbarHandler.cs index 2d18957..e0d3994 100644 --- a/scripts/components/gui/seedpackets/HotbarHandler.cs +++ b/scripts/components/gui/seedpackets/HotbarHandler.cs @@ -1,5 +1,7 @@ -using System; -using Godot; +using Newlon.Components.Level; + +namespace Newlon.Components.GUI.Seedpackets; + public class HotbarHandler : SeedpacketHandler, ISeedpacketPress, ISeedpacketProcess, ISeedpacketUnfocus { public HotbarHandler(Seedpacket owner) : base(owner) diff --git a/scripts/components/gui/seedpackets/HotbarPregameHandler.cs b/scripts/components/gui/seedpackets/HotbarPregameHandler.cs index 2bf8a3b..242cfc5 100644 --- a/scripts/components/gui/seedpackets/HotbarPregameHandler.cs +++ b/scripts/components/gui/seedpackets/HotbarPregameHandler.cs @@ -1,5 +1,8 @@ using System; -using Godot; +using Newlon.Components.Level; + +namespace Newlon.Components.GUI.Seedpackets; + public class HotbarPregameHandler : SeedpacketHandler, ISeedpacketPress { public HotbarPregameHandler(Seedpacket owner) : base(owner) diff --git a/scripts/components/gui/seedpackets/ISeedpacketPress.cs b/scripts/components/gui/seedpackets/ISeedpacketPress.cs index b4bcd1e..f722008 100644 --- a/scripts/components/gui/seedpackets/ISeedpacketPress.cs +++ b/scripts/components/gui/seedpackets/ISeedpacketPress.cs @@ -1,3 +1,5 @@ +namespace Newlon.Components.GUI.Seedpackets; + public interface ISeedpacketPress { public void Pressed(); diff --git a/scripts/components/gui/seedpackets/ISeedpacketProcess.cs b/scripts/components/gui/seedpackets/ISeedpacketProcess.cs index f1e061b..7ee059b 100644 --- a/scripts/components/gui/seedpackets/ISeedpacketProcess.cs +++ b/scripts/components/gui/seedpackets/ISeedpacketProcess.cs @@ -1,3 +1,5 @@ +namespace Newlon.Components.GUI.Seedpackets; + public interface ISeedpacketProcess { public void Process(); diff --git a/scripts/components/gui/seedpackets/ISeedpacketUnfocus.cs b/scripts/components/gui/seedpackets/ISeedpacketUnfocus.cs index ffe363a..fe86942 100644 --- a/scripts/components/gui/seedpackets/ISeedpacketUnfocus.cs +++ b/scripts/components/gui/seedpackets/ISeedpacketUnfocus.cs @@ -1,3 +1,5 @@ +namespace Newlon.Components.GUI.Seedpackets; + public interface ISeedpacketUnfocus { public void OnUnfocused(); diff --git a/scripts/components/gui/seedpackets/Seedpacket.cs b/scripts/components/gui/seedpackets/Seedpacket.cs index 3a3be24..b556dee 100644 --- a/scripts/components/gui/seedpackets/Seedpacket.cs +++ b/scripts/components/gui/seedpackets/Seedpacket.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.GUI.Seedpackets; public partial class Seedpacket : TextureButton { diff --git a/scripts/components/gui/seedpackets/SeedpacketHandler.cs b/scripts/components/gui/seedpackets/SeedpacketHandler.cs index d430b29..d5d30bf 100644 --- a/scripts/components/gui/seedpackets/SeedpacketHandler.cs +++ b/scripts/components/gui/seedpackets/SeedpacketHandler.cs @@ -1,3 +1,5 @@ +namespace Newlon.Components.GUI.Seedpackets; + public class SeedpacketHandler { protected Seedpacket _owner; diff --git a/scripts/components/level/PlantField.cs b/scripts/components/level/PlantField.cs index cefc3c7..35ef88b 100644 --- a/scripts/components/level/PlantField.cs +++ b/scripts/components/level/PlantField.cs @@ -1,4 +1,8 @@ using Godot; +using Newlon.Components.GUI.Seedpackets; +using Newlon.Components.Plants; + +namespace Newlon.Components.Level; public partial class PlantField : Node2D { @@ -64,7 +68,7 @@ public partial class PlantField : Node2D if (canPlace) _plantSetter.GlobalPosition = expected_pos; - _plantSetter.Texture = _resource == null ? null : _resource.Preview; + _plantSetter.Texture = _resource?.Preview; } public override void _UnhandledInput(InputEvent @event) diff --git a/scripts/components/level/PoolContainer.cs b/scripts/components/level/PoolContainer.cs index 8a15c3f..a90fef4 100644 --- a/scripts/components/level/PoolContainer.cs +++ b/scripts/components/level/PoolContainer.cs @@ -1,6 +1,8 @@ using Godot; using System.Collections.Generic; +namespace Newlon.Components.Level; + // // PoolContainer contains nodes that contain different elemnts that generate during runtime // Is not pool in traditional sense, but named like that to prevent repetition diff --git a/scripts/components/level/RuntimeLevelData.cs b/scripts/components/level/RuntimeLevelData.cs index 27894dd..04f2b44 100644 --- a/scripts/components/level/RuntimeLevelData.cs +++ b/scripts/components/level/RuntimeLevelData.cs @@ -1,6 +1,7 @@ using System; using Godot; -//using Godot.Collections; + +namespace Newlon.Components.Level; public partial class RuntimeLevelData : Node { diff --git a/scripts/components/level/SunSpawner.cs b/scripts/components/level/SunSpawner.cs index 5bd3ff9..8bfb473 100644 --- a/scripts/components/level/SunSpawner.cs +++ b/scripts/components/level/SunSpawner.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Level; public partial class SunSpawner : Node { diff --git a/scripts/components/plants/AreaAttack.cs b/scripts/components/plants/AreaAttack.cs index 18f7c8b..abe660d 100644 --- a/scripts/components/plants/AreaAttack.cs +++ b/scripts/components/plants/AreaAttack.cs @@ -1,5 +1,7 @@ using Godot; -using System; +using Newlon.Components.Zombies; + +namespace Newlon.Components.Plants; public partial class AreaAttack : Area2D { diff --git a/scripts/components/plants/ExplosionComponent.cs b/scripts/components/plants/ExplosionComponent.cs index 556c1ab..d0fccd1 100644 --- a/scripts/components/plants/ExplosionComponent.cs +++ b/scripts/components/plants/ExplosionComponent.cs @@ -1,4 +1,7 @@ using Godot; +using Newlon.Components.Zombies; + +namespace Newlon.Components.Plants; public partial class ExplosionComponent : Area2D { diff --git a/scripts/components/plants/Eyesight.cs b/scripts/components/plants/Eyesight.cs index 22fb179..1546b48 100644 --- a/scripts/components/plants/Eyesight.cs +++ b/scripts/components/plants/Eyesight.cs @@ -1,6 +1,8 @@ using Godot; using System.Collections.Generic; +namespace Newlon.Components.Plants; + public partial class Eyesight : Area2D { private bool _enemyDetected; diff --git a/scripts/components/plants/PlantEyesightLimiter.cs b/scripts/components/plants/PlantEyesightLimiter.cs index 8e546cd..1b1f628 100644 --- a/scripts/components/plants/PlantEyesightLimiter.cs +++ b/scripts/components/plants/PlantEyesightLimiter.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Plants; public partial class PlantEyesightLimiter : CollisionShape2D { diff --git a/scripts/components/plants/PlantSunSpawner.cs b/scripts/components/plants/PlantSunSpawner.cs index 5c7c231..d320d79 100644 --- a/scripts/components/plants/PlantSunSpawner.cs +++ b/scripts/components/plants/PlantSunSpawner.cs @@ -1,5 +1,7 @@ using Godot; -using System; +using Newlon.Components.Level; + +namespace Newlon.Components.Plants; public partial class PlantSunSpawner : Node2D { diff --git a/scripts/components/plants/RuntimePlantData.cs b/scripts/components/plants/RuntimePlantData.cs index 0b55a26..468438a 100644 --- a/scripts/components/plants/RuntimePlantData.cs +++ b/scripts/components/plants/RuntimePlantData.cs @@ -1,5 +1,7 @@ using Godot; -using System; +using Newlon.Components.Level; + +namespace Newlon.Components.Plants; // // Data that plant stores during runtime diff --git a/scripts/components/plants/Shooter.cs b/scripts/components/plants/Shooter.cs index 8340823..cf5966f 100644 --- a/scripts/components/plants/Shooter.cs +++ b/scripts/components/plants/Shooter.cs @@ -1,4 +1,7 @@ using Godot; +using Newlon.Components.Level; + +namespace Newlon.Components.Plants; // Shoot component of some plants public partial class Shooter : Node2D diff --git a/scripts/components/plants/behaviours/PeashooterBehaviour.cs b/scripts/components/plants/behaviours/PeashooterBehaviour.cs index 5f6edf3..97d6033 100644 --- a/scripts/components/plants/behaviours/PeashooterBehaviour.cs +++ b/scripts/components/plants/behaviours/PeashooterBehaviour.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Plants.Behaviours; public partial class PeashooterBehaviour : Node { diff --git a/scripts/components/plants/behaviours/PotatomineBehaviour.cs b/scripts/components/plants/behaviours/PotatomineBehaviour.cs index 185b2f8..35232a7 100644 --- a/scripts/components/plants/behaviours/PotatomineBehaviour.cs +++ b/scripts/components/plants/behaviours/PotatomineBehaviour.cs @@ -1,5 +1,7 @@ using Godot; +namespace Newlon.Components.Plants.Behaviours; + public partial class PotatomineBehaviour : Node { [Export] private AnimationPlayer _player; diff --git a/scripts/components/plants/behaviours/SpikeweedBehaviour.cs b/scripts/components/plants/behaviours/SpikeweedBehaviour.cs index 545e4cd..d175907 100644 --- a/scripts/components/plants/behaviours/SpikeweedBehaviour.cs +++ b/scripts/components/plants/behaviours/SpikeweedBehaviour.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Plants.Behaviours; public partial class SpikeweedBehaviour : Node { diff --git a/scripts/components/plants/behaviours/SunflowerBehaviour.cs b/scripts/components/plants/behaviours/SunflowerBehaviour.cs index 4f151a4..292c56f 100644 --- a/scripts/components/plants/behaviours/SunflowerBehaviour.cs +++ b/scripts/components/plants/behaviours/SunflowerBehaviour.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Plants.Behaviours; public partial class SunflowerBehaviour : Node { diff --git a/scripts/components/plants/behaviours/WallnutBehaviour.cs b/scripts/components/plants/behaviours/WallnutBehaviour.cs index a886c0b..88573e5 100644 --- a/scripts/components/plants/behaviours/WallnutBehaviour.cs +++ b/scripts/components/plants/behaviours/WallnutBehaviour.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Plants.Behaviours; public partial class WallnutBehaviour : Node { diff --git a/scripts/components/zombies/AudioDamage.cs b/scripts/components/zombies/AudioDamage.cs index 30ac389..2152342 100644 --- a/scripts/components/zombies/AudioDamage.cs +++ b/scripts/components/zombies/AudioDamage.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Zombies; public partial class AudioDamage : AudioStreamPlayer2D { diff --git a/scripts/components/zombies/EatBox.cs b/scripts/components/zombies/EatBox.cs index 56a9607..9091843 100644 --- a/scripts/components/zombies/EatBox.cs +++ b/scripts/components/zombies/EatBox.cs @@ -1,5 +1,8 @@ using Godot; -using System; +using Newlon.Components.Plants; + + +namespace Newlon.Components.Zombies; public partial class EatBox : Area2D { diff --git a/scripts/components/zombies/RuntimeZombieData.cs b/scripts/components/zombies/RuntimeZombieData.cs index 5aacc3d..ceaa425 100644 --- a/scripts/components/zombies/RuntimeZombieData.cs +++ b/scripts/components/zombies/RuntimeZombieData.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Zombies; public partial class RuntimeZombieData : Node2D, IEntity { diff --git a/scripts/components/zombies/ZombieMover.cs b/scripts/components/zombies/ZombieMover.cs index 196297e..73b0f55 100644 --- a/scripts/components/zombies/ZombieMover.cs +++ b/scripts/components/zombies/ZombieMover.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Zombies; public partial class ZombieMover : Node { diff --git a/scripts/components/zombies/behaviours/BasicZombieBehaviour.cs b/scripts/components/zombies/behaviours/BasicZombieBehaviour.cs index 863b9be..5f52db2 100644 --- a/scripts/components/zombies/behaviours/BasicZombieBehaviour.cs +++ b/scripts/components/zombies/behaviours/BasicZombieBehaviour.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon.Components.Zombies.Behaviours; public partial class BasicZombieBehaviour : Node { diff --git a/scripts/debug/Cheats.cs b/scripts/debug/Cheats.cs index fb277d2..701fb4f 100644 --- a/scripts/debug/Cheats.cs +++ b/scripts/debug/Cheats.cs @@ -1,5 +1,8 @@ using Godot; -using System; +using Newlon.Components.Level; + + +namespace Newlon.Debug; public partial class Cheats : Node { diff --git a/scripts/debug/Clock.cs b/scripts/debug/Clock.cs index 7d97deb..bc8eb10 100644 --- a/scripts/debug/Clock.cs +++ b/scripts/debug/Clock.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon.Debug; + // // Debug tool to check time since clock loaded // diff --git a/scripts/resources/PlantResource.cs b/scripts/resources/PlantResource.cs index a878cc9..2164a26 100644 --- a/scripts/resources/PlantResource.cs +++ b/scripts/resources/PlantResource.cs @@ -1,5 +1,6 @@ using Godot; -using System; + +namespace Newlon; [GlobalClass] public partial class PlantResource : Resource diff --git a/scripts/systems/effects/Effect.cs b/scripts/systems/effects/Effect.cs index b800c46..8a71409 100644 --- a/scripts/systems/effects/Effect.cs +++ b/scripts/systems/effects/Effect.cs @@ -1,6 +1,8 @@ using Godot; using System; +namespace Newlon.Systems.Effects; + public abstract partial class Effect : Resource { public abstract void Enter(); diff --git a/scripts/systems/effects/IEffectHandler.cs b/scripts/systems/effects/IEffectHandler.cs new file mode 100644 index 0000000..b07f020 --- /dev/null +++ b/scripts/systems/effects/IEffectHandler.cs @@ -0,0 +1,6 @@ +namespace Newlon.Systems.Effects; + +public interface IEffectHandler +{ + +} \ No newline at end of file