Skip to content
This repository has been archived by the owner on Sep 18, 2022. It is now read-only.

Commit

Permalink
Added UIWidget
Browse files Browse the repository at this point in the history
  • Loading branch information
craftersmine committed Mar 18, 2019
1 parent b1f337f commit 48c9956
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
11 changes: 11 additions & 0 deletions craftersmine.EtherEngine.Core/Scene.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ public class Scene
private Color _bgColor;

internal List<GameObject> GameObjects = new List<GameObject>();
internal List<UIWidget> UIWidgets = new List<UIWidget>();

internal Dictionary<string, AudioChannel> AudioChannels = new Dictionary<string, AudioChannel>();

Expand Down Expand Up @@ -120,6 +121,16 @@ public AudioChannel GetAudioChannel(string id)
else return null;
}

public void AddUIWidget(UIWidget widget)
{
UIWidgets.Add(widget);
}

public void RemoveUIWidget(UIWidget widget)
{
UIWidgets.Remove(widget);
}

internal void InternalCreate()
{
SceneCamera = new Camera(Game.GameWnd.WindowSize.Width, Game.GameWnd.WindowSize.Height);
Expand Down
14 changes: 14 additions & 0 deletions craftersmine.EtherEngine.Core/UIWidget.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace craftersmine.EtherEngine.Core
{
public class UIWidget : GameObject
{
public UIWidget()
{ }
}
}

0 comments on commit 48c9956

Please sign in to comment.