public Goon[] generateGoons(int number, int level, int minStat, int maxStat, int minHP, int maxHP, int minStartRP, int maxStartRP, int minMaxRP, int maxMaxRP, int minRPMod, int maxRPMod) { Goon[] goons = new Goon[number]; for (int i = 0; i < number; i++) { goons[i] = generateGoon(level, minStat, maxStat, minHP, maxHP, minStartRP, maxStartRP, minMaxRP, maxMaxRP, minRPMod, maxRPMod); } return(goons); }
private Goon makeGoon(int[] stats, int hp, int startRP, int maxRP, int rpMod) { Goon.setCharm(stats[0]); Goon.setInt(stats[1]); Goon.setPow(stats[2]); Goon.setSpeed(stats[3]); Goon.setTech(stats[4]); Goon.setHP(hp); Goon.setCurrentRP(startRP); Goon.setMaxRP(maxRP); Goon.setRPMod(rpMod); return(Goon.makeGoon()); }
public void PlaceMonsters(DungeonMap map, Rectangle room) { // Each room has a 60% chance of having monsters //if (Dice.Roll("1D10") < 7) //{ // // Generate between 1 and 4 monsters // var numberOfMonsters = Dice.Roll("1D4"); // for (int i = 0; i < numberOfMonsters; i++) // { // // Find a random walkable location in the room to place the monster // Point randomRoomLocation = _map.GetRandomWalkableLocationInRoom(room); // // It's possible that the room doesn't have space to place a monster // // In that case skip creating the monster // if (randomRoomLocation != null) // { // // Temporarily hard code this monster to be created at level 1 // var monster = Kobold.Create(1); // monster.X = randomRoomLocation.X; // monster.Y = randomRoomLocation.Y; // _map.AddMonster(_map, monster); // } // } //} if (test == true) { // Generate between 1 and 4 monsters var numberOfMonsters = 1; for (int i = 0; i < numberOfMonsters; i++) { // Find a random walkable location in the room to place the monster Point randomRoomLocation = map.GetRandomWalkableLocationInRoom(room); // It's possible that the room doesn't have space to place a monster // In that case skip creating the monster if (randomRoomLocation != null) { // Temporarily hard code this monster to be created at level 1 var monster = Goon.Create(1); monster.X = randomRoomLocation.X; monster.Y = randomRoomLocation.Y; map.AddMonster(map, monster); } } } }