Template:Action calculation: Difference between revisions

From Baldur's Gate 3 Wiki
Jump to navigation Jump to search
(Created page with "{{#switch: {{{action1_type|}}} | melee attack = {{var|Melee Attack}}: {{{action1_attack|{{#expr: {{#switch: {{{action1_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action1_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action1_mode|}}} | +2}}}}}}} to hit, reach {{{action1_range|1.5 m (5 ft)}}}, {{{action1_target|}}}. {{...")
 
No edit summary
Line 1: Line 1:
{{#switch: {{{action1_type|}}}  
{{#switch: {{{action_type|}}}  
| melee attack = {{var|Melee Attack}}: {{{action1_attack|{{#expr: {{#switch: {{{action1_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action1_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action1_mode|}}} | +2}}}}}}} to hit, reach {{{action1_range|1.5 m (5 ft)}}}, {{{action1_target|}}}. {{var|Hit}}: {{{action1_damage| {{{action1_damage_dice|}}} +{{#expr: {{#switch: {{{action1_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action1_damage_type|}}}}} damage}}}. {{#if: {{{action1_conditions|}}} | On a successful hit, {{#if: {{{action1_save_outcome|}}} | target must make a successful {{{action1_save_ability|}}} save (DC {{{action1_save_dc|{{#expr: {{#switch: {{{action1_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action1_condition|}}} for {{{action1_condition_duration|}}}.}} {{#if: {{{action1_save_outcome|}}} | On a successful save, {{{action1_save_outcome|}}}.}} {{#if: {{{action1_resources|}}} | Uses {{{action1_resources|}}}.}} {{{action1_description|}}}
| melee attack = {{var|Melee Attack}}: {{{action_attack|{{#expr: {{#switch: {{{action_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action_mode|}}} | +2}}}}}}} to hit, reach {{{action_range|1.5 m (5 ft)}}}, {{{action_target|}}}. {{var|Hit}}: {{{action_damage| {{{action_damage_dice|}}} +{{#expr: {{#switch: {{{action_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action_damage_type|}}}}} damage}}}. {{#if: {{{action_conditions|}}} | On a successful hit, {{#if: {{{action_save_outcome|}}} | target must make a successful {{{action_save_ability|}}} save (DC {{{action_save_dc|{{#expr: {{#switch: {{{action_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action_condition|}}} for {{{action_condition_duration|}}}.}} {{#if: {{{action_save_outcome|}}} | On a successful save, {{{action_save_outcome|}}}.}} {{#if: {{{action_resources|}}} | Uses {{{action_resources|}}}.}} {{#if: {{{action_gain|}}} | Gain {{{action_gain_|}}}}}{{{action_description|}}}
| ranged attack = {{var|Ranged Attack}}: {{{action1_attack|{{#expr: {{#switch: {{{action1_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action1_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action1_mode|}}} | +2}}}}}}} to hit, range {{{action1_range|1.5 m (5 ft)}}}, {{{action1_target|}}}. {{var|Hit}}: {{{action1_damage| {{{action1_damage_dice|}}} +{{#expr: {{#switch: {{{action1_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action1_damage_type|}}}}} damage}}}. {{#if: {{{action1_conditions|}}} | On a successful hit, {{#if: {{{action1_save_outcome|}}} | target must make a successful {{{action1_save_ability|}}} save (DC {{{action1_save_dc|{{#expr: {{#switch: {{{action1_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action1_condition|}}} for {{{action1_condition_duration|}}}.}} {{#if: {{{action1_save_outcome|}}} | On a successful save, {{{action1_save_outcome|}}}.}} {{#if: {{{action1_resources|}}} | Uses {{{action1_resources|}}}.}} {{{action1_description|}}}
| ranged attack = {{var|Ranged Attack}}: {{{action_attack|{{#expr: {{#switch: {{{action_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action_mode|}}} | +2}}}}}}} to hit, range {{{action_range|1.5 m (5 ft)}}}, {{{action_target|}}}. {{var|Hit}}: {{{action_damage| {{{action_damage_dice|}}} +{{#expr: {{#switch: {{{action_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action_damage_type|}}}}} damage}}}. {{#if: {{{action_conditions|}}} | On a successful hit, {{#if: {{{action_save_outcome|}}} | target must make a successful {{{action_save_ability|}}} save (DC {{{action_save_dc|{{#expr: {{#switch: {{{action_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action_condition|}}} for {{{action_condition_duration|}}}.}} {{#if: {{{action_save_outcome|}}} | On a successful save, {{{action_save_outcome|}}}.}} {{#if: {{{action_resources|}}} | Uses {{{action_resources|}}}.}} {{#if: {{{action_gain|}}} | Gain {{{action_gain_|}}}}}{{{action_description|}}}
| melee spell attack = {{var|Melee Spell Attack}}: {{{action1_attack|{{#expr: {{#switch: {{{action1_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action1_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action1_mode|}}} | +2}}}}}}} to hit, reach {{{action1_range|1.5 m (5 ft)}}}, {{{action1_target|}}}. {{var|Hit}}: {{{action1_damage| {{{action1_damage_dice|}}} +{{#expr: {{#switch: {{{action1_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action1_damage_type|}}}}} damage}}}. {{#if: {{{action1_conditions|}}} | On a successful hit, {{#if: {{{action1_save_outcome|}}} | target must make a successful {{{action1_save_ability|}}} save (DC {{{action1_save_dc|{{#expr: {{#switch: {{{action1_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action1_condition|}}} for {{{action1_condition_duration|}}}.}} {{#if: {{{action1_save_outcome|}}} | On a successful save, {{{action1_save_outcome|}}}.}} {{#if: {{{action1_resources|}}} | Uses {{{action1_resources|}}}.}} {{{action1_description|}}}
| melee spell attack = {{var|Melee Spell Attack}}: {{{action_attack|{{#expr: {{#switch: {{{action_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action_mode|}}} | +2}}}}}}} to hit, reach {{{action_range|1.5 m (5 ft)}}}, {{{action_target|}}}. {{var|Hit}}: {{{action_damage| {{{action_damage_dice|}}} +{{#expr: {{#switch: {{{action_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action_damage_type|}}}}} damage}}}. {{#if: {{{action_conditions|}}} | On a successful hit, {{#if: {{{action_save_outcome|}}} | target must make a successful {{{action_save_ability|}}} save (DC {{{action_save_dc|{{#expr: {{#switch: {{{action_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action_condition|}}} for {{{action_condition_duration|}}}.}} {{#if: {{{action_save_outcome|}}} | On a successful save, {{{action_save_outcome|}}}.}} {{#if: {{{action_resources|}}} | Uses {{{action_resources|}}}.}} {{#if: {{{action_gain|}}} | Gain {{{action_gain_|}}}}}{{{action_description|}}}
| ranged spell attack = {{var|Ranged Spell Attack}}: {{{action1_attack|{{#expr: {{#switch: {{{action1_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action1_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action1_mode|}}} | +2}}}}}}} to hit, range {{{action1_range|1.5 m (5 ft)}}}, {{{action1_target|}}}. {{var|Hit}}: {{{action1_damage| {{{action1_damage_dice|}}} +{{#expr: {{#switch: {{{action1_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action1_damage_type|}}}}} damage}}}.  {{#if: {{{action1_conditions|}}} | On a successful hit, {{#if: {{{action1_save_outcome|}}} | target must make a successful {{{action1_save_ability|}}} save (DC {{{action1_save_dc|{{#expr: {{#switch: {{{action1_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action1_condition|}}} for {{{action1_condition_duration|}}}.}} {{#if: {{{action1_save_outcome|}}} | On a successful save, {{{action1_save_outcome|}}}.}} {{#if: {{{action1_resources|}}} | Uses {{{action1_resources|}}}.}} {{{action1_description|}}}
| ranged spell attack = {{var|Ranged Spell Attack}}: {{{action_attack|{{#expr: {{#switch: {{{action_attack_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#if: {{{action_attack_proficient|}}} | {{#lvar:proficiencybonus}} }} {{#if: {{{action_mode|}}} | +2}}}}}}} to hit, range {{{action_range|1.5 m (5 ft)}}}, {{{action_target|}}}. {{var|Hit}}: {{{action_damage| {{{action_damage_dice|}}} +{{#expr: {{#switch: {{{action_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action_damage_type|}}}}} damage}}}.  {{#if: {{{action_conditions|}}} | On a successful hit, {{#if: {{{action_save_outcome|}}} | target must make a successful {{{action_save_ability|}}} save (DC {{{action_save_dc|{{#expr: {{#switch: {{{action_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}), or gain |target gains}} {{{action_condition|}}} for {{{action_condition_duration|}}}.}} {{#if: {{{action_save_outcome|}}} | On a successful save, {{{action_save_outcome|}}}.}} {{#if: {{{action_resources|}}} | Uses {{{action_resources|}}}.}} {{#if: {{{action_gain|}}} | Gain {{{action_gain_|}}}}}{{{action_description|}}}
| spell = {{var|Spell}}: Target {{{action1_target|}}}, range {{{action1_range|}}}. {{#if: {{{action1_save_outcome|}}} | Target must make a successful {{{action1_save_ability|}}} save (DC {{{action1_save_dc|{{#expr: {{#switch: {{{action1_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}),}} {{#if: {{{action1_damage_type|}}} | {{#if: {{{action1_save_outcome|}}} | or take | Target takes}} {{{action1_damage| {{{action1_damage_dice|}}} +{{#expr: {{#switch: {{{action1_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action1_damage_type|}}}}} damage.}}}}} {{#if: {{{action1_condition|}}} | {{#if: {{{action1_save_outcome|}}} | or gain | Target gains}} {{{action1_condition|}}} for {{{action1_condition_duration|}}}.}} {{#if: {{{action1_save_outcome|}}} | On a successful save, {{{action1_save_outcome|}}}.}} {{#if: {{{action1_resources|}}} | Uses {{{action1_resources|}}}.}} {{{action1_description|}}}
| spell = {{var|Spell}}: Target {{{action_target|}}}, range {{{action_range|}}}. {{#if: {{{action_save_outcome|}}} | Target must make a successful {{{action_save_ability|}}} save (DC {{{action_save_dc|{{#expr: {{#switch: {{{action_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}),}} {{#if: {{{action_damage_type|}}} | {{#if: {{{action_save_outcome|}}} | or take | Target takes}} {{{action_damage| {{{action_damage_dice|}}} +{{#expr: {{#switch: {{{action_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action_damage_type|}}}}} damage.}}}}} {{#if: {{{action_condition|}}} | {{#if: {{{action_save_outcome|}}} | or gain | Target gains}} {{{action_condition|}}} for {{{action_condition_duration|}}}.}} {{#if: {{{action_save_outcome|}}} | On a successful save, {{{action_save_outcome|}}}.}} {{#if: {{{action_resources|}}} | Uses {{{action_resources|}}}.}} {{#if: {{{action_gain|}}} | Gain {{{action_gain_|}}}}}{{{action_description|}}}
| Action = {{var|Action}}: Target {{{action1_target|}}}, range {{{action1_range|}}}. {{#if: {{{action1_save_outcome|}}} | Target must make a successful {{{action1_save_ability|}}} save (DC {{{action1_save_dc|{{#expr: {{#switch: {{{action1_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}),}} {{#if: {{{action1_damage_type|}}} | {{#if: {{{action1_save_outcome|}}} | or take | Target takes}} {{{action1_damage| {{{action1_damage_dice|}}} +{{#expr: {{#switch: {{{action1_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action1_damage_type|}}}}} damage.}}}}} {{#if: {{{action1_condition|}}} | {{#if: {{{action1_save_outcome|}}} | or gain | Target gains}} {{{action1_condition|}}} for {{{action1_condition_duration|}}}.}} {{#if: {{{action1_save_outcome|}}} | On a successful save, {{{action1_save_outcome|}}}.}} {{#if: {{{action1_resources|}}} | Uses {{{action1_resources|}}}.}} {{{action1_description|}}}}}
| Action = {{var|Action}}: Target {{{action_target|}}}, range {{{action_range|}}}. {{#if: {{{action_save_outcome|}}} | Target must make a successful {{{action_save_ability|}}} save (DC {{{action_save_dc|{{#expr: {{#switch: {{{action_dc_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}} {{#lvar:proficiencybonus}}}}.}}}),}} {{#if: {{{action_damage_type|}}} | {{#if: {{{action_save_outcome|}}} | or take | Target takes}} {{{action_damage| {{{action_damage_dice|}}} +{{#expr: {{#switch: {{{action_damage_ability|}}} | str = {{#lvar:strmod}} | dex = {{#lvar:dexmod}} | con = {{#lvar:conmod}} | int = {{#lvar:intmod}} | wis = {{#lvar:wismod}} | cha = {{#lvar:chamod}}}}}} {{damage color|{{{action_damage_type|}}}}} damage.}}}}} {{#if: {{{action_condition|}}} | {{#if: {{{action_save_outcome|}}} | or gain | Target gains}} {{{action_condition|}}} for {{{action_condition_duration|}}}.}} {{#if: {{{action_save_outcome|}}} | On a successful save, {{{action_save_outcome|}}}.}} {{#if: {{{action_resources|}}} | Uses {{{action_resources|}}}.}} {{#if: {{{action_gain|}}} | Gain {{{action_gain_|}}}}}{{{action_description|}}}

Revision as of 00:29, 4 January 2024

{{#switch: | melee attack = Melee Attack: to hit, reach 1.5 m (5 ft), . Hit: + damage. | ranged attack = Ranged Attack: to hit, range 1.5 m (5 ft), . Hit: + damage. | melee spell attack = Melee Spell Attack: to hit, reach 1.5 m (5 ft), . Hit: + damage. | ranged spell attack = Ranged Spell Attack: to hit, range 1.5 m (5 ft), . Hit: + damage. | spell = Spell: Target , range . | Action = Action: Target , range .