17 lines
461 B
C#
17 lines
461 B
C#
using Godot;
|
|
using GodotHostTest.AetherBind;
|
|
using OwofGames.AetherBind;
|
|
|
|
namespace GodotHostTest.Game.Turret;
|
|
|
|
[Injected]
|
|
public partial class Turret : Sprite2D
|
|
{
|
|
[Export] private PackedScene _projectilePackedScene = null!;
|
|
[Inject] private ISceneInstantiator _sceneInstantiator = null!;
|
|
|
|
public override void _Ready()
|
|
{
|
|
GetTree().CreateTimer(1).Timeout += () => AddChild(_sceneInstantiator.Instantiate(_projectilePackedScene));
|
|
}
|
|
} |