Changed plugins to abstract classes

This commit is contained in:
SpoinkyNL committed 2019-04-16 00:24:50 +02:00
1 parent c9277ecc4e
commit f63a7b91c8
36 files changed
+657 -300

No files matched your search

@@ -0,0 +1,49 @@
using System.Drawing;
using Artemis.Core.Plugins.Models;
using RGB.NET.Core;
using Stylet;
namespace Artemis.Core.Plugins.Abstract
{
/// <inheritdoc />
/// <summary>
/// Allows you to add support for new games/applications
/// </summary>
public abstract class Module : Plugin
{
protected Module(PluginInfo pluginInfo) : base(pluginInfo)
{
}
/// <summary>
/// The modules display name that's shown in the menu
/// </summary>
public string DisplayName { get; protected set; }
/// <summary>
/// Whether or not this module expands upon the main data model. If set to true any data in main data model can be
/// accessed by profiles in this module
/// </summary>
public bool ExpandsMainDataModel { get; protected set; }
/// <summary>
/// Called each frame when the module must update
/// </summary>
/// <param name="deltaTime">Time since the last update</param>
public abstract void Update(double deltaTime);
/// <summary>
/// Called each frame when the module must render
/// </summary>
/// <param name="deltaTime">Time since the last render</param>
/// <param name="surface">The RGB Surface to render to</param>
/// <param name="graphics"></param>
public abstract void Render(double deltaTime, RGBSurface surface, Graphics graphics);
/// <summary>
/// Called when the module's main view is being shown
/// </summary>
/// <returns></returns>
public abstract IScreen GetMainViewModel();
}
}