use of gartham.c10ver.games.rpg.fighting.battles.app.GarmonFighter in project c10ver by Gartham.
the class Dungeon method generateRandomRoom.
public static DungeonRoom generateRandomRoom() {
var rand = Math.random();
if (rand < .7)
return new EmptyRoom();
else if (rand < 0.8) {
List<Creature> creechurrs = new ArrayList<>();
var enemy = new Nymph();
if (Math.random() < 0.3)
creechurrs.add(new Nymph());
GarmonTeam team = new GarmonTeam("Wilderness", new GarmonFighter(enemy));
return new EnemyRoom(team);
} else if (rand < 0.95)
return new LootRoom(new RewardsOperation().setCloves(BigInteger.valueOf((long) (Math.random() * 158 + 32))));
else {
var ro = new RewardsOperation();
ro.getMults().put(generateRandomMultiplier(), 1);
if (Math.random() < .2) {
AbstractMultiplier val = generateRandomMultiplier();
if (ro.getMults().containsKey(val))
ro.getMults().put(val, ro.getMults().get(val) + 1);
}
return new LootRoom(ro);
}
}
Aggregations