Template:Condition: Difference between revisions

From bg3.wiki
Jump to navigation Jump to search
mNo edit summary
Tag: Reverted
mNo edit summary
Tag: Reverted
Line 1: Line 1:
<includeonly><onlyinclude>{{#if:{{{border|}}}|<div style="padding-bottom: 1em"><div class="bg3wiki-tooltip-box">||}}{{#cargo_query: tables = conditions
<includeonly><onlyinclude>{{#if:{{{border|}}}|<div style="padding-bottom: 1em"><div class="bg3wiki-tooltip-box">||}}{{#cargo_query: tables = conditions
| fields = _pageName=page, name, icon, effects, types, CONCAT('{{{save|}}}') = save, CONCAT('{{{duration|}}}') = duration, condition_name = condition, condition_save, condition_dc, condition2_name = condition2, condition2_save, condition2_dc, condition3_name = condition3, condition3_save, condition3_dc, CONCAT('{{{inline|}}}') = inline, CONCAT('{{#replace:{{{altname|}}}|'|\'}}') = altname, CONCAT('{{#replace:{{{dc|}}}|'|"}}') = dc, CONCAT('{{#if:{{{w|}}}|{{{w}}}|25}}') = w,
| fields = _pageName=page, name, icon, effects, types, CONCAT('{{{save|}}}') = save, CONCAT('{{{duration|}}}') = duration CONCAT('{{{inline|}}}') = inline, CONCAT('{{#replace:{{{altname|}}}|'|\'}}') = altname, CONCAT('{{#replace:{{{dc|}}}|'|"}}') = dc, CONCAT('{{#if:{{{w|}}}|{{{w}}}|25}}') = w,
| where = _pageName = "{{#replace:{{{1}}}|&#39;|\'}} (Condition)"
| where = _pageName = "{{#replace:{{{1}}}|&#39;|\'}} (Condition)"
| format = template
| format = template

Revision as of 19:50, 13 May 2024

Template documentation

Use this to display a condition. Examples follow.

This template just runs the Cargo query. For the formatting, see: Template:Condition/Format

Base usage

Usage:

{{Condition | Bleeding }}

Result:


Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` ...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT() AS `save`,CONCAT() = duration CONCAT() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Bleeding (Condition)" ORDER BY `_ID` LIMIT 100


With duration

Usage:

{{Condition | Bleeding | duration = 2 }}

Result:


Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` ...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT() AS `save`,CONCAT('2') = duration CONCAT() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Bleeding (Condition)" ORDER BY `_ID` LIMIT 100


With saving throw

Usage:

{{Condition | Bleeding | save = CON }}

Result:


Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` ...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT('CON') AS `save`,CONCAT() = duration CONCAT() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Bleeding (Condition)" ORDER BY `_ID` LIMIT 100


With duration and saving throw

Usage:

{{Condition | Bleeding | save = CON | duration = 2 | dc = 15 }}

Result:


Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '() = inline,CONCAT() AS `altname`,CONCAT('15') AS `dc`,CONCAT('25') AS `w...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT('CON') AS `save`,CONCAT('2') = duration CONCAT() = inline,CONCAT() AS `altname`,CONCAT('15') AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Bleeding (Condition)" ORDER BY `_ID` LIMIT 100


With a border

Use border = 1 to add a border.

{{Condition | Bleeding | save = CON | duration = 2 | border = 1}}

Result:


Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` ...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT('CON') AS `save`,CONCAT('2') = duration CONCAT() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Bleeding (Condition)" ORDER BY `_ID` LIMIT 100


Inline-friendly

Usage:

{{Condition | Bleeding | inline = true }}
Result: blabla
Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '('true') = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS ...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT() AS `save`,CONCAT() = duration CONCAT('true') = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Bleeding (Condition)" ORDER BY `_ID` LIMIT 100

blabla

Alternative display name

{{Condition | Bleeding | save = CON | altname=oh no i'm bleeding | duration = 2 }}

Result:

Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '() = inline,CONCAT('oh no i\'m bleeding') AS `altname`,CONCAT() AS `dc`,C...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT('CON') AS `save`,CONCAT('2') = duration CONCAT() = inline,CONCAT('oh no i\'m bleeding') AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Bleeding (Condition)" ORDER BY `_ID` LIMIT 100

Also displays types

Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near '() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` ...' at line 1

Function: CargoSQLQuery::run Query: SELECT `cargo__conditions`.`_pageID` AS `cargo_backlink_page_id_conditions`,`_pageName` AS `page`,`name` AS `name`,`icon` AS `icon`,`effects` AS `effects`,`types__full` AS `types`,CONCAT() AS `save`,CONCAT() = duration CONCAT() = inline,CONCAT() AS `altname`,CONCAT() AS `dc`,CONCAT('25') AS `w` FROM `cargo__conditions` WHERE _pageName = "Feverish (Condition)" ORDER BY `_ID` LIMIT 100