PlayerHasExploredWorldIndex() public method

public PlayerHasExploredWorldIndex ( Vector2 worldIndex ) : bool
worldIndex Vector2
return bool
Exemplo n.º 1
0
        public void Draw(GameTime gameTime)
        {
            if (_world.PlayerHasExploredWorldIndex(WorldIndex))
            {
                Vector2 worldPosition  = _world.ConvertTileIndexToWorldPosition(WorldIndex.X, WorldIndex.Y);
                Vector2 screenPosition = Camera.GetScreenPosition(worldPosition);

                if (IsOpen)
                {
                    GraphicsHelper.spriteBatch.Draw(_openImage, screenPosition, null, Color.White, 0f, new Vector2(0, 0), 1f, SpriteEffects.None, 0.7f);
                }
                else
                {
                    GraphicsHelper.spriteBatch.Draw(_closedImage, screenPosition, null, Color.White, 0f, new Vector2(0, 0), 1f, SpriteEffects.None, 0.7f);
                }
            }
        }