56 lines
1.3 KiB
C#
56 lines
1.3 KiB
C#
using System;
|
|
using FlaxEngine;
|
|
using Console = Cabrito.Console;
|
|
#if FLAX_EDITOR
|
|
using FlaxEditor;
|
|
#endif
|
|
|
|
namespace Game
|
|
{
|
|
public class ConsolePlugin : GamePlugin
|
|
{
|
|
public static PluginDescription DescriptionInternal = new PluginDescription
|
|
{
|
|
Author = "Ari Vuollet",
|
|
Name = "Console",
|
|
Description = "Quake-like console",
|
|
Version = Version.Parse("0.1.0"),
|
|
IsAlpha = true,
|
|
Category = "Game"
|
|
};
|
|
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
Debug.Log("ConsolePlugin Initialize");
|
|
|
|
Console.Init();
|
|
}
|
|
|
|
public override void Deinitialize()
|
|
{
|
|
base.Deinitialize();
|
|
Debug.Log("ConsolePlugin Deinitialize");
|
|
}
|
|
}
|
|
|
|
#if FLAX_EDITOR
|
|
public class ConsoleEditorPlugin : EditorPlugin
|
|
{
|
|
public override PluginDescription Description => ConsolePlugin.DescriptionInternal;
|
|
|
|
public override Type GamePluginType => typeof(ConsolePlugin);
|
|
|
|
public override void Initialize()
|
|
{
|
|
Debug.Log("ConsoleEditorPlugin Initialize");
|
|
Console.Init();
|
|
}
|
|
|
|
public override void Deinitialize()
|
|
{
|
|
Debug.Log("ConsoleEditorPlugin Deinitialize");
|
|
}
|
|
}
|
|
#endif
|
|
} |