Template:Recipes/extract

来自Terraria Wiki
跳到导航 跳到搜索
This template is i18n-ready, which means it is easy to localize for different languages. Please see I18n & l10n for templates to learn more.
此模板使用了 Lua。
此模板使用了用 Lua 编程语言编写的 模块:Recipes。要了解 Lua 的更多信息,参见 en:Terraria Wiki:Lua
Template-info.svg 文档 以下文档来自Template:Recipes/extract/doc。(编辑 | 历史

Use this template to extract info from certain crafting recipe(s).

Usage

This template is designed for extracting info from recipe(s) for "single result item"(however can be multiple recipes), so you need to use query constraint paramters (result, ingredient ...) to query "single" result. See {{recipes}} for details of all query constraint paramters.

If query result is more than one row, this template will only return first row for mode=station or mode=result, and all rows for mode=compact or mode=ingredients .

then, use following parameters for output format:

mode = compact/result/resultamount/ingredients/station/ingredients-buy/ingredients-sell

Output mode. If not specified, it will be compact by default. See examples below. NOTE: for ingredients-buy/ingredients-sell, you should make sure there is only 1 result recipe and no alternative crafting ingredient in ingredients list. For ingredients-buy, you should make sure all ingredients are actually buyable.

sep or seperator

Separator between multiple ingredients lists. Only valid when mode=compact or mode=ingredients. Default is <br/>'''or'''<br/> for mode=compact or <br/>'''or'''<br/> for mode=ingredients. If value is null or nil, there will be no seperator. Note: single ingredients list will be wrapped in <div> when |mode=ingredients and in <span> when |mode=compact.

withresult and nostation and noversion

Only valid when mode=compact. By default, it will output as [version]: [ingredients]@[station], if withresult=y, will output as [ingredients]@[station]=[result], if nostation=y, there wil be no @[station], if noversion=y, there will be no [version]:.

noversion

Only valid when mode=ingredients. If noversion=y, there will be no version icons before ingredients list.

nonote

Only valid when mode=compact or mode=result. If nonote=y, there will be no result note text after result item.

noamount

Only valid when mode=result. If noamount=y, there will be no result amount after result item.

showresultid=y and link=no

Only valid when mode=result. result item will show their internal item ID (if available), and/or have no link, respectively.

Examples

Code Result
{{recipes/extract|result=Lunar Hook}} 6 星云碎片 + 6 日耀碎片 + 6 星尘碎片 + 6 星旋碎片 ( @ 远古操纵机 )
{{recipes/extract|result=Lunar Hook|withresult=y}} 6 星云碎片 + 6 日耀碎片 + 6 星尘碎片 + 6 星旋碎片 = 月钩 ( @ 远古操纵机 )
{{recipes/extract|result=Lunar Hook|nostation=y}} 6 星云碎片 + 6 日耀碎片 + 6 星尘碎片 + 6 星旋碎片
{{recipes/extract|result=Lunar Hook|withresult=y|nostation=y}} 6 星云碎片 + 6 日耀碎片 + 6 星尘碎片 + 6 星旋碎片 = 月钩
{{recipes/extract|result=Lunar Hook|mode=result}} 月钩月钩(电脑版、主机版、和移动版)
{{recipes/extract|result=Lunar Hook|mode=ingredients}}
{{recipes/extract|result=Lunar Hook|mode=station}} 远古操纵机远古操纵机(电脑版、主机版、和移动版)
{{recipes/extract|result=Campfire|sep=<br/>}} 电脑版主机版移动版:10 任何木材 + 5 火把
前代主机版任天堂3DS版:20 任何木材 + 5 火把
{{recipes/extract|result=Lunar Hook|mode=ingredients-sell}} 48000
{{coin|{{recipes/extract|result=Lunar Hook|mode=ingredients-sell}}}} 4 GC80 SC

With and without full parameter:

Code Result
{{recipes/extract|result=Optic Staff|full=y}} 1 黑晶状体 + 2 晶状体 + 12 神圣锭 + 20 视域之魂 ( @ 秘银砧 / 山铜砧 )
{{recipes/extract|result=Optic Staff}} 黑晶状体 + 2 晶状体 + 12 神圣锭 + 20 视域之魂 ( @ 秘银砧 / 山铜砧 )

Platforms exclusive:

Code Result
{{recipes/extract|result=Flaming Arrow|versions={{eversions|raw=y|1.3.0.1}}|withresult=y}} 电脑版主机版移动版:10 木箭 + 火把 = 10 烈焰箭
{{recipes/extract|result=Flaming Arrow|versions={{eversions|raw=y|1.3.0.1|invert=y}}|withresult=y}} 前代主机版任天堂3DS版:5 木箭 + 火把 = 5 烈焰箭
{{recipes/extract|result=Flaming Arrow|versions={{eversions|raw=y|1.3.0.1|invert=y}}|withresult=y|noversion=y}} 5 木箭 + 火把 = 5 烈焰箭

Result note:

Code Result
{{recipes/extract|result=Heavenforge Brick|withresult=y}} 夜明砖 = 天熔砖(在满月 size=16px 期间) ( @ 微光嬗变 )

4 天熔砖墙 = 天熔砖 ( @ 工作台 )
{{recipes/extract|result=Heavenforge Brick|withresult=y|nonote=y}} 夜明砖 = 天熔砖 ( @ 微光嬗变 )

4 天熔砖墙 = 天熔砖 ( @ 工作台 )
{{recipes/extract|result=Heavenforge Brick|mode=result}} 天熔砖天熔砖(电脑版、主机版、和移动版)(在满月 size=16px 期间)
{{recipes/extract|result=Heavenforge Brick|mode=result|nonote=y}} 天熔砖天熔砖(电脑版、主机版、和移动版)

Multiple recipes: Note: single ingredients list will be wrapped in <div> when |mode=ingredients and in <span> when |mode=compact.

Code Result
{{recipes/extract|result=Sashimi}} 金枪鱼 ( @ 工作台 )

三文鱼 ( @ 工作台 )

红鲷鱼 ( @ 工作台 )

偏口鱼 ( @ 工作台 )

前代主机版任天堂3DS版鳟鱼 ( @ 工作台 )
{{recipes/extract|result=Sashimi|withresult=y}} 金枪鱼 = 生鱼片 ( @ 工作台 )

三文鱼 = 生鱼片 ( @ 工作台 )

红鲷鱼 = 生鱼片 ( @ 工作台 )

偏口鱼 = 生鱼片 ( @ 工作台 )

前代主机版任天堂3DS版鳟鱼 = 生鱼片 ( @ 工作台 )
{{recipes/extract|result=Sashimi|mode=result}} 生鱼片生鱼片
{{recipes/extract|result=Sashimi|mode=ingredients}}
  • 偏口鱼偏口鱼(电脑版、主机版、和移动版)
前代主机版任天堂3DS版
{{recipes/extract|result=Sashimi|mode=station}} 工作台工作台
{{recipes/extract|result=Sashimi|mode=ingredients|sep=--or--}}
--or----or----or--
  • 偏口鱼偏口鱼(电脑版、主机版、和移动版)
--or--
前代主机版任天堂3DS版
{{recipes/extract|result=Sashimi|nostation=y|sep=&#32;/&#32;}} 金枪鱼 / 三文鱼 / 红鲷鱼 / 偏口鱼 / 前代主机版任天堂3DS版鳟鱼
<table class="terraria lined"><tr><td rowspan="5" style="border:0">{{recipes/extract|result=Sashimi|mode=result}}</td>
<td>{{recipes/extract|result=Sashimi|withresult=y|sep=</td></tr><tr><td>}}</td></tr></table>
生鱼片生鱼片 金枪鱼 = 生鱼片 ( @ 工作台 )
三文鱼 = 生鱼片 ( @ 工作台 )
红鲷鱼 = 生鱼片 ( @ 工作台 )
偏口鱼 = 生鱼片 ( @ 工作台 )
前代主机版任天堂3DS版鳟鱼 = 生鱼片 ( @ 工作台 )