Index: ps/trunk/binaries/data/mods/public/gui/credits/texts/programming.json =================================================================== --- ps/trunk/binaries/data/mods/public/gui/credits/texts/programming.json +++ ps/trunk/binaries/data/mods/public/gui/credits/texts/programming.json @@ -187,6 +187,7 @@ {"nick": "qwertz"}, {"nick": "Radagast"}, {"nick": "Raj", "name": "Raj Sharma"}, + {"nick": "rapidelectron", "name": "Christian Weihsbach"}, {"nick": "RedFox", "name": "Jorma Rebane"}, {"nick": "RefinedCode"}, {"nick": "Riemer"}, Index: ps/trunk/binaries/data/mods/public/maps/random/aegean_sea.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/aegean_sea.js +++ ps/trunk/binaries/data/mods/public/maps/random/aegean_sea.js @@ -183,12 +183,12 @@ g_Map.log("Creating island stone mines"); createMines( - [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], - [new SimpleObject(oStoneSmall, 2,5, 1,3)] - ], - stayClasses(clIsland, 4), - clRock); + [ + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], + [new SimpleObject(oStoneSmall, 2,5, 1,3)] + ], + stayClasses(clIsland, 4), + clRock); g_Map.log("Creating island metal mines"); createMines( @@ -201,12 +201,12 @@ g_Map.log("Creating stone mines"); createMines( - [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], - [new SimpleObject(oStoneSmall, 2,5, 1,3)] - ], - avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clWater, 1, clHill, 1), - clRock); + [ + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], + [new SimpleObject(oStoneSmall, 2,5, 1,3)] + ], + avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clWater, 1, clHill, 1), + clRock); g_Map.log("Creating metal mines"); createMines( Index: ps/trunk/binaries/data/mods/public/maps/random/african_plains.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/african_plains.js +++ ps/trunk/binaries/data/mods/public/maps/random/african_plains.js @@ -149,8 +149,8 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4)], - [new SimpleObject(oStoneSmall, 2,5, 1,3)] + [new SimpleObject(oStoneSmall, 0, 2, 0, 4)], + [new SimpleObject(oStoneSmall, 2, 5, 1, 3)] ], avoidClasses(clWater, 4, clForest, 4, clPlayer, 20, clRock, 10, clHill, 4), clRock); Index: ps/trunk/binaries/data/mods/public/maps/random/alpine_lakes.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/alpine_lakes.js +++ ps/trunk/binaries/data/mods/public/maps/random/alpine_lakes.js @@ -178,7 +178,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/alpine_valley.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/alpine_valley.js +++ ps/trunk/binaries/data/mods/public/maps/random/alpine_valley.js @@ -422,7 +422,7 @@ Engine.SetProgress(65); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/anatolian_plateau.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/anatolian_plateau.js +++ ps/trunk/binaries/data/mods/public/maps/random/anatolian_plateau.js @@ -129,7 +129,7 @@ Engine.SetProgress(55); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), scaleByMapSize(1,4), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/archipelago.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/archipelago.js +++ ps/trunk/binaries/data/mods/public/maps/random/archipelago.js @@ -175,7 +175,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], [avoidClasses(clForest, 1, clPlayer, 7, clRock, 10, clHill, 1), stayClasses(clLand, 6)], Index: ps/trunk/binaries/data/mods/public/maps/random/arctic_summer.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/arctic_summer.js +++ ps/trunk/binaries/data/mods/public/maps/random/arctic_summer.js @@ -183,7 +183,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2, 5, 1, 3)] ], avoidClasses( Index: ps/trunk/binaries/data/mods/public/maps/random/ardennes_forest.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/ardennes_forest.js +++ ps/trunk/binaries/data/mods/public/maps/random/ardennes_forest.js @@ -345,15 +345,21 @@ Engine.SetProgress(75); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 1,2, 0,4), new SimpleObject(oStoneLarge, 0,1, 0,4)], true, clRock); -createObjectGroupsByAreasDeprecated(group, 0, +createObjectGroupsByAreasDeprecated( + new SimpleGroup( + [ + new SimpleObject(oStoneSmall, 1, 2, 0, 4, 0, 2 * Math.PI, 1), + new SimpleObject(oStoneLarge, 0, 1, 0, 4, 0, 2 * Math.PI, 4) + ], + true, + clRock), + 0, [avoidClasses(clHill, 4, clForest, 2, clPlayer, 20, clRock, 10)], scaleByMapSize(6,20), 100, - [explorableArea] -); + [explorableArea]); g_Map.log("Creating small stone mines"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 2,5, 1,3)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 2, 5, 1, 3)], true, clRock); createObjectGroupsByAreasDeprecated(group, 0, [avoidClasses(clHill, 4, clForest, 2, clPlayer, 20, clRock, 10)], scaleByMapSize(6,20), 100, Index: ps/trunk/binaries/data/mods/public/maps/random/atlas_mountains.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/atlas_mountains.js +++ ps/trunk/binaries/data/mods/public/maps/random/atlas_mountains.js @@ -118,7 +118,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clForest, 1, clPlayer, 20, clMetal, 10, clRock, 5, clHill, 2), Index: ps/trunk/binaries/data/mods/public/maps/random/cantabrian_highlands.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/cantabrian_highlands.js +++ ps/trunk/binaries/data/mods/public/maps/random/cantabrian_highlands.js @@ -195,7 +195,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 0, clForest, 1, clPlayer, 5, clRock, 10, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/canyon.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/canyon.js +++ ps/trunk/binaries/data/mods/public/maps/random/canyon.js @@ -253,7 +253,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], [avoidClasses(clForest, 1, clPlayer, 3, clRock, 10, clHill, 1, clHill2, 1), stayClasses(clLand, 2)], Index: ps/trunk/binaries/data/mods/public/maps/random/continent.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/continent.js +++ ps/trunk/binaries/data/mods/public/maps/random/continent.js @@ -164,7 +164,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], [avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), stayClasses(clLand, 6)], Index: ps/trunk/binaries/data/mods/public/maps/random/corinthian_isthmus.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/corinthian_isthmus.js +++ ps/trunk/binaries/data/mods/public/maps/random/corinthian_isthmus.js @@ -168,7 +168,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clForest, 4, clPlayer, 15, clRock, 10, clWater, 4, clHill, 4), Index: ps/trunk/binaries/data/mods/public/maps/random/cycladic_archipelago.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/cycladic_archipelago.js +++ ps/trunk/binaries/data/mods/public/maps/random/cycladic_archipelago.js @@ -206,7 +206,7 @@ Engine.SetProgress(42); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsByAreasDeprecated(group, 0, [avoidClasses(clWater, 1, clForest, 1, clHill, 1, clPlayer, 5, clRock, 6)], scaleByMapSize(4,16), 200, areas Index: ps/trunk/binaries/data/mods/public/maps/random/dodecanese.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/dodecanese.js +++ ps/trunk/binaries/data/mods/public/maps/random/dodecanese.js @@ -238,7 +238,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2, 5, 1, 3)] ], avoidClasses(clWater, 4, clVolcano, 4, clPlayerIsland, 0, clBaseResource, 4, clForest, 3, clMetal, 4, clRock, 4), Index: ps/trunk/binaries/data/mods/public/maps/random/english_channel.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/english_channel.js +++ ps/trunk/binaries/data/mods/public/maps/random/english_channel.js @@ -164,7 +164,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 2, clForest, 1, clPlayer, 20, clRock, 10, clHill, 2), Index: ps/trunk/binaries/data/mods/public/maps/random/fortress.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/fortress.js +++ ps/trunk/binaries/data/mods/public/maps/random/fortress.js @@ -212,7 +212,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 0, clForest, 1, clPlayer, 5, clRock, 10, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/gear.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/gear.js +++ ps/trunk/binaries/data/mods/public/maps/random/gear.js @@ -233,7 +233,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/guadalquivir_river.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/guadalquivir_river.js +++ ps/trunk/binaries/data/mods/public/maps/random/guadalquivir_river.js @@ -174,7 +174,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], [avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clRiver, 1), stayClasses(clLand, 5)], Index: ps/trunk/binaries/data/mods/public/maps/random/gulf_of_bothnia.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/gulf_of_bothnia.js +++ ps/trunk/binaries/data/mods/public/maps/random/gulf_of_bothnia.js @@ -163,7 +163,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/hellas.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/hellas.js +++ ps/trunk/binaries/data/mods/public/maps/random/hellas.js @@ -331,8 +331,8 @@ g_Map.log("Creating stone mines"); var minesStone = [ - [new SimpleObject(biomes.common.gaia.mines.stoneLarge, 1, 1, 0, 4)], - [new SimpleObject(biomes.common.gaia.mines.stoneSmall, 2, 3, 1, 3)] + [new SimpleObject(biomes.common.gaia.mines.stoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], + [new SimpleObject(biomes.common.gaia.mines.stoneSmall, 2, 3, 1, 3, 0, 2 * Math.PI, 1)] ]; for (let mine of minesStone) createObjectGroups( @@ -345,8 +345,8 @@ g_Map.log("Creating metal mines"); var minesMetal = [ - [new SimpleObject(biomes.common.gaia.mines.metalLarge, 1, 1, 0, 4)], - [new SimpleObject(biomes.common.gaia.mines.metalSmall, 2, 3, 1, 3)] + [new SimpleObject(biomes.common.gaia.mines.metalLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], + [new SimpleObject(biomes.common.gaia.mines.metalSmall, 2, 3, 1, 3, 0, 2 * Math.PI, 1)] ]; for (let mine of minesMetal) createObjectGroups( Index: ps/trunk/binaries/data/mods/public/maps/random/hyrcanian_shores.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/hyrcanian_shores.js +++ ps/trunk/binaries/data/mods/public/maps/random/hyrcanian_shores.js @@ -219,7 +219,7 @@ Engine.SetProgress(80); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clWater, 0, clForest, 1, clPlayer, 20, clRock, 10, clHill, 2)], scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/island_stronghold.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/island_stronghold.js +++ ps/trunk/binaries/data/mods/public/maps/random/island_stronghold.js @@ -215,20 +215,18 @@ createBumps(avoidClasses(clPlayer, 20)); createMines( -[ - [new SimpleObject(oMetalLarge, 1, 1, 3, (numPlayers * 2) + 1)] -], -[avoidClasses(clForest, 1, clPlayer, 40, clRock, 20), stayClasses(clLand, 4)], -clMetal -); + [ + [new SimpleObject(oMetalLarge, 1, 1, 0, 4)] + ], + [avoidClasses(clForest, 1, clPlayer, 40, clRock, 20), stayClasses(clLand, 4)], + clMetal); createMines( -[ - [new SimpleObject(oStoneLarge, 1, 1, 3, (numPlayers * 2) + 1)], [new SimpleObject(oStoneSmall, 2, 2, 2, (numPlayers * 2) + 1)] -], -[avoidClasses(clForest, 1, clPlayer, 40, clMetal, 20), stayClasses(clLand, 4)], -clRock -); + [ + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)] + ], + [avoidClasses(clForest, 1, clPlayer, 40, clMetal, 20), stayClasses(clLand, 4)], + clRock); var [forestTrees, stragglerTrees] = getTreeCounts(...rBiomeTreeCount(1)); createForests( Index: ps/trunk/binaries/data/mods/public/maps/random/islands.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/islands.js +++ ps/trunk/binaries/data/mods/public/maps/random/islands.js @@ -223,7 +223,7 @@ Engine.SetProgress(55); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clForest, 1, clPlayer, 0, clRock, 10, clHill, 1), stayClasses(clLand, 5)], scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/kerala.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/kerala.js +++ ps/trunk/binaries/data/mods/public/maps/random/kerala.js @@ -198,7 +198,7 @@ scaleByMapSize(20, 80)); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/lake.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/lake.js +++ ps/trunk/binaries/data/mods/public/maps/random/lake.js @@ -163,7 +163,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/latium.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/latium.js +++ ps/trunk/binaries/data/mods/public/maps/random/latium.js @@ -378,7 +378,7 @@ Engine.SetProgress(50); g_Map.log("Creating large stone mines"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clWater, 1, clForest, 4, clPlayer, 40, clRock, 60, clMetal, 10, clCliff, 3), scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/lorraine_plain.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/lorraine_plain.js +++ ps/trunk/binaries/data/mods/public/maps/random/lorraine_plain.js @@ -193,7 +193,7 @@ Engine.SetProgress(80); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clWater, 0, clForest, 1, clPlayer, 15, clRock, 10, clHill, 1)], scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/mainland.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/mainland.js +++ ps/trunk/binaries/data/mods/public/maps/random/mainland.js @@ -117,12 +117,12 @@ g_Map.log("Creating stone mines"); createMines( - [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], - [new SimpleObject(oStoneSmall, 2,5, 1,3)] - ], - avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), - clRock); + [ + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)] + [new SimpleObject(oStoneSmall, 2, 5, 1, 3, 0, 2 * Math.PI, 1)] + ], + avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), + clRock); g_Map.log("Creating metal mines"); createMines( @@ -168,7 +168,7 @@ 3 * numPlayers, 3 * numPlayers ], - avoidClasses(clForest, 0, clPlayer, 20, clHill, 1, clFood, 20), + avoidClasses(clForest, 0, clPlayer, 20, clHill, 1, clMetal, 4, clRock, 4, clFood, 20), clFood); Engine.SetProgress(75); @@ -180,14 +180,14 @@ [ 3 * numPlayers ], - avoidClasses(clForest, 0, clPlayer, 20, clHill, 1, clFood, 10), + avoidClasses(clForest, 0, clPlayer, 20, clHill, 1, clMetal, 4, clRock, 4, clFood, 10), clFood); Engine.SetProgress(85); createStragglerTrees( [oTree1, oTree2, oTree4, oTree3], - avoidClasses(clForest, 8, clHill, 1, clPlayer, 12, clMetal, 6, clRock, 6), + avoidClasses(clForest, 8, clHill, 1, clPlayer, 12, clMetal, 6, clRock, 6, clFood, 1), clForest, stragglerTrees); Index: ps/trunk/binaries/data/mods/public/maps/random/migration.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/migration.js +++ ps/trunk/binaries/data/mods/public/maps/random/migration.js @@ -233,7 +233,7 @@ Engine.SetProgress(46); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clForest, 1, clPlayer, 10, clRock, 10, clHill, 1), stayClasses(clLand, 7)], scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/northern_lights.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/northern_lights.js +++ ps/trunk/binaries/data/mods/public/maps/random/northern_lights.js @@ -209,7 +209,7 @@ scaleByMapSize(20, 80)); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), scaleByMapSize(8,32), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/persian_highlands.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/persian_highlands.js +++ ps/trunk/binaries/data/mods/public/maps/random/persian_highlands.js @@ -182,35 +182,53 @@ Engine.SetProgress(50); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4), new RandomObject(aBushes, 2, 4, 0, 2)], true, clRock); -createObjectGroupsDeprecated(group, 0, +createObjectGroupsDeprecated( + new SimpleGroup( + [ + new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), + new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4), + new RandomObject(aBushes, 2, 4, 0, 2) + ], + true, + clRock), + 0, [avoidClasses(clForest, 1, clPlayer, 10, clRock, 10, clHill, 1, clCP, 1)], - scaleByMapSize(2,8), 100 -); + scaleByMapSize(2,8), + 100); g_Map.log("Creating small stone quarries"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 2,5, 1,3), new RandomObject(aBushes, 2,4, 0,2)], true, clRock); -createObjectGroupsDeprecated(group, 0, +createObjectGroupsDeprecated( + new SimpleGroup([new SimpleObject(oStoneSmall, 2, 5, 1, 3), new RandomObject(aBushes, 2, 4, 0, 2)], true, clRock), + 0, [avoidClasses(clForest, 1, clPlayer, 10, clRock, 10, clHill, 1, clCP, 1)], - scaleByMapSize(2,8), 100 -); + scaleByMapSize(2, 8), + 100); g_Map.log("Creating metal mines"); -group = new SimpleGroup([new SimpleObject(oMetalLarge, 1,1, 0,4), new RandomObject(aBushes, 2,4, 0,2)], true, clMetal); -createObjectGroupsDeprecated(group, 0, +createObjectGroupsDeprecated( + new SimpleGroup([new SimpleObject(oMetalLarge, 1, 1, 0, 4), new RandomObject(aBushes, 2, 4, 0, 2)], true, clMetal), + 0, [avoidClasses(clForest, 1, clPlayer, 10, clMetal, 10, clRock, 5, clHill, 1, clCP, 1)], - scaleByMapSize(2,8), 100 -); + scaleByMapSize(2,8), + 100); g_Map.log("Creating centeral stone mines"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4), new RandomObject(aBushes, 2,4, 0,2)], true, clRock); -createObjectGroupsDeprecated(group, 0, +createObjectGroupsDeprecated( + new SimpleGroup( + [ + new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), + new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4), + new RandomObject(aBushes, 2,4, 0,2) + ], + true, + clRock), + 0, stayClasses(clCP, 6), - 5*scaleByMapSize(5,30), 50 -); + 5*scaleByMapSize(5, 30), + 50); g_Map.log("Creating small stone quarries"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 2,5, 1,3), new RandomObject(aBushes, 2,4, 0,2)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 2, 5, 1, 3), new RandomObject(aBushes, 2, 4, 0, 2)], true, clRock); createObjectGroupsDeprecated(group, 0, stayClasses(clCP, 6), 5*scaleByMapSize(5,30), 50 Index: ps/trunk/binaries/data/mods/public/maps/random/phoenician_levant.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/phoenician_levant.js +++ ps/trunk/binaries/data/mods/public/maps/random/phoenician_levant.js @@ -193,7 +193,7 @@ g_Map.log("Creating cyprus mines"); var mines = [ - new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock), + new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock), new SimpleGroup([new SimpleObject(oMetalLarge, 1, 1, 0, 4)], true, clMetal), new SimpleGroup([new SimpleObject(oStoneSmall, 2, 5, 1, 3)], true, clRock) ]; @@ -208,7 +208,7 @@ scaleByMapSize(4, 16)); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clWater, 3, clHill, 1), scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/polar_sea.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/polar_sea.js +++ ps/trunk/binaries/data/mods/public/maps/random/polar_sea.js @@ -151,7 +151,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 3, clPlayer, 20, clRock, 18, clHill, 2), Index: ps/trunk/binaries/data/mods/public/maps/random/pyrenean_sierra.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/pyrenean_sierra.js +++ ps/trunk/binaries/data/mods/public/maps/random/pyrenean_sierra.js @@ -398,7 +398,7 @@ Engine.SetProgress(80); g_Map.log("Creating stone mines"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 8, clPyrenneans, 1), scaleByMapSize(4,16), 100 ); g_Map.log("Creating small stone quarries"); Index: ps/trunk/binaries/data/mods/public/maps/random/rhine_marshlands.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/rhine_marshlands.js +++ ps/trunk/binaries/data/mods/public/maps/random/rhine_marshlands.js @@ -145,7 +145,7 @@ scaleByMapSize(15, 45)); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clWater, 0, clForest, 1, clPlayer, 20, clRock, 10)], scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/rivers.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/rivers.js +++ ps/trunk/binaries/data/mods/public/maps/random/rivers.js @@ -189,7 +189,7 @@ g_Map.log("Creating stone mines"); createMines( [ - [new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2,5, 1,3)] ], avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/rmgen/group.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/rmgen/group.js +++ ps/trunk/binaries/data/mods/public/maps/random/rmgen/group.js @@ -34,22 +34,28 @@ this.centerPosition = deepfreeze(position.clone().round()); }; -SimpleGroup.prototype.place = function(player, constraint) +SimpleGroup.prototype.place = function(playerID, constraint) { let entitySpecsResult = []; + let avoidPositions = this.avoidSelf ? [] : undefined; // Test if the Objects can be placed at the given location // Place none of them if one can't be placed. for (let object of this.objects) { - let entitySpecs = object.place(this.centerPosition, player, this.avoidSelf, constraint); + let entitySpecs = object.place(this.centerPosition, playerID, avoidPositions, constraint, 20); if (!entitySpecs) return undefined; entitySpecsResult = entitySpecsResult.concat(entitySpecs); - } + if (this.avoidSelf) + avoidPositions = avoidPositions.concat(entitySpecs.map(entitySpec => ({ + "position": entitySpec.position, + "distance": object.avoidDistance + }))); + } // Create and place entities as specified let entities = []; @@ -79,7 +85,7 @@ this.simpleGroup.setCenterPosition(position); }; -RandomGroup.prototype.place = function(player, constraint) +RandomGroup.prototype.place = function(playerID, constraint) { - return this.simpleGroup.place(player, constraint); + return this.simpleGroup.place(playerID, constraint); }; Index: ps/trunk/binaries/data/mods/public/maps/random/rmgen/object.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/rmgen/object.js +++ ps/trunk/binaries/data/mods/public/maps/random/rmgen/object.js @@ -5,7 +5,7 @@ /** * The SimpleObject attempts to find locations for a random amount of entities with a random distance to the given center. */ -function SimpleObject(templateName, minCount, maxCount, minDistance, maxDistance, minAngle = 0, maxAngle = 2 * Math.PI) +function SimpleObject(templateName, minCount, maxCount, minDistance, maxDistance, minAngle = 0, maxAngle = 2 * Math.PI, avoidDistance = 1) { this.templateName = templateName; this.minCount = minCount; @@ -14,6 +14,7 @@ this.maxDistance = maxDistance; this.minAngle = minAngle; this.maxAngle = maxAngle; + this.avoidDistance = avoidDistance; if (minCount > maxCount) throw new Error("SimpleObject: minCount should be less than or equal to maxCount"); @@ -25,7 +26,7 @@ throw new Error("SimpleObject: minAngle should be less than or equal to maxAngle"); } -SimpleObject.prototype.place = function(centerPosition, playerID, avoidSelf, constraint, maxRetries = 20) +SimpleObject.prototype.place = function(centerPosition, playerID, avoidPositions, constraint, maxRetries) { let entitySpecs = []; let numRetries = 0; @@ -40,7 +41,9 @@ let position = Vector2D.sum([centerPosition, new Vector2D(0.5, 0.5), new Vector2D(distance, 0).rotate(-angle)]); if (validTile(position) && - (!avoidSelf || entitySpecs.every(entSpec => entSpec.position.distanceTo(position) >= 1)) && + (!avoidPositions || + entitySpecs.every(entSpec => entSpec.position.distanceTo(position) >= this.avoidDistance) && + avoidPositions.every(avoid => avoid.position.distanceTo(position) >= Math.max(this.avoidDistance, avoid.distance))) && constraint.allows(position.clone().floor())) { entitySpecs.push({ @@ -66,7 +69,7 @@ this.simpleObject = new SimpleObject(pickRandom(templateNames), minCount, maxCount, minDistance, maxDistance, minAngle, maxAngle); } -RandomObject.prototype.place = function(centerPosition, player, avoidSelf, constraint, maxRetries = 20) +RandomObject.prototype.place = function(centerPosition, player, avoidPositions, constraint, maxRetries) { - return this.simpleObject.place(centerPosition, player, avoidSelf, constraint, maxRetries); + return this.simpleObject.place(centerPosition, player, avoidPositions, constraint, maxRetries); }; Index: ps/trunk/binaries/data/mods/public/maps/random/saharan_oases.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/saharan_oases.js +++ ps/trunk/binaries/data/mods/public/maps/random/saharan_oases.js @@ -130,7 +130,7 @@ Engine.SetProgress(60); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clForest, 1, clPlayer, 26, clRock, 10, clWater, 1), 2*scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/sahel_watering_holes.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/sahel_watering_holes.js +++ ps/trunk/binaries/data/mods/public/maps/random/sahel_watering_holes.js @@ -212,7 +212,7 @@ Engine.SetProgress(55); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clWater, 3, clForest, 1, clPlayer, 20, clRock, 10, clHill, 1), scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/scythian_rivulet.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/scythian_rivulet.js +++ ps/trunk/binaries/data/mods/public/maps/random/scythian_rivulet.js @@ -205,7 +205,7 @@ // Allow mines on the bumps at the river createMines( [ - [new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], + [new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], [new SimpleObject(oStoneSmall, 2, 5, 1, 3)] ], avoidClasses(clForest, 4, clWater, 1, clPlayer, 20, clRock, 15, clHill, 1), Index: ps/trunk/binaries/data/mods/public/maps/random/snowflake_searocks.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/snowflake_searocks.js +++ ps/trunk/binaries/data/mods/public/maps/random/snowflake_searocks.js @@ -289,7 +289,7 @@ Engine.SetProgress(55); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clForest, 1, clPlayer, 10, clRock, 10), stayClasses(clLand, 5)], 5*scaleByMapSize(4,16), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/syria.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/syria.js +++ ps/trunk/binaries/data/mods/public/maps/random/syria.js @@ -168,14 +168,22 @@ Engine.SetProgress(70); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0,4), new RandomObject(aBushes, 2, 4, 0, 2)], true, clRock); -createObjectGroupsDeprecated(group, 0, +createObjectGroupsDeprecated( + new SimpleGroup( + [ + new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), + new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4), + new RandomObject(aBushes, 2, 4, 0, 2) + ], + true, + clRock), + 0, [avoidClasses(clForest, 1, clPlayer, 10, clRock, 10, clHill, 1, clGrass, 1)], - scaleByMapSize(2,8), 100 -); + scaleByMapSize(2, 8), + 100); g_Map.log("Creating small stone quarries"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 2,5, 1,3), new RandomObject(aBushes, 2,4, 0,2)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 2,5, 1,3), new RandomObject(aBushes, 2,4, 0,2)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clForest, 1, clPlayer, 10, clRock, 10, clHill, 1, clGrass, 1)], scaleByMapSize(2,8), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/the_nile.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/the_nile.js +++ ps/trunk/binaries/data/mods/public/maps/random/the_nile.js @@ -256,7 +256,7 @@ Engine.SetProgress(60); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clWater, 1, clPond, 1), scaleByMapSize(4,16), 100 @@ -277,7 +277,7 @@ ); g_Map.log("Creating stone mines"); -group = new SimpleGroup([new SimpleObject(oStoneSmall, 0,2, 0,4), new SimpleObject(oStoneLarge, 1,1, 0,4)], true, clRock); +group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, [avoidClasses(clForest, 1, clPlayer, 20, clRock, 10, clWater, 1, clPond, 1), stayClasses(clDesert, 3)], scaleByMapSize(6,20), 100 Index: ps/trunk/binaries/data/mods/public/maps/random/the_unknown/unknown_common.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/the_unknown/unknown_common.js +++ ps/trunk/binaries/data/mods/public/maps/random/the_unknown/unknown_common.js @@ -894,7 +894,7 @@ g_Map.log("Creating stone mines"); createObjectGroupsDeprecated( - new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock), + new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock), 0, [avoidClasses(clForest, 1, clPlayer, 10, clRock, 10, clHill, 2), stayClasses(clLand, 3)], randIntInclusive(scaleByMapSize(2, 9), scaleByMapSize(9, 40)), Index: ps/trunk/binaries/data/mods/public/maps/random/volcanic_lands.js =================================================================== --- ps/trunk/binaries/data/mods/public/maps/random/volcanic_lands.js +++ ps/trunk/binaries/data/mods/public/maps/random/volcanic_lands.js @@ -128,7 +128,7 @@ ); g_Map.log("Creating stone mines"); -var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4), new SimpleObject(oStoneLarge, 1, 1, 0, 4)], true, clRock); +var group = new SimpleGroup([new SimpleObject(oStoneSmall, 0, 2, 0, 4, 0, 2 * Math.PI, 1), new SimpleObject(oStoneLarge, 1, 1, 0, 4, 0, 2 * Math.PI, 4)], true, clRock); createObjectGroupsDeprecated(group, 0, avoidClasses(clForest, 1, clPlayer, 10, clRock, 10, clHill, 1), scaleByMapSize(4,16), 100