Difference between revisions of "Template:DbParser"

From StarMade Wiki
(Created page with "{{#if{{{2|}}}|<<!-- -->>{{#if{{{3|}}}|<<!-- -->>{{Db/Version/0.200.335/Main|{{{1}}}|{{{2}}}|{{{3}}}}}<<!-- -->>|}}<<!-- -->>{{#switch:{{{2}}} |Armor={{#ifeq:{{Db/Version/0.200...")
 
m
 
(43 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{#if{{{2|}}}|<<!--
+
{{#if:{{{1|}}}|{{#switch:{{padleft:|1|{{{1}}}}} <!-- Verify if version is requested by ~, then shift all parameters numbers -->
-->>{{#if{{{3|}}}|<<!--
+
|~ ={{#if:{{{3|}}}|<!--
-->>{{Db/Version/0.200.335/Main|{{{1}}}|{{{2}}}|{{{3}}}}}<<!--
+
-->{{#switch:{{{3}}}<!--  
-->>|}}<<!--
+
=========== Main Database =============
-->>{{#switch:{{{2}}}
+
---------    Rename some database type name -->
|Armor={{#ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|Armor}}|0.0|No|{{Db/Version/0.200.335/Main|{{{1}}}|{{{2}}}}
+
|Id={{Db|{{{1}}}|{{{2}}}|type}}
|Ahp={{#ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|ArmorHPContribution}}|0| ---- |{{Db/Version/0.200.335/Main|{{{1}}}|ArmorHPContribution}}}}
+
|Depreciated={{Db|{{{1}}}|{{{2}}}|Deprecated}}
|Shp={{#ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|SHP}}|0|No|{{Db/Version/0.200.335/Main|{{{1}}}|SHP}}}}
+
|Shp={{Db|{{{1}}}|{{{2}}}|SHP}}
|ReactorHp={{#ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|ReactorHp}}|0| ---- |{{Db/Version/0.200.335/Main|{{{1}}}|ReactorHp}}}}
+
|name={{Db|{{{1}}}|{{{2}}}|link}}<!--
|Light={{#ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|Light}}|true|Yes|No}}
+
---------    Preformat some answers (0, False, etc.. return value if true) -->
|Transparency={{#ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|Transparency}}|true|Yes|No}}
+
|image=[[File:{{Db|{{{1}}}|{{{2}}}|link}}.png|{{#if:{{{4|}}}|{{{4}}}|150}}px|link={{Db|{{{1}}}|{{{2}}}|link}}]]
|Factory={{#Ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|Factory}}|3|{{blocklink|Basic Factory}}|{{#Ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|Factory}}|4|{{blocklink|Standard Factory}}|{{#Ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|Factory}}|5|{{blocklink|Advanced Factory}}|n/a}}}}}}
+
|Armor|Hp={{#ifeq:{{Db|{{{1}}}|{{{2}}}|{{{3}}}}}|0|No|{{Db|{{{1}}}|{{{2}}}|{{{3}}}}}}}
|InShop={{#ifeq:{{Db/Version/0.200.335/Main|{{{1}}}|InShop}}|true|Yes|No}}
+
|AHP|Ahp={{#ifeq:{{Db|{{{1}}}|{{{2}}}|AHP}}|0| ---- |{{Db|{{{1}}}|{{{2}}}|AHP}}}}
{{Db/Version/0.200.335/Main|{{{1}}}|{{{2}}}}}<<!--
+
|Animated|Light|Transparency|InShop|Placable={{#ifeq:{{Db|{{{1}}}|{{{2}}}|{{{3}}}}}|true|Yes|No}}
-->>}}
+
|Factory={{#Ifeq:{{Db|{{{1}}}|{{{2}}}|Factory}}|3|Basic Factory|{{#Ifeq:{{Db|{{{1}}}||{{{2}}}Factory}}|4|Standard Factory|{{#Ifeq:{{Db|{{{1}}}|{{{2}}}|Factory}}|5|Advanced Factory|n/a}}}}}}
 +
|ReactorHp={{#ifeq:{{Db|{{{1}}}|{{{2}}}|{{{3}}}}}|0||{{Db|{{{1}}}|{{{2}}}|{{{3}}}}}}}<!--
 +
---------    Default for other Main Db value -->
 +
|link|type|SHP||EM|Kinetic|Heat|Mass|Hp|cat|cat2|textureId|cat3|FactoryBakeTime|cat4|BlockStyle|Light|Deprecated|LightColor= {{Db|{{{1}}}|{{{2}}}|{{{3}}}}}<!--
 +
=========== Sub Database =============
 +
---------    Return an other value if true -->
 +
|Shop={{#ifeq:{{Db|{{{1}}}|{{{2}}}|InShop}}|true|{{DbSub|{{{1}}}|{{{2}}}|Price}} c|No}}<!--
 +
---------    Preformat some answers (0, False, etc.. ) -->
 +
|MainCtrl|EffectCtrl|SupportCtrl={{#ifeq:{{DbSub|{{{1}}}|{{{2}}}}}|true|Yes|No}}
 +
|ExpAbsorb={{#ifeq:{{DbSub|{{{1}}}|{{{2}}}|{{{3}}}}}|0||{{DbSub|{{{1}}}|{{{2}}}|{{{3}}}}}}}<!--
 +
---------    Default for other Main Db value -->
 +
|Item|CtrlBy|Ctrling|Price|Desc|BlockResourceType|Chamber|Volume|InRecipe = {{DbSub|{{{1}}}|{{{2}}}|{{{3}}}|{{{4}}}|{{{5}}}}}
 +
|Unknow {{{3}}} : link, Id, Factory, Animated, Armor, Ahp, Shp, Transparency, InShop, ReactorHp, Mass, Hp, Heat, Kinetic,EM, cat, cat2, cat3, cat4, Placable, BlockStyle, Light, Depreciated, LightColor, Item(table), CtrlBy(table), Ctrling(table), Shop(InShop+Price), Price, Desc, BlockResourceType, FactoryBakeTime, Chamber(table), Volume, InRecipe, MainCtrl, SupportCtrl, EffectCtrl, ExpAbsorb
 +
}}}}<!--
 +
-->|{{#if:{{{2|}}}|<!-- Request without "~"  ==> default version
 +
-->{{#switch:{{{2}}}<!--
 +
=========== Main Database =============
 +
---------    Rename some database type name -->
 +
|Id={{Db|{{{1}}}|type}}
 +
|Depreciated={{Db|{{{1}}}|Deprecated}}
 +
|Shp={{Db|{{{1}}}|SHP}}
 +
|name={{Db|{{{1}}}|link}}<!--
 +
---------    Preformat some answers (0, False, etc.. return value if true) -->
 +
|image=[[File:{{Db|{{{1}}}|link}}.png|{{#if:{{{3|}}}|{{{3}}}|150}}px|link={{Db|{{{1}}}|link}}]]
 +
|Armor|Hp={{#ifeq:{{Db|{{{1}}}|{{{2}}}}}|0|No|{{Db|{{{1}}}|{{{2}}}}}}}
 +
|AHP|Ahp={{#ifeq:{{Db|{{{1}}}|AHP}}|0| ---- |{{Db|{{{1}}}|AHP}}}}
 +
|Animated|Light|Transparency|InShop|Placable={{#ifeq:{{Db|{{{1}}}|{{{2}}}}}|true|Yes|No}}
 +
|Factory={{#Ifeq:{{Db|{{{1}}}|Factory}}|3|Basic Factory|{{#Ifeq:{{Db|{{{1}}}|Factory}}|4|Standard Factory|{{#Ifeq:{{Db|{{{1}}}|Factory}}|5|Advanced Factory|n/a}}}}}}
 +
|ReactorHp={{#ifeq:{{Db|{{{1}}}|{{{2}}}}}|0||{{Db|{{{1}}}|{{{2}}}}}}}<!--
 +
---------    Default for other Main Db value -->
 +
|link|type|SHP||EM|Kinetic|Heat|Mass|Hp|cat|cat2|textureId|cat3|FactoryBakeTime|cat4|BlockStyle|Light|Deprecated|LightColor= {{Db|{{{1}}}|{{{2}}}}}<!--
 +
=========== Sub Database =============
 +
---------    Return an other value if true -->
 +
|Shop={{#ifeq:{{Db|{{{1}}}|InShop}}|true|{{DbSub|{{{1}}}|Price}} c|No}}<!--
 +
---------    Preformat some answers (0, False, etc.. ) -->
 +
|MainCtrl|EffectCtrl|SupportCtrl={{#ifeq:{{DbSub|{{{1}}}|{{{2}}}}}|true|Yes|No}}
 +
|ExpAbsorb={{#ifeq:{{DbSub|{{{1}}}|{{{2}}}}}|0||{{DbSub|{{{1}}}|{{{2}}}}}}}<!--
 +
---------    Default for other Main Db value -->
 +
|Item|CtrlBy|Ctrling|Price|Desc|BlockResourceType|Chamber|Volume|InRecipe = {{DbSub|{{{1}}}|{{{2}}}|{{{3}}}|{{{4}}}}}
 +
|Unknow {{{2}}} : link, Id, Factory, Animated, Armor, Ahp, Shp, Transparency, InShop, ReactorHp, Mass, Hp, Heat, Kinetic,EM, cat, cat2, cat3, cat4, Placable, BlockStyle, Light, Depreciated, LightColor, Item(table), CtrlBy(table), Ctrling(table), Shop(InShop+Price), Price, Desc, BlockResourceType, FactoryBakeTime, Chamber(table), Volume, InRecipe, MainCtrl, SupportCtrl, EffectCtrl, ExpAbsorb
 +
}}<!-- switch
 +
-->| No Request to DbParser}}}}}}<!--
 +
--><noinclude>{{Documentation}}</noinclude>

Latest revision as of 22:05, 27 July 2018

[view] [edit] [history] [[[:Template:Purge]]] 50px Template documentation

see Template:Db/doc to more information