Class ApplicationController
Inheritance
Inherited Members
Namespace: MacacaGames.GameSystem
Assembly: Macaca.GameSystem.dll
Syntax
[ResolveTarget]
public class ApplicationController : MonoBehaviour
Fields
| Improve this Doc View SourceInstance
Declaration
public static ApplicationController Instance
Field Value
Type | Description |
---|---|
ApplicationController |
IsInit
Declaration
public bool IsInit
Field Value
Type | Description |
---|---|
System.Boolean |
Properties
| Improve this Doc View SourceCurrentApplicationState
Current application state
Declaration
public ApplicationController.ApplicationState CurrentApplicationState { get; }
Property Value
Type | Description |
---|---|
ApplicationController.ApplicationState | See ApplicationController.ApplicationState to get more detail about each state |
CurrentGameState
Current application state
Declaration
public ApplicationController.GameState CurrentGameState { get; }
Property Value
Type | Description |
---|---|
ApplicationController.GameState | See ApplicationController.ApplicationState to get more detail about each state |
isInGame
Declaration
public bool isInGame { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
| Improve this Doc View SourceCreateInstance(Type, Boolean)
Create a new instance with target type and do inject immediately
Declaration
public object CreateInstance(Type type, bool inject = true)
Parameters
Type | Name | Description |
---|---|---|
System.Type | type | The object type to create new instance |
System.Boolean | inject | Inject the reference in new instance |
Returns
Type | Description |
---|---|
System.Object | The new Instance |
CreateInstance<T>(Boolean)
Create a new instance with target type and do inject immediately
Declaration
public T CreateInstance<T>(bool inject = true)
where T : class
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | inject | Inject the reference in new instance |
Returns
Type | Description |
---|---|
T |
Type Parameters
Name | Description |
---|---|
T | The object type to create new instance |
GetGamePlayController()
Get Current GamePlayController
Declaration
public GamePlayController GetGamePlayController()
Returns
Type | Description |
---|---|
GamePlayController | The GamePlayController instance, null if no instance |
GetMonobehaviourLifeCycle(Type)
Get the ApplicationLifeCycle instance
Declaration
public object GetMonobehaviourLifeCycle(Type t)
Parameters
Type | Name | Description |
---|---|---|
System.Type | t |
Returns
Type | Description |
---|---|
System.Object | The ApplicationLifeCycle instance, null if no instance |
GetMonobehaviourLifeCycle<T>()
Get the ApplicationLifeCycle instance
Declaration
public T GetMonobehaviourLifeCycle<T>()
where T : MonoBehaviourLifeCycle
Returns
Type | Description |
---|---|
T | The ApplicationLifeCycle instance, null if no instance |
Type Parameters
Name | Description |
---|---|
T | The ApplicationLifeCycle class you wish to get |
GetResloveTargetInstance(Type)
Get the object instance which has Register Attribute
Declaration
public object GetResloveTargetInstance(Type t)
Parameters
Type | Name | Description |
---|---|---|
System.Type | t |
Returns
Type | Description |
---|---|
System.Object | The Register instance, null if no instance |
GetScriptableLifeCycle(Type)
Get the game system instance
Declaration
public object GetScriptableLifeCycle(Type t)
Parameters
Type | Name | Description |
---|---|---|
System.Type | t | The game system class you wish to get |
Returns
Type | Description |
---|---|
System.Object | The game system instance, null if no instance |
GetScriptableLifeCycle<T>()
Get the game system instance
Declaration
public T GetScriptableLifeCycle<T>()
where T : ScriptableObjectLifeCycle
Returns
Type | Description |
---|---|
T | The game system instance, null if no instance |
Type Parameters
Name | Description |
---|---|
T | The game system class you wish to get |
Init()
Declaration
public void Init()
RegistApplicationExecuter(IResumable)
Regist an IResumable which update by Application
Declaration
public void RegistApplicationExecuter(IResumable c)
Parameters
Type | Name | Description |
---|---|---|
Rayark.Mast.IResumable | c |
ResolveInjection(Object)
Inject all member with [Inject] attribute on target object
Declaration
public void ResolveInjection(object injectable)
Parameters
Type | Name | Description |
---|---|---|
System.Object | injectable | The object to inject |
StartGame()
Start the Game
Declaration
public void StartGame()
UnRegistApplicationExecuter(IResumable)
Unregist an IResumable which update by Application
Declaration
public void UnRegistApplicationExecuter(IResumable c)
Parameters
Type | Name | Description |
---|---|---|
Rayark.Mast.IResumable | c |