public
Created

  • Download Gist
gistfile1.cs
C#
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
while (map.Layers[0].GetTile((int)position.Y, (int)position.X).TileIndex != 63 && map.Layers[0].GetTile((int)position.Y - 1, (int)position.X).TileIndex != 63)
{
try
{
position = new Vector2(ran.Next(minX, maxX), ran.Next(minY, maxY));
}
catch
{
;
}
 
position *= 64f;
return new Enemy(dmg, health, range, speed, position, new List<Rectangle>(playerCollisionRectangles), (Item)weaponList[weaponIndex].Clone(), GameRef.GraphicsDevice);
 
}

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.