using System.Collections.Generic; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Graphics; using V3.Camera; using V3.Map; namespace V3.Objects { /// /// Objects manager for all game objects, be is creatures or buildings or even simple landscape objects. /// public interface IObjectsManager { //***** FOR TESTING PURPOSES! List AddToSelectables { get; } List CreatureList { get; } List UndeadCreatures { get; } //List KingdromCreatures { get; } //List PlebCreatures { get; } //***** NOT FOR TESTING PURPOSES ANYMORE! /// /// Gets the current player character. Usually the necromancer. /// Do not set directly! Use CreatePlayerCharacter() instead! /// ICreature PlayerCharacter { get; } ICreature Boss { get; } ICreature Prince { get; } Castle Castle { get; } /// /// If you load a new map with new objects you need to initialize the objects manager again. /// (Or else you have all the current objects on the new map.) /// /// void Initialize(IMapManager mapManager); /// /// Removes all objects from the object manager. /// void Clear(); /// /// Creates the player character. This should be the first thing you do /// after you created or initialized the objects manager. /// /// void CreatePlayerCharacter(Necromancer necromancer); /// /// Creates the boss of the level. Game is won if the boss is killed. /// /// Some ICreature to kill for winning. void CreateBoss(ICreature boss); /// /// Create the prince, a small boss. /// /// Some hard ICreature to kill. void CreatePrince(ICreature prince); /// /// Creates a creature for the game and inserts it in the appropriate data structures. /// /// void CreateCreature(ICreature creature); /// /// Removes specified creature from the game. /// /// The creature to be removed. void RemoveCreature(ICreature creature); /// /// Draws all currently shown objects on the map. /// /// The sprite batch used. /// Camera for calculating which objects need to be drawn. void Draw(SpriteBatch spriteBatch, ICamera camera); /// /// Draws a visual representation of the Quadtree. For debugging purposes. /// /// void DrawQuadtree(SpriteBatch spriteBatch); /// /// Update the behaviour of all creatures on the map. /// /// Current game time. /// Did the player press the right mouse button? /// Where is the mouse currently? /// Camera for checking where to do important updates. void Update(GameTime gameTime, bool rightButtonPressed, Vector2 rightButtonPosition, ICamera camera); /// /// Imports the TextureObjects from the objects map layer for drawing things in the right order. /// /// void ImportMapObjects(List textureObjects); /// /// Get all objects in the given rectangles. /// /// The rectangle which defines the area of the returnes objects. /// Game objects in the rectangle. List GetObjectsInRectangle(Rectangle rectangle); /// /// Gets all creatures which are in the given ellipse area. /// /// To check if creature is in ellipse area. /// List GetCreaturesInEllipse(Ellipse ellipse); /// /// Playing around with some cheating codes. /// void ExposeTheLiving(); /// /// Checks if a creature is standing in a graveyard area. /// /// Check for this creature. /// True when standing in graveyard area. bool InGraveyardArea(ICreature creature); } }