Initial Commit
This commit is contained in:
+21
@@ -0,0 +1,21 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Zenject.Tests.Bindings.FromNewScriptableObjectResource
|
||||
{
|
||||
//[CreateAssetMenu(fileName = "Bob", menuName = "Test/Bob")]
|
||||
public class Bob : ScriptableObject
|
||||
{
|
||||
public string Arg
|
||||
{
|
||||
get;
|
||||
private set;
|
||||
}
|
||||
|
||||
[Inject]
|
||||
public void Construct(string arg)
|
||||
{
|
||||
Arg = arg;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9e40755b32ffa6f4fb5f67e0612fc480
|
||||
timeCreated: 1486670038
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
using UnityEngine;
|
||||
|
||||
namespace Zenject.Tests.Bindings.FromNewScriptableObjectResource
|
||||
{
|
||||
public interface IFoo
|
||||
{
|
||||
}
|
||||
|
||||
//[CreateAssetMenu(fileName = "Foo", menuName = "Test/Foo")]
|
||||
public class Foo : ScriptableObject, IFoo
|
||||
{
|
||||
public static int InstanceCount
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
|
||||
public bool WasInjected
|
||||
{
|
||||
get;
|
||||
private set;
|
||||
}
|
||||
|
||||
[Inject]
|
||||
public void Construct()
|
||||
{
|
||||
WasInjected = true;
|
||||
InstanceCount++;
|
||||
}
|
||||
}
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 70da936d4db31fa4a9f79f7af7604209
|
||||
timeCreated: 1486615350
|
||||
licenseType: Free
|
||||
MonoImporter:
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user