-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add prototype dependencies
- Loading branch information
decembrist-revolt
authored and
decembrist-revolt
committed
Apr 26, 2021
1 parent
be9b32c
commit f48dfd2
Showing
20 changed files
with
398 additions
and
107 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
<Project Sdk="Godot.NET.Sdk/3.2.3"> | ||
<Project Sdk="Godot.NET.Sdk/3.3.0"> | ||
<PropertyGroup> | ||
<LangVersion>8</LangVersion> | ||
<LangVersion>9</LangVersion> | ||
<TargetFramework>netcoreapp3.1</TargetFramework> | ||
<RootNamespace>Decembrist</RootNamespace> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Content Include="README.md" /> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,6 @@ | |
{ | ||
public interface IService | ||
{ | ||
public void Run(); | ||
public string GetString(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
namespace Decembrist.Example.Service | ||
{ | ||
public class InstanceService | ||
{ | ||
|
||
public static InstanceService Instance = new InstanceService(); | ||
|
||
private InstanceService() | ||
{ | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using Decembrist.Utils; | ||
|
||
namespace Decembrist.Example.Service | ||
{ | ||
public class PrototypeService1: IService | ||
{ | ||
private readonly SingletonService2 _service; | ||
private readonly string _randomNumber; | ||
|
||
public PrototypeService1(SingletonService2 service) | ||
{ | ||
_service = service; | ||
_randomNumber = Random.RandomInt(1, 100).ToString(); | ||
} | ||
|
||
public string GetString() | ||
{ | ||
return $"{_randomNumber} {_service.GetString()}"; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
using Godot; | ||
|
||
namespace Decembrist.Example.Service | ||
{ | ||
public class SingletonService1 | ||
{ | ||
public string SayHello() => "Hello"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
namespace Decembrist.Example.Service | ||
{ | ||
public class SingletonService2: IService | ||
{ | ||
private readonly SingletonService1 _service1; | ||
|
||
public SingletonService2(SingletonService1 service1) | ||
{ | ||
_service1 = service1; | ||
} | ||
|
||
public string GetString() => _service1.SayHello(); | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
**Godot Decembrist Plugin** | ||
_Utils for godot development_ | ||
* (DI) Dependency Injection for Godot | ||
* Util classes for _Buttons_, _Controls_, _Vectors_ etc |
Oops, something went wrong.