merge commit

This commit is contained in:
AnloGames 2023-08-18 04:19:55 +03:00
parent a0cb764e11
commit 6229d7dda4
2 changed files with 2 additions and 7 deletions

View file

@ -62,11 +62,6 @@ namespace DangerousD.GameCore.GameObjects.LivingEntities
};
}
public Player(Vector2 position, bool isInvincible) : this(position)
{
this.isInvincible = isInvincible;
}
public bool IsAlive { get { return isAlive; } }
protected override GraphicsComponent GraphicsComponent { get; } = new(new List<string> { "playerMoveLeft", "playerMoveRight", "DeathFromZombie", "playerRightStay", "playerStayLeft",

View file

@ -98,9 +98,9 @@ namespace DangerousD.GameCore.Managers
new Vector2(float.Parse(entity.Attributes["x"].Value, CultureInfo.InvariantCulture) + offsetX,
float.Parse(entity.Attributes["y"].Value, CultureInfo.InvariantCulture) + offsetY) * _scale;
Entity inst;
if (type.Equals(typeof(Player)) && entity.Attributes["name"] is not null && entity.Attributes["name"].Value == "DEBUGUS")
if (type.Equals(typeof(Player)))
{
inst = (Entity)Activator.CreateInstance(type, pos, true);
inst = (Entity)Activator.CreateInstance(type, pos, false);
}
else
{