User:Crashaholic/ActionTemplate: Difference between revisions

From bg3.wiki
Jump to navigation Jump to search
(added NoSeo Option)
m (Changed redirect target from Template:Action Page to Template:Action page)
Tags: Redirect target changed Visual edit
 
(50 intermediate revisions by 3 users not shown)
Line 1: Line 1:
<includeonly>{{#ifeq: {{{NoSeo}}} | 1 | {{blank}} | {{PageSeo
#REDIRECT [[Template:Action page]]
| description = {{{name|{{PAGENAME}}}}} {{{summary}}}
| image = {{#if: {{{image|}}} | {{{image|}}} | Alert Icon.png}}
}}}}
__NOTOC__
[[File:{{#if: {{{image|}}} | {{{image|}}} | Alert Icon.png}}|frameless|right]]
{{{summary}}}
 
== Description ==
{{{description}}}
 
== Properties ==
{{trim|{{#if: {{{cost|}}}
    |{{#if: {{#pos: {{{cost|}}}|,}}
        |{{#if: {{trim|{{#explode: {{{cost|}}}|,|0}}}}
        | {{InfoBlob|{{action|{{#explode: {{{cost|}}}|,|0}}}} + {{#explode: {{{cost|}}}|,|1}}}}
| {{InfoBlob|{{#explode: {{{cost|}}}|,|1}}}}
}}
|{{InfoBlob|{{action|{{#explode: {{{cost}}}|,|0}}}}}}
    }}| {{blank}}
}}}}
{{trim|{{#if: {{{concentration|}}} | * {{Concentration}} | {{blank}}}}}}
{{trim|{{#if: {{{damage|}}} | * {{{damage}}}| {{blank}}}}}} <!-- TODO: make this a bit smarter -->
{{trim|{{#if: {{{recharge|}}} | * {{{recharge}}}| {{blank}}}}}} <!-- TODO: make this a bit smarter -->
{{trim|
{{#if: {{{duration|}}}
|{{#ifeq:{{{duration|}}}| LR
|* {{Duration|Until Long Rest}}
|{{#ifeq: {{{duration|}}} |Perm
|* {{Duration|Permanent}}
|* {{Duration|{{{duration}}}}}
}}
}}
|{{blank}}
}}
}}
{{trim|{{#if: {{{range|}}} | * {{{range}}}| {{blank}}}}}} <!-- TODO: make this a bit smarter -->
{{trim|{{#if: {{{aoe|}}} | * {{{aoe}}}| {{blank}}}}}} <!-- TODO: make this a bit smarter -->
{{trim|
{{#if: {{{save|}}}
| * {{SmallIcon|Saving Throw Icons.png}} {{#switch: {{#if: {{#pos:{{{save|}}}|,}} | {{#explode:{{{save|}}}|,|0}} | {{{save|}}}}}
| strength | Strength | str | STR = [[Saving Throw|STR Save]]
| dexterity | Dexterity | dex | DEX = [[Saving Throw|DEX Save]]
| constitution | Constitution | con | CON = [[Saving Throw|CON Save]]
| intelligence | Intelligence | int | INT = [[Saving Throw|INT Save]]
| wisdom | Wisdom | wis | WIS = [[Saving Throw|WIS Save]]
| charisma | Charisma | cha | CHA = [[Saving Throw|CHA Save]]
| #default = *[[Saving Throw]]
}}{{#if: {{#pos:{{{save|}}}|,}}
|- (On Save: {{#explode:{{{save|}}}|,|1}})
}}| {{blank}}
}}
}}
{{trim|{{#if: {{{additional|}}} | {{{additional}}}| {{blank}}}}}}
 
{{#if: {{{higherlevels|}}} | == At Higher Levels ==}}
{{trim|{{#if: {{{higherlevels|}}} | {{{higherlevels}}}| {{blank}}}}}} <!-- TODO: make this a bit smarter -->
 
{{#if: {{{learns|}}} | == How to Learn ==}}
{{trim|{{#if: {{{learns|}}} | {{{learns|}}}}}}} <!-- TODO: make this a bit smarter -->
 
{{clear}}
{{#if: {{{notes|}}} | == Notes == }}
{{trim|{{#if: {{{notes|}}} | {{{notes}}}| {{blank}}}}}}</includeonly><noinclude>This is a page to transclude to generate action pages. It is generally for pages that do not fit the [[Template:SpellPage | <code><nowiki>{{SpellPage}} Template</nowiki></code>]]
 
If this is too egregious, do reach out to me on Discord and tell me if there are alternatives instead of using transclusion (which I'm trying to use for custom templates).
<!-- im just lazy and tired of copy pasting from other page sources, i just want to lazily type out something PLEASE-->
 
=Usage=
<pre>
{{User:Crashaholic/ActionTemplate
| NoSeo
| description =
| image =
| summary =
| cost =
| concentration =
| damage =
| recharge =
| duration =
| range =
| aoe =
| save =
| additional =
| higherlevels =
| learns =
| notes =
}}
</pre>
 
The following is a table to further explain what each parameter takes, and how to use them.
 
{| class="wikitable" style="width: 100%;"
|-
! Parameter Name
! Description
! Usage
|-
| {{C|NoSeo}}
|
|
|-
| {{C|description}}
| The in-game description of the action. This description is NOT for SEO 'See: summary'.
| <code>description = Lorem ipsum</code>
|-
| {{C|image}}
| The image that will be used in the page's SEO and be the page's main image.<br/>IF THIS IS LEFT EMPTY, [[File:Alert Icon.png]] WILL BE USED INSTEAD!
| <code>image = Wiki_Link_To_Image_Here</code>
|-
| {{C|summary}}
| The summary of the action. This will be used as the wiki's description as well as the SEO text.
| <code>summary = Lorem Ipsum</code>
|-
| {{C|cost}}
| The resource cost of the action. You can use the same parameters as with <code><nowiki>{{action}}</nowiki></code>, but you can add an additional resource to it as well.
For example:
* If a skill takes a <code><nowiki>{{action|bonus}}</nowiki></code> and a [[Battle Master|Superiority Die]] (D8): <code><nowiki>| cost = bonus,[[File:Superiority_Die_d8_Icon.png|25px]]</nowiki></code>
** Result: <code>{{action|bonus}} + [[File:Superiority_Die_d8_Icon.png|25px]]</code>
* If a skill takes an <code><nowiki>{{action}}</nowiki></code>: <code><nowiki>| cost = action</nowiki></code>
** Result: <code>{{action}}</code>
* If a skill takes just a class resource like 2{{User:Tc/Ki}}s: <code><nowiki>| cost = ,2{{User:Tc/Ki}}s</nowiki></code>
** Result: <code>2{{User:Tc/Ki}}s</code>
| <code>cost = (<nowiki>{{action}}</nowiki> parameters), (text)</code><br/>
<code>cost = (<nowiki>{{action}}</nowiki> parameters)</code><br/>
<code>cost = , (text)</code>
|-
| {{C|concentration}}
| If this skill is a concentration, type something here. Can be any value you want. Otherwise, leave it blank or delete the field entirely.
| <code>concentration = This action is a concentration!</code>
<code>concentration=</code>
|}
 
=Example=
<pre>{{User:Crashaholic/ActionTemplate
| description = abc
| image = Fly Icon.png
| summary = fly you fools
| cost = action, 2{{User:Tc/Ki}}s
| damage = {{DamageInfo|1d4+1|Bludgeoning}}
| recharge = {{Recharge|Long Rest}}
| duration = LR
| save = DEX, abc
| additional = * abcd
| higherlevels = go far
| notes = bar
| learns = {{class|Monk}} 3
}}
</pre>
{{User:Crashaholic/ActionTemplate
| description = abc
| image = Fly Icon.png
| summary = fly you fools
| cost = action, 2{{User:Tc/Ki}}s
| damage = {{DamageInfo|1d4+1|Bludgeoning}}
| recharge = {{Recharge|Long Rest}}
| duration = LR
| save = DEX, abc
| additional = * abcd
| higherlevels = go far
| notes = bar
| learns = {{class|Monk}} 3
}}
</noinclude>

Latest revision as of 21:56, 21 January 2024