Skip to content

Commit

Permalink
Merge branch 'release/0.4.0' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
caewok committed Aug 11, 2024
2 parents e6a95f2 + a1f2ade commit 4018a9b
Show file tree
Hide file tree
Showing 27 changed files with 3,643 additions and 598 deletions.
14 changes: 14 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
## 0.4.0
Add a Terrain Mapper tab to the region configuration with options to make a 3d region shape:
1. Plateau: Region treated like a physical plateau with a flat top at a given elevation. Note that the region affected area can continue above the plateau.
2. Ramp/Steps: Like Plateau but the top goes from a low to a high elevation, either continuously or at a given step size.

Modify the SetElevation behavior to act like stairs, moving a token up or up/down.
Automatically adjust token elevations as they move across region plateaus/ramps/steps, accounting for flying or burrowing tokens.

Add config options to overhead tiles to treat them as a "floor" at the set tile elevation. Include options to ignore the transparent rectangular boundary and to treat transparent tiles (alpha <= 0.75 ) to be holes. Add `CONFIG.terrainmapper.holePercentThreshold` to modify how large the hole has to be for a token to "fall through."

Set scene config elevation step to "0.1" so that it accepts decimal values. Closes #33.
Added basic Brazilian Portuguese translation. Thanks @Kharmans!
Modifications to better support move and move penalty calculations in Elevation Ruler when crossing regions or tiles.

## 0.3.3
Add json folder to workflow so default terrains will be present in dnd5e.

Expand Down
52 changes: 48 additions & 4 deletions languages/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,33 @@
"terrainmapper.active-effect-config.displayStatusIcon.name": "Status Icon",
"terrainmapper.active-effect-config.displayStatusIcon.hint": "When disabled, the terrain status icon will not display on affected tokens.",

"terrainmapper.region-config.algorithm.name": "Region Elevation Shape",
"terrainmapper.region-config.algorithm.hint": "Apply a physical shape to the region's elevation. 'None' keeps the Foundry default. 'Plateau' treats the region like a plateau or mesa. Tokens entering the region will move to the plateau elevation and will be considered 'burrowing' if under that elevation. 'Ramp' is similar to 'Plateau' but applies a slope starting at the floor elevation and moving up to the plateau elevation in the given direction. Tokens that leave the region will 'fall' back to the ground unless flying.",

"terrainmapper.region-config.plateauElevation.name": "Plateau Elevation",
"terrainmapper.region-config.plateauElevation.hint": "When moving into the region, the token will be set to this elevation. For ramps, this is the topmost elevation of the ramp. For a typical scene, try setting the region top to this elevation and the region bottom to negative infinity.",

"terrainmapper.region-config.rampFloor.name": "Lowest Ramp Elevation",
"terrainmapper.region-config.rampFloor.hint": "For ramps only. Ramp elevation starts here and goes up to the Plateau Elevation. To create a wedge shape, set this value to the scene elevation.",

"terrainmapper.region-config.rampDirection.name": "Ramp Direction",
"terrainmapper.region-config.rampDirection.hint": "0º is due south; 90º is due west. For ramps only.",

"terrainmapper.region-config.rampStepSize.name": "Step Size",
"terrainmapper.region-config.rampStepSize.hint": "How tall, in grid units, to make each step of the ramp. The number of steps will be automatically determined based on this value. If set to 0, the ramp will approximate a smooth incline. For ramps only.",

"terrainmapper.tile-config.isFloor.name": "Treat as Floor",
"terrainmapper.tile-config.isFloor.hint": "When enabled, will be treated as a solid floor (ground) when moving tokens.",

"terrainmapper.tile-config.trimAlphaBorder.name": "Trim Boundary",
"terrainmapper.tile-config.trimAlphaBorder.hint": "When enabled, the transparent border of the tile will be ignored for purposes of token movement. Only a rectangle, possibly rotated, will be used as the border. For more complex shapes, enable Test for Holes.",

"terrainmapper.tile-config.testHoles.name": "Test for Holes",
"terrainmapper.tile-config.testHoles.hint": "Transparent pixels will be considered holes on this tile. Sufficiently large holes will cause the token to 'fall' through the tile. `CONFIG.terrainmapper.holePercentThreshold` controls how large a hole must be for a given token. Default setting: a hole that exceeds 50% of the token size as measured from a given pixel will not support the token. Testing for holes is somewhat performance-intensive.",

"terrainmapper.tile-config.alphaThreshold.name": "Alpha (Transparency) Threshold",
"terrainmapper.tile-config.alphaThreshold.hint": "What percentage transparency counts for treating a given pixel as a hole or outer boundary. Default in Foundry is 0.75.",

"terrainmapper.behavior.types.add-terrain.fields.terrain.hint": "Select terrain that will be added to the token as an active effect.",

"terrainmapper.behavior.types.set-terrain.fields.terrain.hint": "Select terrain that will be added to the token as an active effect. When the token exits the region, the terrain will be automatically removed.",
Expand All @@ -31,11 +58,28 @@
"terrainmapper.behavior.types.remove-terrain.fields.keepSelected.name": "Keep selected",
"terrainmapper.behavior.types.remove-terrain.fields.keepSelected.hint": "Enable to keep the selected terrains and remove all the rest from the token.",

"terrainmapper.behavior.types.set-elevation.fields.elevation.name": "Elevation",
"terrainmapper.behavior.types.set-elevation.fields.elevation.hint": "When moving into the region, the token will be set to this elevation. For a typical scene, you should set the region top to this elevation and the region bottom to negative infinity.",
"terrainmapper.behavior.types.set-elevation.fields.elevation.name": "Elevation/Stairs Top",
"terrainmapper.behavior.types.set-elevation.fields.elevation.hint": "When moving into the region, the token will be set to this elevation. For stairs, tokens at elevation below the midpoint of this and the stairs bottom will be set to this elevation upon entry.",

"terrainmapper.behavior.types.set-elevation.fields.algorithm.name": "Elevation Method",

"terrainmapper.elevationAlgorithm.labels.none": "None",
"terrainmapper.elevationAlgorithm.labels.oneWay": "Single Elevation",
"terrainmapper.elevationAlgorithm.labels.plateau": "Plateau / Mesa",
"terrainmapper.elevationAlgorithm.labels.ramp": "Ramp / Steps",
"terrainmapper.elevationAlgorithm.labels.stairs": "Stairs",

"terrainmapper.behavior.types.set-elevation.fields.floor.name": "Stairs Bottom",
"terrainmapper.behavior.types.set-elevation.fields.floor.hint": "For stairs, tokens at elevation above the midpoint of this and the stairs top will be set to this elevation upon entry.",

"terrainmapper.behavior.types.set-elevation.fields.rampDirection.name": "Ramp Direction",
"terrainmapper.behavior.types.set-elevation.fields.rampDirection.hint": "0 is due south; 90 is due west. Does nothing unless method chosen is 'Ramp'.",

"terrainmapper.behavior.types.set-elevation.fields.rampStepHeight.name": "Ramp Step Size",
"terrainmapper.behavior.types.set-elevation.fields.rampStepHeight.hint": "How tall, in grid units, to make each step of the ramp. The number of steps will be automatically determined based on this value. If set to 0, the ramp will approximate a smooth incline. Does nothing unless method chosen is 'Ramp'.",

"terrainmapper.behavior.types.set-elevation.fields.reset.name": "Reset on exit",
"terrainmapper.behavior.types.set-elevation.fields.reset.hint": "When enabled, the token's elevation will be reset to the scene's background elevation when the token exits the region.",
"terrainmapper.behavior.types.set-elevation.fields.ignoreOtherElevations.name": "Ignore Other Elevations",
"terrainmapper.behavior.types.set-elevation.fields.ignoreOtherElevations.hint": "If enabled, tokens entering the region will be ignored unless at the designated minimum elevation (or maximum, for stairs).",

"TYPES.RegionBehavior.terrainmapper.addTerrain": "Add Terrains",
"TYPES.RegionBehavior.terrainmapper.removeTerrain": "Remove Terrains",
Expand Down
54 changes: 54 additions & 0 deletions languages/pt-BR.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{
"terrainmapper.name": "Terrain Mapper",
"terrainmapper.controls.fill-by-grid.name": "Preencher por Grade",
"terrainmapper.controls.fill-by-los.name": "Preencher por Linha de Visão",
"terrainmapper.controls.fill-space.name": "Preencher Espaços Cercados por Paredes",

"terrainmapper.terrainbook.create-terrain": "Criar Terreno",
"terrainmapper.terrainbook.create-defaults": "Redefinir Terrenos Padrão",

"terrainmapper.scene-config.backgroundElevation.name": "Elevação de Fundo",
"terrainmapper.scene-config.backgroundElevation.hint": "A elevação padrão para tokens colocados na tela.",

"terrainmapper.active-effect-config.duplicatesAllowed.name": "Permitir Duplicatas",
"terrainmapper.active-effect-config.duplicatesAllowed.hint": "Quando ativado, este efeito de terreno pode ser aplicado diversas vezes a um único token.",

"terrainmapper.active-effect-config.displayStatusIcon.name": "Ícone de Status",
"terrainmapper.active-effect-config.displayStatusIcon.hint": "Quando desativado, o ícone de status do terreno não será exibido nos tokens afetados.",

"terrainmapper.behavior.types.add-terrain.fields.terrain.hint": "Selecione o terreno que será adicionado ao token como efeito ativo.",

"terrainmapper.behavior.types.set-terrain.fields.terrain.hint": "Selecione o terreno que será adicionado ao token como efeito ativo. Quando o token sair da região, o terreno será removido automaticamente.",

"terrainmapper.behavior.types.add-terrain.fields.removeOther.name": "Remover Outros",
"terrainmapper.behavior.types.add-terrain.fields.removeOther.hint": "Quando ativado, todos os outros terrenos do token serão removidos.",

"terrainmapper.behavior.types.add-terrain.fields.secret.name": "Secreto",
"terrainmapper.behavior.types.add-terrain.fields.secret.hint": "Quando ativado, arrastar o token não revelará a existência do terreno aos usuários.",

"terrainmapper.behavior.types.remove-terrain.fields.terrain.hint": "Selecione um ou mais terrenos que serão removidos do token. Deixe em branco para remover todos os terrenos.",

"terrainmapper.behavior.types.remove-terrain.fields.keepSelected.name": "Manter Selecionados",
"terrainmapper.behavior.types.remove-terrain.fields.keepSelected.hint": "Habilite para manter os terrenos selecionados e remover todo o resto do token.",

"terrainmapper.behavior.types.set-elevation.fields.elevation.name": "Elevação",
"terrainmapper.behavior.types.set-elevation.fields.elevation.hint": "Ao entrar na região, o token será definido para esta elevação. Para uma cena típica, você deve definir a região superior para esta elevação e a região inferior para infinito negativo.",

"terrainmapper.behavior.types.set-elevation.fields.reset.name": "Redefinir ao Sair",
"terrainmapper.behavior.types.set-elevation.fields.reset.hint": "Quando ativado, a elevação do token será redefinida para a elevação de fundo da cena quando o token sair da região.",

"TYPES.RegionBehavior.terrainmapper.addTerrain": "Adicionar Terrenos",
"TYPES.RegionBehavior.terrainmapper.removeTerrain": "Remover Terrenos",
"TYPES.RegionBehavior.terrainmapper.setTerrain": "Definir Terreno",
"TYPES.RegionBehavior.terrainmapper.setElevation": "Definir Elevação",

"terrainmapper.phrases.terrainLayer": "Camada de Terreno",
"terrainmapper.phrases.terrain": "Terreno",
"terrainmapper.phrases.terrains": "Terrenos",
"terrainmapper.phrases.no-terrain": "Sem Terreno",
"terrainmapper.phrases.new-terrain": "Novo Terreno",
"terrainmapper.phrases.layer-number": "Camada {layerNumber}",
"terrainmapper.phrases.difficult_x2": "Dificuldade (x2)",
"terrainmapper.phrases.water_swimming": "Água (Natação)",
"terrainmapper.phrases.cliff_climbing": "Penhasco (Escalada)"
}
2 changes: 1 addition & 1 deletion module.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"manifestPlusVersion": "1.2.0",
"compatibility": {
"minimum": "12",
"verified": "12.327"
"verified": "12.330"
},
"authors": [
{
Expand Down
Loading

0 comments on commit 4018a9b

Please sign in to comment.