Template:Creature mutation: Difference between revisions

From Caves of Qud Wiki
Jump to navigation Jump to search
(Created page with "<noinclude>{{#cargo_declare:_table=CreatureMutations|Mutation=Page|MutationLevel=Integer}}</noinclude><includeonly>{{#cargo_store:_table=CreatureMutations|Mutation={{{1|}}}|Mu...")
 
(move all logic into a module)
 
(27 intermediate revisions by the same user not shown)
Line 1: Line 1:
<noinclude>{{#cargo_declare:_table=CreatureMutations|Mutation=Page|MutationLevel=Integer}}</noinclude><includeonly>{{#cargo_store:_table=CreatureMutations|Mutation={{{1|}}}|MutationLevel={{{2|1}}}}}
<noinclude>{{#cargo_declare:_table=CreatureMutations
[[{{{1|}}}]] ({{{2|1}}})</includeonly><noinclude>[[Category:Templates]]
|Mutation=Page
|MutationLevel=Integer
|Bonus=Integer
|JoinKey=String
|ObjectID=String}}</noinclude><includeonly>{{#cargo_store:_table=CreatureMutations
|Mutation={{{1|}}}
|MutationLevel={{{2|1}}}
|Bonus={{modifier|{{{3|16}}} }}
|JoinKey={{BASEPAGENAME}}
|ObjectID={{#var:id|}} }}<!----


Template for use in [[Template:Character]] only. The first argument is the mutation name, and the second is the mutation level (defaults to 1):
  Start


<syntaxhighlight lang="xml">
-->{{#invoke:Creature Mutation Query|main
{{creature mutation|Burrowing Claws|3}}
|{{{1|}}}|{{{2|}}}|{{{3|}}}}}</includeonly><noinclude>[[Category:Cargo Store Templates]]
</syntaxhighlight>
{{doc}}
 
</noinclude>
{{creature mutation|Burrowing Claws|3}}</noinclude>

Latest revision as of 15:08, 19 January 2023

This template defines the table "CreatureMutations". View table.

Template-info.png Documentation

Template for use in Template:Character only.

The first argument is the mutation name, and the second is the mutation level (defaults to 0).

{{creature mutation|Burrowing Claws|3}}
Burrowing Claws (3)

If mutation level is 0(or not set), the mutation level will not be shown (used for 1 pt mutations). If the mutation is a defect, a (D) will automatically be added:

{{creature mutation|Albino}}

Lua error in Module:Creature_Mutation_Query at line 84: attempt to concatenate local 'level' (a nil value).

This template also takes a third argument, the ego value of a creature. If the mutation is a mental mutation, it will add bonus levels based on the ego modifier.

{{creature mutation|Psychometry|3|9}}
Psychometry (3)