From f2d5fcdab2431db62557aacf1a62fb48fbd90845 Mon Sep 17 00:00:00 2001 From: Jose Lozano Date: Tue, 30 Jan 2024 12:27:49 +0100 Subject: [PATCH 1/4] Achtung --- lang/es.json | 68 +++++++++++++++++++++++++++++++++++++++++++ module.json | 12 +++++++- scripts/damage-log.js | 19 ++++++++++++ 3 files changed, 98 insertions(+), 1 deletion(-) create mode 100644 lang/es.json diff --git a/lang/es.json b/lang/es.json new file mode 100644 index 0000000..ef513aa --- /dev/null +++ b/lang/es.json @@ -0,0 +1,68 @@ +{ + "damage-log.chat-tab-name": "Chat", + "damage-log.damage-log-tab-name": "Daño", + + "damage-log.reset-visibility": "Reiniciar visibilidad", + "damage-log.undo-damage": "Deshacer daño", + "damage-log.undo-healing": "Deshacer curación", + "damage-log.redo-damage": "Reaplicar daño", + "damage-log.redo-healing": "Reaplicar curación", + + "damage-log.damage-flavor-text": "Took {diff} {damageType} damage", + "damage-log.healing-flavor-text": "Healed {diff} damage", + + "damage-log.old": "Old", + "damage-log.new": "New", + "damage-log.diff": "Diff", + + "damage-log.default.hp-name" : "HP", + "damage-log.default.temp-name" : "Temp", + "damage-log.age-of-sigmar-soulbound.toughness-name" : "Toughness", + "damage-log.D35E.vigor-name": "Vigor", + "damage-log.D35E.vigorTemp-name": "Temp", + "damage-log.D35E.wounds-name": "Wounds", + "damage-log.demonlord.corruption-name": "Corruption", + "damage-log.demonlord.damage-name": "Damage", + "damage-log.demonlord.insanity-name": "Insanity", + "damage-log.gurps.fp-name": "FP", + "damage-log.pf2e.sp-name": "Stamina", + "damage-log.swade.wounds-name" : "Wounds", + "damage-log.swade.fatigue-name" : "Fatigue", + "damage-log.swade.bennies-name" : "Bennies", + "damage-log.tormenta20.pv-name" : "PV", + + "damage-log.settings.use-tab": "Use separate damage log tab", + "damage-log.settings.use-tab-hint": "Use a separate tab for damage logs. If this is unchecked, damage logs will be sent to the default chatlog.", + + "damage-log.settings.allow-player-view": "Allow players to view the damage log", + + "damage-log.settings.min-player-permission": "Minimum actor permission", + "damage-log.settings.min-player-permission-hint": "Players will only be able to see actors in the damage log for which they have this permission (or better).", + + "damage-log.settings.allow-player-undo": "Allow players to undo/redo damage", + "damage-log.settings.allow-player-undo-hint": "When enabled, players will be able to undo/redo damage and healing dealt to their *owned* actors.", + + "damage-log.settings.show-limited-info": "Show limited damage info to players", + "damage-log.settings.show-limited-info-hint": "When enabled, players can see the damage taken by *all* actors, but not the old/diff/new table of values.", + + "damage-log.settings.hide-healing-in-limited-info": "Hide healing in the limited damage info", + "damage-log.settings.hide-healing-in-limited-info-hint": "When enabled, players will not be able to see any healing in the limited damage info.", + + "damage-log.settings.clamp-to-max": "Clamp to max HP", + "damage-log.settings.clamp-to-max-hint": "When reverting damage or re-applying healing, prevent the character's HP going over its current allowed maxiumum value", + + "damage-log.settings.clamp-to-min": "Clamp to min HP", + "damage-log.settings.clamp-to-min-hint": "When re-applying damage or reverting healing, prevent the character's HP going under its current allowed minimum value", + + "damage-log.settings.none": "None", + "damage-log.settings.limited": "Limited", + "damage-log.settings.observer": "Observer", + "damage-log.settings.owner": "Owner", + + "damage-log.error.system-not-supported": "Damage Log | The '{systemId}' system is not currently supported", + "damage-log.error.scene-id-missing": "Damage Log | Scene ID missing from damage log", + "damage-log.error.scene-deleted": "Damage Log | Scene '{scene}' no longer exists", + "damage-log.error.token-id-missing": "Damage Log | Token ID missing from damage log", + "damage-log.error.token-deleted": "Damage Log | Token '{token}' no longer exists", + "damage-log.error.no-undo-user": "Damage Log | Cannot {undo} {damage}. Neither {user}, nor any GM is connected" +} diff --git a/module.json b/module.json index 72171a1..d771222 100644 --- a/module.json +++ b/module.json @@ -38,7 +38,8 @@ "pf2e", "worldbuilding", "archmage", - "shaper" + "shaper", + "ac2d20" ], "relationships": { "requires": [ @@ -99,6 +100,10 @@ { "id": "worldbuilding", "type": "system" + }, + { + "id": "ac2d20", + "type": "system" } ] }, @@ -132,6 +137,11 @@ "lang": "cn", "name": "中文(简体)", "path": "lang/cn.json" + }, + { + "lang": "es", + "name": "Español", + "path": "lang/es.json" } ], "url": "#{URL}#", diff --git a/scripts/damage-log.js b/scripts/damage-log.js index 2293a3b..6d7fff5 100644 --- a/scripts/damage-log.js +++ b/scripts/damage-log.js @@ -144,6 +144,25 @@ class DamageLog { min: "health.min", max: "health.max" } + }, + ac2d20: { + stress: { + invert: true, + value: "stress.value", + max: "stress.max" + }, + injuries: { + invert: true, + value: "injuries.value" + }, + fortune: { + invert: false, + value: "fortune.value" + }, + fatigue: { + invert: true, + value: "fatigue" + } } }; From 0b1f6bebf547799f7b0c5a609d88fbad0666a1dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20E=2E=20Lozano?= Date: Tue, 30 Jan 2024 13:05:09 +0100 Subject: [PATCH 2/4] fix --- scripts/damage-log.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/damage-log.js b/scripts/damage-log.js index 6d7fff5..085b182 100644 --- a/scripts/damage-log.js +++ b/scripts/damage-log.js @@ -146,20 +146,20 @@ class DamageLog { } }, ac2d20: { - stress: { + "Stress": { invert: true, value: "stress.value", max: "stress.max" }, - injuries: { + "Injuries": { invert: true, value: "injuries.value" }, - fortune: { + "Fortune": { invert: false, value: "fortune.value" }, - fatigue: { + "Fatigue": { invert: true, value: "fatigue" } From b42eb1e5827a83b877889431aa432dee74e4fdd9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20E=2E=20Lozano?= Date: Tue, 30 Jan 2024 19:26:36 +0100 Subject: [PATCH 3/4] Fix --- lang/en.json | 4 +++ lang/es.json | 84 ++++++++++++++++++++++--------------------- scripts/damage-log.js | 8 ++--- 3 files changed, 52 insertions(+), 44 deletions(-) diff --git a/lang/en.json b/lang/en.json index d1b4a71..f926251 100644 --- a/lang/en.json +++ b/lang/en.json @@ -30,6 +30,10 @@ "damage-log.swade.fatigue-name" : "Fatigue", "damage-log.swade.bennies-name" : "Bennies", "damage-log.tormenta20.pv-name" : "PV", + "damage-log.ac2d20.stress-name" : "Stress", + "damage-log.ac2d20.injuries-name" : "Injuries", + "damage-log.ac2d20.fortune-name" : "Fortune", + "damage-log.ac2d20.fatigue-name" : "Fatigue", "damage-log.settings.use-tab": "Use separate damage log tab", "damage-log.settings.use-tab-hint": "Use a separate tab for damage logs. If this is unchecked, damage logs will be sent to the default chatlog.", diff --git a/lang/es.json b/lang/es.json index ef513aa..bac0c89 100644 --- a/lang/es.json +++ b/lang/es.json @@ -8,61 +8,65 @@ "damage-log.redo-damage": "Reaplicar daño", "damage-log.redo-healing": "Reaplicar curación", - "damage-log.damage-flavor-text": "Took {diff} {damageType} damage", - "damage-log.healing-flavor-text": "Healed {diff} damage", + "damage-log.damage-flavor-text": "Pierde {diff} {damageType} punto(s)", + "damage-log.healing-flavor-text": "Gana {diff} punto(s)", - "damage-log.old": "Old", - "damage-log.new": "New", - "damage-log.diff": "Diff", + "damage-log.old": "Antes", + "damage-log.new": "Ahora", + "damage-log.diff": "Dif.", - "damage-log.default.hp-name" : "HP", + "damage-log.default.hp-name" : "PV", "damage-log.default.temp-name" : "Temp", - "damage-log.age-of-sigmar-soulbound.toughness-name" : "Toughness", + "damage-log.age-of-sigmar-soulbound.toughness-name" : "Dureza", "damage-log.D35E.vigor-name": "Vigor", "damage-log.D35E.vigorTemp-name": "Temp", - "damage-log.D35E.wounds-name": "Wounds", - "damage-log.demonlord.corruption-name": "Corruption", - "damage-log.demonlord.damage-name": "Damage", - "damage-log.demonlord.insanity-name": "Insanity", + "damage-log.D35E.wounds-name": "Heridas", + "damage-log.demonlord.corruption-name": "Corrupción", + "damage-log.demonlord.damage-name": "Daño", + "damage-log.demonlord.insanity-name": "Locura", "damage-log.gurps.fp-name": "FP", - "damage-log.pf2e.sp-name": "Stamina", - "damage-log.swade.wounds-name" : "Wounds", - "damage-log.swade.fatigue-name" : "Fatigue", - "damage-log.swade.bennies-name" : "Bennies", + "damage-log.pf2e.sp-name": "Resistencia", + "damage-log.swade.wounds-name" : "Heridas", + "damage-log.swade.fatigue-name" : "Fatiga", + "damage-log.swade.bennies-name" : "Benis", "damage-log.tormenta20.pv-name" : "PV", + "damage-log.ac2d20.stress-name" : "Estrés", + "damage-log.ac2d20.injuries-name" : "Heridas", + "damage-log.ac2d20.fortune-name" : "Fortuna", + "damage-log.ac2d20.fatigue-name" : "Fatiga", - "damage-log.settings.use-tab": "Use separate damage log tab", - "damage-log.settings.use-tab-hint": "Use a separate tab for damage logs. If this is unchecked, damage logs will be sent to the default chatlog.", + "damage-log.settings.use-tab": "Usar pestaña separada", + "damage-log.settings.use-tab-hint": "Usar una pestaña separada para el registro de daños. Si no se habilita, el registro se volcará al char habitual.", - "damage-log.settings.allow-player-view": "Allow players to view the damage log", + "damage-log.settings.allow-player-view": "Permitir a los jugadores ver el registro de daños", - "damage-log.settings.min-player-permission": "Minimum actor permission", - "damage-log.settings.min-player-permission-hint": "Players will only be able to see actors in the damage log for which they have this permission (or better).", + "damage-log.settings.min-player-permission": "Permiso de actor mínimo", + "damage-log.settings.min-player-permission-hint": "Los jugadores solo podrán ver información de los actores para los que tienen este permiso o superior.", - "damage-log.settings.allow-player-undo": "Allow players to undo/redo damage", - "damage-log.settings.allow-player-undo-hint": "When enabled, players will be able to undo/redo damage and healing dealt to their *owned* actors.", + "damage-log.settings.allow-player-undo": "Permitir deshacer/reaplicar daño", + "damage-log.settings.allow-player-undo-hint": "Si se habilita, los jugadores podrán deshacer/reaplicar el daño que ha sufrido un actor del que se tiene permiso de *propietario*.", - "damage-log.settings.show-limited-info": "Show limited damage info to players", - "damage-log.settings.show-limited-info-hint": "When enabled, players can see the damage taken by *all* actors, but not the old/diff/new table of values.", + "damage-log.settings.show-limited-info": "Mostrar información limitada de daño a los jugadores", + "damage-log.settings.show-limited-info-hint": "Si se habilita, los jugadores pueden ver el daño de *todos* los actores, pero no la tabla ahora/dif./antes.", - "damage-log.settings.hide-healing-in-limited-info": "Hide healing in the limited damage info", - "damage-log.settings.hide-healing-in-limited-info-hint": "When enabled, players will not be able to see any healing in the limited damage info.", + "damage-log.settings.hide-healing-in-limited-info": "Ocultar la curación en la información limitada de daño", + "damage-log.settings.hide-healing-in-limited-info-hint": "Si se habilita, los jugadores no verán ningún mensaje de curación en la información limitada de daño.", - "damage-log.settings.clamp-to-max": "Clamp to max HP", - "damage-log.settings.clamp-to-max-hint": "When reverting damage or re-applying healing, prevent the character's HP going over its current allowed maxiumum value", + "damage-log.settings.clamp-to-max": "Restringir a máx PV", + "damage-log.settings.clamp-to-max-hint": "Cuando se deshaga o se reaplique daño/curación, evite que los PV del personaje sean mayores que el máximo.", - "damage-log.settings.clamp-to-min": "Clamp to min HP", - "damage-log.settings.clamp-to-min-hint": "When re-applying damage or reverting healing, prevent the character's HP going under its current allowed minimum value", + "damage-log.settings.clamp-to-min": "Restringir a mín PV", + "damage-log.settings.clamp-to-min-hint": "Cuando se deshaga o se reaplique daño/curación, evite que los PV del personaje sean menores que el mínimo.", - "damage-log.settings.none": "None", - "damage-log.settings.limited": "Limited", - "damage-log.settings.observer": "Observer", - "damage-log.settings.owner": "Owner", + "damage-log.settings.none": "Ninguno", + "damage-log.settings.limited": "Limitado", + "damage-log.settings.observer": "Espectador", + "damage-log.settings.owner": "Propietario", - "damage-log.error.system-not-supported": "Damage Log | The '{systemId}' system is not currently supported", - "damage-log.error.scene-id-missing": "Damage Log | Scene ID missing from damage log", - "damage-log.error.scene-deleted": "Damage Log | Scene '{scene}' no longer exists", - "damage-log.error.token-id-missing": "Damage Log | Token ID missing from damage log", - "damage-log.error.token-deleted": "Damage Log | Token '{token}' no longer exists", - "damage-log.error.no-undo-user": "Damage Log | Cannot {undo} {damage}. Neither {user}, nor any GM is connected" + "damage-log.error.system-not-supported": "Damage Log | El sistema '{systemId}' no está soportado", + "damage-log.error.scene-id-missing": "Damage Log | No se encuentra Scene ID de damage log", + "damage-log.error.scene-deleted": "Damage Log | La escena '{scene}' no existe", + "damage-log.error.token-id-missing": "Damage Log | No se encuentra el Token ID de damage log", + "damage-log.error.token-deleted": "Damage Log | El token '{token}' no existe", + "damage-log.error.no-undo-user": "Damage Log | No se puede {undo} {damage}. O {user} o el GM no están conectados" } diff --git a/scripts/damage-log.js b/scripts/damage-log.js index 085b182..6d7fff5 100644 --- a/scripts/damage-log.js +++ b/scripts/damage-log.js @@ -146,20 +146,20 @@ class DamageLog { } }, ac2d20: { - "Stress": { + stress: { invert: true, value: "stress.value", max: "stress.max" }, - "Injuries": { + injuries: { invert: true, value: "injuries.value" }, - "Fortune": { + fortune: { invert: false, value: "fortune.value" }, - "Fatigue": { + fatigue: { invert: true, value: "fatigue" } From 3922d88427048bcf4e1794a1891c895a724f4820 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20E=2E=20Lozano?= Date: Wed, 31 Jan 2024 19:16:00 +0100 Subject: [PATCH 4/4] Alphabetical order --- README.md | 1 + module.json | 21 ++++++++++++--------- scripts/damage-log.js | 38 +++++++++++++++++++------------------- 3 files changed, 32 insertions(+), 28 deletions(-) diff --git a/README.md b/README.md index 7898983..764745b 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,7 @@ Damage Log is also compatible with the [Tabbed Chatlog](https://github.com/cswen ## System Compatibility Damage Log is currently compatible with the following systems. +* Achtung! Cthulhu 2d20 (`ac2d20`) * Age of Sigmar: Soulbound (`age-of-sigmar-soulbound`) * Dungeons & Dragons v3.5 (`D35E`) * Dungeons & Dragons 5th Edition (`dnd5e`) diff --git a/module.json b/module.json index d771222..9804fc7 100644 --- a/module.json +++ b/module.json @@ -29,17 +29,20 @@ } ], "system": [ + "ac2d20", "age-of-sigmar-soulbound", + "archmage", "D35E", + "demonlord", "dnd5e", - "swade", - "tormenta20", + "gurps", "pf1", "pf2e", - "worldbuilding", - "archmage", "shaper", - "ac2d20" + "sw5e", + "swade", + "tormenta20", + "worldbuilding" ], "relationships": { "requires": [ @@ -49,6 +52,10 @@ } ], "systems": [ + { + "id": "ac2d20", + "type": "system" + }, { "id": "age-of-sigmar-soulbound", "type": "system" @@ -100,10 +107,6 @@ { "id": "worldbuilding", "type": "system" - }, - { - "id": "ac2d20", - "type": "system" } ] }, diff --git a/scripts/damage-log.js b/scripts/damage-log.js index 6d7fff5..0b87939 100644 --- a/scripts/damage-log.js +++ b/scripts/damage-log.js @@ -40,6 +40,25 @@ class DamageLog { * Location of HP attributes for supported systems. */ static SYSTEM_CONFIGS = { + ac2d20: { + fatigue: { + invert: true, + value: "fatigue" + }, + fortune: { + invert: false, + value: "fortune.value" + }, + injuries: { + invert: true, + value: "injuries.value" + }, + stress: { + invert: true, + value: "stress.value", + max: "stress.max" + } + }, "age-of-sigmar-soulbound": { toughness: { value: "combat.health.toughness.value", @@ -144,25 +163,6 @@ class DamageLog { min: "health.min", max: "health.max" } - }, - ac2d20: { - stress: { - invert: true, - value: "stress.value", - max: "stress.max" - }, - injuries: { - invert: true, - value: "injuries.value" - }, - fortune: { - invert: false, - value: "fortune.value" - }, - fatigue: { - invert: true, - value: "fatigue" - } } };