public TDEEditor(GameWindow mGameWindow) { TDGameWindow = mGameWindow; _drawEntities = new List<TDEEntity>(); _elementSprites = new List<Sprite>(); _common = new TDCommon(mGameWindow); _currentOutline = TDEOutlines.GetOutlines().First(); _rectangleMode = true; OnUpdate += mFrameTime => { UpdateSelector(); UpdateInfoText(); }; AddDrawAction(DrawEntities); _previewSpriteCount = 14; for (var i = 0; i < _previewSpriteCount; i++) _elementSprites.Add(new Sprite()); OnDrawAfterDefault += DrawGUI; OnDrawBeforeCamera += _common.GUI.DrawBackground; InitializeInputs(); }
public TDGGame(GameWindow mGameWindow) { _common = new TDCommon(mGameWindow); OnUpdate += mFrameTime => _common.UpdatePositions(); OnDrawBeforeCamera += _common.GUI.DrawBackground; AddDrawAction(DrawEntities); OnDrawAfterDefault += DrawGUI; InitializeInputs(); }