Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/maps/random/wild_lake.js
Show First 20 Lines • Show All 265 Lines • ▼ Show 20 Lines | var farmEntities = { | ||||
"desert": { "building": "structures/pers_farmstead", "animal": "gaia/fauna_camel" }, | "desert": { "building": "structures/pers_farmstead", "animal": "gaia/fauna_camel" }, | ||||
"alpine": { "building": "structures/rome_farmstead", "animal": "gaia/fauna_sheep" }, | "alpine": { "building": "structures/rome_farmstead", "animal": "gaia/fauna_sheep" }, | ||||
"mediterranean": { "building": "structures/iber_farmstead", "animal": "gaia/fauna_pig" }, | "mediterranean": { "building": "structures/iber_farmstead", "animal": "gaia/fauna_pig" }, | ||||
"savanna": { "building": "structures/sele_farmstead", "animal": "gaia/fauna_horse" }, | "savanna": { "building": "structures/sele_farmstead", "animal": "gaia/fauna_horse" }, | ||||
"tropic": { "building": "structures/ptol_farmstead", "animal": "gaia/fauna_camel" }, | "tropic": { "building": "structures/ptol_farmstead", "animal": "gaia/fauna_camel" }, | ||||
"autumn": { "building": "structures/gaul_farmstead", "animal": "gaia/fauna_horse" } | "autumn": { "building": "structures/gaul_farmstead", "animal": "gaia/fauna_horse" } | ||||
}; | }; | ||||
wallStyles.other.sheepIn = new WallElement("sheepIn", farmEntities[currentBiome()].animal, PI / 4, -1.5, 0.75, PI/2); | g_WallStyles.other = { | ||||
wallStyles.other.foodBin = new WallElement("foodBin", "gaia/special_treasure_food_bin", PI/2, 1.5); | "overlap": 0, | ||||
wallStyles.other.sheep = new WallElement("sheep", farmEntities[currentBiome()].animal, 0, 0, 0.75); | "fence": readyWallElement("other/fence_long", "gaia"), | ||||
wallStyles.other.farm = new WallElement("farm", farmEntities[currentBiome()].building, PI, 0, -3); | "fence_short": readyWallElement("other/fence_short", "gaia"), | ||||
"bench": { "angle": Math.PI / 2, "length": 1.5, "indent": 0, "bend": 0, "templateName": "other/bench" }, | |||||
"foodBin": { "angle": Math.PI / 2, "length": 1.5, "indent": 0, "bend": 0, "templateName": "gaia/special_treasure_food_bin" }, | |||||
"animal": { "angle": 0, "length": 0, "indent": 0.75, "bend": 0, "templateName": farmEntities[currentBiome()].animal }, | |||||
"farmstead": { "angle": Math.PI, "length": 0, "indent": -3, "bend": 0, "templateName": farmEntities[currentBiome()].building } | |||||
}; | |||||
elexis: Oh yeah and then we also don't have to add code to keep things in sync | |||||
let fences = [ | let fences = [ | ||||
new Fortress("fence", ["foodBin", "farm", "bench", "sheepIn", "fence", "sheepIn", "fence", "sheepIn", "fence"]), | |||||
new Fortress("fence", ["foodBin", "farm", "fence", "sheepIn", "fence", "sheepIn", "bench", "sheep", "fence", "sheepIn", "fence"]), | |||||
new Fortress("fence", [ | new Fortress("fence", [ | ||||
"foodBin", "farm", "cornerIn", "bench", "cornerOut", "fence_short", "sheepIn", "fence", "sheepIn", | "foodBin", "farmstead", "bench", | ||||
"fence", "sheepIn", "fence_short", "sheep", "fence" | "turn_0.25", "animal", "turn_0.25", "fence", | ||||
"turn_0.25", "animal", "turn_0.25", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "fence" | |||||
]), | |||||
new Fortress("fence", [ | |||||
"foodBin", "farmstead", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "bench", "animal", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "fence" | |||||
]), | |||||
new Fortress("fence", [ | |||||
"foodBin", "farmstead", "turn_0.5", "bench", "turn_-0.5", "fence_short", | |||||
"turn_0.25", "animal", "turn_0.25", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "fence_short", "animal", "fence" | |||||
]), | ]), | ||||
new Fortress("fence", [ | new Fortress("fence", [ | ||||
"foodBin", "farm", "cornerIn", "fence_short", "cornerOut", "bench", "sheepIn", "fence", "sheepIn", | "foodBin", "farmstead", "turn_0.5", "fence_short", "turn_-0.5", "bench", | ||||
"fence", "sheepIn", "fence_short", "sheep", "fence" | "turn_0.25", "animal", "turn_0.25", "fence", | ||||
"turn_0.25", "animal", "turn_0.25", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "fence_short", "animal", "fence" | |||||
]), | ]), | ||||
new Fortress("fence", [ | new Fortress("fence", [ | ||||
"foodBin", "farm", "fence", "sheepIn", "bench", "sheep", "fence", "sheepIn", | "foodBin", "farmstead", "fence", | ||||
"fence_short", "sheep", "fence", "sheepIn", "fence_short", "sheep", "fence" | "turn_0.25", "animal", "turn_0.25", "bench", "animal", "fence", | ||||
"turn_0.25", "animal", "turn_0.25", "fence_short", "animal", "fence", | |||||
"turn_0.25", "animal", "turn_0.25", "fence_short", "animal", "fence" | |||||
]) | ]) | ||||
]; | ]; | ||||
let num = fences.length; | let num = fences.length; | ||||
for (let i = 0; i < num; ++i) | for (let i = 0; i < num; ++i) | ||||
fences.push(new Fortress("fence", clone(fences[i].wall).reverse())); | fences.push(new Fortress("fence", clone(fences[i].wall).reverse())); | ||||
// Camps with fire and gold treasure | // Camps with fire and gold treasure | ||||
function placeCamp(point, | function placeCamp(point, | ||||
▲ Show 20 Lines • Show All 330 Lines • Show Last 20 Lines |
Wildfire Games · Phabricator
Oh yeah and then we also don't have to add code to keep things in sync