Changed terminate into unload
This commit is contained in:
@@ -6,7 +6,7 @@ namespace Awperative;
|
|||||||
|
|
||||||
public sealed partial class Body
|
public sealed partial class Body
|
||||||
{
|
{
|
||||||
public void Terminate() { foreach (Component component in components) component.Terminate(); }
|
public void Unload() { foreach (Component component in components) component.Unload(); }
|
||||||
|
|
||||||
public void Load() { foreach (Component component in components) { component.Load(); } }
|
public void Load() { foreach (Component component in components) { component.Load(); } }
|
||||||
|
|
||||||
|
|||||||
@@ -6,9 +6,9 @@ namespace Awperative;
|
|||||||
public sealed partial class Scene
|
public sealed partial class Scene
|
||||||
{
|
{
|
||||||
|
|
||||||
public void Terminate() {
|
public void Unload() {
|
||||||
foreach (Behavior behavior in behaviors) behavior.Terminate();
|
foreach (Behavior behavior in behaviors) behavior.Unload();
|
||||||
foreach (Body body in bodies) body.Terminate();
|
foreach (Body body in bodies) body.Unload();
|
||||||
}
|
}
|
||||||
|
|
||||||
public void Load() {
|
public void Load() {
|
||||||
|
|||||||
@@ -13,5 +13,5 @@ public interface AwperativeHook
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Called when the program closes.
|
/// Called when the program closes.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void Terminate() {}
|
public void Unload() {}
|
||||||
}
|
}
|
||||||
@@ -20,8 +20,7 @@ public sealed class Base : Game
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Initialize() is called when the program starts. It can be confusing because Initialize() in hooks and events is actually LoadContent().
|
/// Initialize() is called when the program starts. Goes before LoadContent(). And prepares the kernel for use.
|
||||||
/// This is because Initialize() has little utility and there is no reason to
|
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <remarks> It is recommended not to load content in Initialize()</remarks>
|
/// <remarks> It is recommended not to load content in Initialize()</remarks>
|
||||||
protected override void Initialize() {
|
protected override void Initialize() {
|
||||||
@@ -65,7 +64,7 @@ public sealed class Base : Game
|
|||||||
/// </summary>
|
/// </summary>
|
||||||
/// <remarks> This event may not trigger if the program is force closed.</remarks>
|
/// <remarks> This event may not trigger if the program is force closed.</remarks>
|
||||||
protected override void EndRun() {
|
protected override void EndRun() {
|
||||||
foreach (AwperativeHook hook in Awperative.EventHooks) hook.Terminate();
|
foreach (AwperativeHook hook in Awperative.EventHooks) hook.Unload();
|
||||||
foreach (Scene scene in Awperative.LoadedScenes) scene.Terminate();
|
foreach (Scene scene in Awperative.LoadedScenes) scene.Unload();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -37,7 +37,7 @@ public abstract class Behavior
|
|||||||
|
|
||||||
|
|
||||||
//GAME HAS JUST BEGUN/ended
|
//GAME HAS JUST BEGUN/ended
|
||||||
public virtual void Terminate() {}
|
public virtual void Unload() {}
|
||||||
|
|
||||||
//WE ARE LOADING STUFF
|
//WE ARE LOADING STUFF
|
||||||
public virtual void Load() {}
|
public virtual void Load() {}
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ public abstract class Component
|
|||||||
|
|
||||||
|
|
||||||
//GAME HAS JUST BEGUN/ended
|
//GAME HAS JUST BEGUN/ended
|
||||||
public virtual void Terminate() {}
|
public virtual void Unload() {}
|
||||||
|
|
||||||
//WE ARE LOADING STUFF
|
//WE ARE LOADING STUFF
|
||||||
public virtual void Load() {}
|
public virtual void Load() {}
|
||||||
|
|||||||
Reference in New Issue
Block a user