.mkshell
Command to make shell: each 1 of energy gives 10 of shell, up to 100 per cycle.
Facts
- Address
- 822
- Name
.mkshell- Kind
- Command: the bot writes it and the engine reads it and usually consumes it
- Group
- Defenses
- Written by
- Your DNA.
- Read by
- The engine, in the actions phase of the same cycle: makes up to 100 shell (or takes it apart, if negative) and charges 1 energy per 10, plus a surcharge that goes to waste (parameter Shell).
- Cleared
- The engine, after making. With energy at 0 or less, the command stays written without being carried out.
- Range
- −32000 to 32000; at most 100 per cycle are used in each direction
- Mutations
- picked as a store target
Write how much shell you want to add this cycle. The engine makes it at the end of the cycle, charges 1 energy for every 10 of shell and sets the command to 0, so you have to write it again every cycle you want to keep making it. More than 100 per cycle is not possible: a 500 makes 100.
A negative number takes shell apart, but note: taking apart also costs energy, it does not give it back. With -50 you lose 50 of shell and 5 of energy. The simulation's transaction cost is also charged, which ends up as waste; in a multicellular bot (.multi) the part you pay in energy is divided by the number of ties plus one.
If energy is 0 or less, the command is not run and is not cleared either: it stays written until there is energy.
The result is read in .shell.
' keep 300 of shell when there is energy to spare
cond
*.shell 300 <
*.nrg 1000 >
start
100 .mkshell store
stop