Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
item:nanomachines:zh [2023/11/06 10:38]
hfsr created
item:nanomachines:zh [2023/11/28 09:11] (current)
hfsr [纳米机器]
Line 1: Line 1:
-Nanomachines+纳米机器
 ============ ============
  
-**Nanomachines** are a configurable buff system. Using energy as a resource, they are able to apply various positive and negative effects to the player.+**纳米机器**是一种可配置的增益系统。它们可消耗能源以为玩家提供多种正面或负面效果。
  
-=== Basic Usage === +===基本用法=== 
-The player has to "​eat"​ them before they can be used. Once ingested, a power indicator in the HUD, positioned left of the item bar, will indicate how much energy the nanomachines have left. Their energy can be recharged by standing close to a [[block:Charger]]. Energy is slowly used over time proportional to the number of active inputs. A small amount of energy is still lost over time even when all inputs are deactivated.+在使用之前,玩家需要“吃掉”它们。当吃掉纳米机器后,玩家的HUD中将会多出一个能量指示器,位置在快捷栏的左侧,用于显示纳米机器中的剩余能量。站在[[block:charger:​zh|充电器]]附近即可补充能量。能量会随时间消耗,速度正比于启用的输入数。即使禁用所有输入也会随时间消耗少量能量。
  
-They provide a certain number of "​inputs"​ that can be toggled, causing many different effects on the player, ranging from visual effects such as particles spawning near the player, to select potion effects and some more rare and special behaviors.+纳米机器会提供一定数量的可开关的“输入”,这些“输入”会给玩家造成多种不同的效果:从视觉效果(如在玩家附近产生的粒子)到可选择的选择药水效果,以及一些更罕见和特殊的行为。
  
-Which input triggers what effect depends on the current configuration of the nanomachines,​ the actual "​connections"​ being random per configuration. Which input does what is not clear to the player until they try it. The configuration can be changed by ingesting a new batch of nanomachines. Additionally,​ enabling too many inputs at a time has severe negative effects.+何种输入触发何种效果取决于纳米机器的当前配置,实际“对应关系”随配置不同而不同。玩家只有尝试才能弄清楚某种输入有什么效果。摄入新的一批纳米机器可以改变配置。此外,一次启用太多的输入会产生严重的负面效果。
  
-See the `nanomachines` ​section in the config for fine tuning to your preference.+请参看配置文件的`nanomachines`部分,以便根据您的喜好微调。
  
-To dispose of nanomachines,​ the player has to drink [[item:Grog]].+要废弃纳米机器,玩家需要饮用[[item:grog:​zh|蚀刻药水]]
  
-=== Crafting ​=== +===合成=== 
-Nanomachines are crafted using the following recipe: +纳米机器由以下配方合成: 
-  * 4 [[item:​materials#​Chamelium]] +  * 4 [[item:​materials#​变色材料|变色材料]] 
-  * 1 [[Wireless Network Card]] +  * 1 [[item:​wireless_network_card:​zh|无线网卡]] 
-  * 1 [[item:cpu|Tier 2 CPU]] +  * 1 [[item:cpu:zh|2CPU]] 
-  * 1 [[item:Grog]] +  * 1 [[item:grog:​zh|蚀刻药水]] 
-  * 1 [[item:ram|Tier RAM]] +  * 1 [[item:memory:zh|1级内存条]] 
-  * 1 [[block:Capacitor]]+  * 1 [[block:capacitor:​zh|电容器]]
  
-=== Programming ​=== +===编程=== 
-Programming the machines happens through wireless messages. The range nanomachines are able to receive messages from is only about two meters, though this can be circumvented easily by using a tablet to send the messages. However, the nanomachines do not check which device sent the messages they receive.+玩家可通过无线网络信息程控纳米机器。纳米机器的信息接收范围只有大约两米,通过平板电脑发送信息即可轻易克服此困难。然而,纳米机器不会检查它们收到的信息是由哪台设备发出的。
  
-Nanomachines react to a simple, proprietary protocol: each packet must consist of multiple parts, the first of which is the "​header"​ and must equal the string ​`nanomachines`. The second part must be the command name. Additional parts are parameters for the command. The following commands are available, formatted as `commandName(arg1, ...)`:+纳米机器使用一套简单的专有协议:向其发送的每个数据包都必须包含数个部分,第一部分是“信息头”,需要为字符串`nanomachines`。第二部分需要为命令名称。其余部分是命令所需的参数。可用命令在下方列出,格式为`命令名称(参数1, ...)`
  
-- `setResponsePort(port:​number)` - Set the port nanomachines should send response messages to, for commands that have a response. +- `setResponsePort(port:​number)` - 设定纳米机器发送响应信息所用的端口,对带有响应信息的命令生效。 ​  
-- `getPowerState()` - Request the currently stored and maximum stored energy of the nanomachines. +\\ 
-- `getHealth()` - Request the player'​s health state. +- `getPowerState()` - 获取纳米机器当前存储能量值以及能量存储上限。 ​  
-- `getHunger()` - Request the player'​s hunger state. +\\ 
-- `getAge()` - Request the player'​s age in seconds. +- `getHealth()` - 获取玩家的健康值。 ​  
-- `getName()` - Request the player'​s display name. +\\ 
-- `getExperience()` - Request the player'​s experience level. +- `getHunger()` - 获取玩家的饥饿值。 ​  
-- `getTotalInputCount()` - Request the total number of available inputs. +\\ 
-- `getSafeActiveInputs()` - Request the number of *safeactive inputs. +- `getAge()` - 获取玩家的年龄,单位为秒。 ​  
-- `getMaxActiveInputs()` - Request the number of *maximumactive inputs. +\\ 
-- `getInput(index:​number)` - Request the current state of the input with the specified index. +- `getName()` - 获取玩家的显示名称。 ​  
-- `setInput(index:​number,​ value:​boolean)` - Set the state of the input with the specified index to the specified value. +\\ 
-- `getActiveEffects()` - Request a list of active effects. Note that some effects may not show up in this list. +- `getExperience()` - 获取玩家的经验等级。 ​  
-- `saveConfiguration()` - Requires a set of nanomachines in the players inventory, will store the current configuration to it.+\\ 
 +- `getTotalInputCount()` - 获取可用输入总数。 ​  
 +\\ 
 +- `getSafeActiveInputs()` - 获取最大**安全**启用输入数。 ​  
 +\\ 
 +- `getMaxActiveInputs()` - 获取**最大**启用输入数。 ​  
 +\\ 
 +- `getInput(index:​number)` - 获取指定索引号对应输入的当前状态。 ​  
 +\\ 
 +- `setInput(index:​number,​ value:​boolean)` - 将指定索引号对应输入的状态设定为指定值。 ​  
 +\\ 
 +- `getActiveEffects()` - 获取生效的效果列表。请注意一些效果可能不会在列表中出现。 ​  
 +\\ 
 +- `saveConfiguration()` - 玩家物品栏中需要有一份纳米机器,本命令会将当前配置存储到其中。 ​  
 +\\
  
-For example, in OpenOS:+例如,在OpenOS中:
  
-- `component.modem.broadcast(1,​ "​nanomachines",​ "​setInput",​ 1, true)` ​will enable the first input. +- `component.modem.broadcast(1,​ "​nanomachines",​ "​setInput",​ 1, true)`将会启用第一个输入。 
-- `component.modem.broadcast(1,​ "​nanomachines",​ "​getHealth"​)` ​will get the player'​s health info.+- `component.modem.broadcast(1,​ "​nanomachines",​ "​getHealth"​)`将会获取玩家的健康值信息。
  
-=== See also === +===另请参见=== 
-[[http://​youtu.be/​gl3zGcTh67w |Nanomachines Preview]] (slightly outdated)+[[http://​youtu.be/​gl3zGcTh67w |纳米机器预览]](英文,可能略微过时)
  
 目录 目录
 ----------- -----------
 {{page>​item:​contents:​zh&​noheader&​noeditbutton&​nouser&​nofooter}} {{page>​item:​contents:​zh&​noheader&​noeditbutton&​nouser&​nofooter}}