Difference between revisions of "AI Craftapalooza Machines"
Jump to navigation
Jump to search
Troylaurin (talk | contribs) |
Troylaurin (talk | contribs) |
||
(8 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
===Machine scripts=== | ===Machine scripts=== | ||
− | + | ====Oven (1)==== | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
(pic) | (pic) | ||
− | |||
{| class="wikitable" | {| class="wikitable" | ||
!Name | !Name | ||
Line 78: | Line 71: | ||
tier = global.int.get("craft_tier:2.1") | tier = global.int.get("craft_tier:2.1") | ||
count = global.double.get("craft_count:2.1") | count = global.double.get("craft_count:2.1") | ||
− | gotoif(99, tier < 1 | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) |
executesync("craft 2:1:in") | executesync("craft 2:1:in") | ||
Line 235: | Line 228: | ||
}} | }} | ||
|} | |} | ||
− | + | ||
− | + | ====Assembler (2)==== | |
− | |||
(pic) | (pic) | ||
− | |||
{| class="wikitable" | {| class="wikitable" | ||
!Name | !Name | ||
Line 299: | Line 290: | ||
tier = global.int.get("craft_tier:2.2") | tier = global.int.get("craft_tier:2.2") | ||
count = global.double.get("craft_count:2.2") | count = global.double.get("craft_count:2.2") | ||
− | gotoif(99, tier < 1 | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) |
executesync("craft 2:2:in") | executesync("craft 2:2:in") | ||
Line 489: | Line 480: | ||
|} | |} | ||
− | + | ====Refiner (3)==== | |
− | |||
− | |||
(pic) | (pic) | ||
− | |||
{| class="wikitable" | {| class="wikitable" | ||
!Name | !Name | ||
Line 551: | Line 539: | ||
tier = global.int.get("craft_tier:2.3") | tier = global.int.get("craft_tier:2.3") | ||
count = global.double.get("craft_count:2.3") | count = global.double.get("craft_count:2.3") | ||
− | gotoif(99, tier < 1 | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) |
executesync("craft 2:3:in") | executesync("craft 2:3:in") | ||
Line 737: | Line 725: | ||
end: waituntil(count("ring", tier) >= rings) | end: waituntil(count("ring", tier) >= rings) | ||
wait(0.0) | wait(0.0) | ||
+ | }} | ||
|} | |} | ||
− | + | ====Crusher (4)==== | |
− | |||
− | |||
(pic) | (pic) | ||
− | |||
{| class="wikitable" | {| class="wikitable" | ||
!Name | !Name | ||
Line 789: | Line 775: | ||
AAANZmFjdG9yeS5jcmFmdAhjb25zdGFudAQPbWFjaGluZS5jcnVzaGVyDWxvY2FsLmludC5nZXQIY29u | AAANZmFjdG9yeS5jcmFmdAhjb25zdGFudAQPbWFjaGluZS5jcnVzaGVyDWxvY2FsLmludC5nZXQIY29u | ||
c3RhbnQEBHRpZXIQbG9jYWwuZG91YmxlLmdldAhjb25zdGFudAQFY291bnQ= | c3RhbnQEBHRpZXIQbG9jYWwuZG91YmxlLmdldAhjb25zdGFudAQFY291bnQ= | ||
− | src= | + | |src= |
; Crusher | ; Crusher | ||
:global double craft_inventory | :global double craft_inventory | ||
Line 799: | Line 785: | ||
tier = global.int.get("craft_tier:2.4") | tier = global.int.get("craft_tier:2.4") | ||
count = global.double.get("craft_count:2.4") | count = global.double.get("craft_count:2.4") | ||
− | gotoif(99, tier < 1 | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) |
motors = count * floor((22211111111.0 / (10.0 ^ i2d(tier))) % 10.0) | motors = count * floor((22211111111.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
Line 897: | Line 883: | ||
|} | |} | ||
− | + | ====Cutter (5)==== | |
− | |||
− | |||
(pic) | (pic) | ||
− | |||
{| class="wikitable" | {| class="wikitable" | ||
!Name | !Name | ||
Line 962: | Line 945: | ||
tier = global.int.get("craft_tier:2.5") | tier = global.int.get("craft_tier:2.5") | ||
count = global.double.get("craft_count:2.5") | count = global.double.get("craft_count:2.5") | ||
− | gotoif(99, tier < 1 | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) |
executesync("craft 2:5:in") | executesync("craft 2:5:in") | ||
Line 1,110: | Line 1,093: | ||
tier = global.int.get("craft_tier:2.5") | tier = global.int.get("craft_tier:2.5") | ||
count = global.double.get("craft_count:2.5") | count = global.double.get("craft_count:2.5") | ||
− | gotoif(99, tier < 1 | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) |
; blocks = count * floor((64400000001.0 / (10.0 ^ i2d(tier))) % 10.0) | ; blocks = count * floor((64400000001.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
Line 1,129: | Line 1,112: | ||
|} | |} | ||
− | + | ====Presser (6)==== | |
− | |||
− | |||
(pic) | (pic) | ||
− | |||
{| class="wikitable" | {| class="wikitable" | ||
!Name | !Name | ||
Line 1,204: | Line 1,184: | ||
tier = global.int.get("craft_tier:2.6") | tier = global.int.get("craft_tier:2.6") | ||
count = global.double.get("craft_count:2.6") | count = global.double.get("craft_count:2.6") | ||
− | gotoif(99, tier < 1 | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) |
executesync("craft 2:6:in") | executesync("craft 2:6:in") | ||
Line 1,230: | Line 1,210: | ||
|- | |- | ||
− | | | + | |craft 2:6:in |
− | | | + | |22 |
|{{AIScript | |{{AIScript | ||
|code= | |code= | ||
− | |||
− | |||
DGNyYWZ0IDI6NjppbgAAAAAAAAAAFgAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2Jh | DGNyYWZ0IDI6NjppbgAAAAAAAAAAFgAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2Jh | ||
bC5pbnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuNhBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50 | bC5pbnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuNhBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50 | ||
Line 1,317: | Line 1,295: | ||
executesync("craft 3:1") | executesync("craft 3:1") | ||
− | gotoif(99, global.int.get("craft_status") > 199 | + | gotoif(99, global.int.get("craft_status") > 199 {{!}} tier > 1) |
; Tier 1 has to buy hammers! | ; Tier 1 has to buy hammers! | ||
click(vec(0.96 * i2d(width()), 0.49 * i2d(height()))) | click(vec(0.96 * i2d(width()), 0.49 * i2d(height()))) | ||
Line 1,326: | Line 1,304: | ||
|} | |} | ||
− | + | ====Mixer (7)==== | |
− | |||
− | |||
(pic) | (pic) | ||
− | |||
{| class="wikitable" | {| class="wikitable" | ||
!Name | !Name | ||
!Lines | !Lines | ||
!Code | !Code | ||
− | |||
− | |||
|- | |- | ||
− | | | + | |craft 2:7 |
− | | | + | |14 |
− | + | |{{AIScript | |
− | | | + | |code= |
− | + | CWNyYWZ0IDI6NwAAAAAAAAAADgAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2JhbC5p | |
− | + | bnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuNxBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50BAVj | |
− | + | b3VudBFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfY291bnQ6Mi43DmdlbmVyaWMuZ290 | |
− | + | b2lmCGNvbnN0YW50AmMAAAAPY29tcGFyaXNvbi5ib29sD2NvbXBhcmlzb24uYm9vbA9jb21wYXJpc29u | |
− | + | LmJvb2wOY29tcGFyaXNvbi5pbnQNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllcghjb25zdGFudAQB | |
+ | PAhjb25zdGFudAIBAAAACGNvbnN0YW50BAF8DmNvbXBhcmlzb24uaW50DWxvY2FsLmludC5nZXQIY29u | ||
+ | c3RhbnQEBHRpZXIIY29uc3RhbnQEAT4IY29uc3RhbnQCCgAAAAhjb25zdGFudAQBfBFjb21wYXJpc29u | ||
+ | LmRvdWJsZRBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAVjb3VudAhjb25zdGFudAQBPAhjb25zdGFu | ||
+ | dAMAAAAAAADwPwhjb25zdGFudAQBfA5jb21wYXJpc29uLmludA5nbG9iYWwuaW50LmdldAhjb25zdGFu | ||
+ | dAQMY3JhZnRfc3RhdHVzCGNvbnN0YW50BAE+CGNvbnN0YW50AscAAAATZ2VuZXJpYy5leGVjdXRlc3lu | ||
+ | Ywhjb25zdGFudAQMY3JhZnQgMjo3OmluDmdsb2JhbC5pbnQuc2V0CGNvbnN0YW50BA5jcmFmdF90aWVy | ||
+ | OjMuMw1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyEWdsb2JhbC5kb3VibGUuc2V0CGNvbnN0YW50 | ||
+ | BA9jcmFmdF9jb3VudDozLjMRYXJpdGhtZXRpYy5kb3VibGURYXJpdGhtZXRpYy5kb3VibGUQbG9jYWwu | ||
+ | ZG91YmxlLmdldAhjb25zdGFudAQFY291bnQIY29uc3RhbnQEASoMZG91YmxlLmZsb29yEWFyaXRobWV0 | ||
+ | aWMuZG91YmxlEWFyaXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAApshFCy9CCGNvbnN0YW50BAEvEWFy | ||
+ | aXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAAAAAAACRACGNvbnN0YW50BANwb3cDaTJkDWxvY2FsLmlu | ||
+ | dC5nZXQIY29uc3RhbnQEBHRpZXIIY29uc3RhbnQEA21vZAhjb25zdGFudAMAAAAAAAAkQAhjb25zdGFu | ||
+ | dAQBLRFhcml0aG1ldGljLmRvdWJsZRFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52 | ||
+ | ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3RvcnkuaXRlbXMuY291bnQIY29uc3RhbnQEC3BsYXRlLmRlbnNl | ||
+ | DWxvY2FsLmludC5nZXQIY29uc3R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vdWJsZRFh | ||
+ | cml0aG1ldGljLmRvdWJsZRBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAVjb3VudAhjb25zdGFudAQB | ||
+ | Kghjb25zdGFudAMAAAAAAAAAQAhjb25zdGFudAQBLRFhcml0aG1ldGljLmRvdWJsZRFnbG9iYWwuZG91 | ||
+ | YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3RvcnkuaXRlbXMu | ||
+ | Y291bnQIY29uc3RhbnQEBW1vdG9yDWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXITZ2VuZXJpYy5l | ||
+ | eGVjdXRlc3luYwhjb25zdGFudAQJY3JhZnQgMzo4DWZhY3RvcnkuY3JhZnQIY29uc3RhbnQEDW1hY2hp | ||
+ | bmUubWl4ZXINbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0 | ||
+ | YW50BAVjb3VudA== | ||
+ | |src= | ||
+ | ; Mixer | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
− | + | tier = global.int.get("craft_tier:2.7") | |
− | + | count = global.double.get("craft_count:2.7") | |
− | + | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) | |
− | ( | + | |
− | + | executesync("craft 2:7:in") | |
− | + | ||
− | + | ;denseplates = count * floor((66666554451.0 / (10.0 ^ i2d(tier))) % 10.0) | |
− | + | global.int.set("craft_tier:3.3", tier) | |
− | + | global.double.set("craft_count:3.3", count * floor((66666554451.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("plate.dense", tier)) | |
− | + | executesync("craft 3:3") | |
+ | |||
+ | ;pumps = count * floor((33333221111.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.9", tier) | ||
+ | global.double.set("craft_count:3.9", count * floor((33333221111.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("pump", tier)) | ||
+ | executesync("craft 3:9") | ||
+ | |||
+ | ;motors = count * 2 | ||
+ | global.int.set("craft_tier:3.8", tier) | ||
+ | global.double.set("craft_count:3.8", count * 2.0 - craft_inventory * count("motor", tier)) | ||
+ | executesync("craft 3:8") | ||
+ | |||
+ | craft("machine.mixer", tier, count) | ||
+ | }} | ||
|- | |- | ||
− | | | + | |craft 2:7:in |
− | | | + | |18 |
− | ( | + | |{{AIScript |
− | + | |code= | |
− | + | DGNyYWZ0IDI6NzppbgAAAAAAAAAAEgAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2Jh | |
− | + | bC5pbnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuNxBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50 | |
− | + | BAVjb3VudBFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfY291bnQ6Mi43EGxvY2FsLmRv | |
− | + | dWJsZS5zZXQIY29uc3RhbnQEBmluZ290cwhjb25zdGFudAMAAAAAAAAAAA5nbG9iYWwuaW50LnNldAhj | |
− | + | b25zdGFudAQQY3JhZnRfdGllcjppbmdvdA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyEWdsb2Jh | |
+ | bC5kb3VibGUuc2V0CGNvbnN0YW50BBFjcmFmdF9jb3VudDppbmdvdBFhcml0aG1ldGljLmRvdWJsZRBs | ||
+ | b2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAZpbmdvdHMIY29uc3RhbnQEAS0TZmFjdG9yeS5pdGVtcy5j | ||
+ | b3VudAhjb25zdGFudAQFaW5nb3QNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchNnZW5lcmljLmV4 | ||
+ | ZWN1dGVzeW5jCGNvbnN0YW50BAtjcmFmdCBpbmdvdA5nZW5lcmljLmdvdG9pZghjb25zdGFudAJjAAAA | ||
+ | DmNvbXBhcml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bC5kb3VibGUuZ2V0CGNvbnN0YW50BA9jcmFmdF9pbnZlbnRvcnkIY29uc3RhbnQEASoTZmFjdG9y | ||
+ | eS5pdGVtcy5jb3VudAhjb25zdGFudAQEY2hpcA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAhjaGlwdGll | ||
+ | chNnZW5lcmljLmV4ZWN1dGVzeW5jCGNvbnN0YW50BAljcmFmdCAzOjE= | ||
+ | |src= | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | :local double ingots | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.7") | ||
+ | count = global.double.get("craft_count:2.7") | ||
+ | |||
+ | ; Ingots | ||
+ | ingots = 0.0 ; TODO | ||
+ | global.int.set("craft_tier:ingot", tier) | ||
+ | global.double.set("craft_count:ingot", ingots - count("ingot", tier)) | ||
+ | ;global.int.set("craft_verify:ingot", 1) | ||
+ | executesync("craft ingot") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Lower tier inputs | ||
+ | global.int.set("craft_tier:2.7", tier - 1) | ||
+ | global.double.set("craft_count:2.7", count - craft_inventory * count("machine.mixer", tier - 1)) | ||
+ | executesync("craft 2:7") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Restore state for this tier | ||
+ | global.int.set("craft_tier:2.7", tier) | ||
+ | global.double.set("craft_count:2.7", count) | ||
+ | ; chips | ||
+ | :local double chips | ||
+ | chips = count * floor((33333221111.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | :local int chiptier | ||
+ | chiptier = d2i(floor((44322221111.0 / (10.0 ^ i2d(tier))) % 10.0)) | ||
+ | global.int.set("craft_tier:3.1", chiptier) | ||
+ | global.double.set("craft_count:3.1", chips - craft_inventory * count("chip", chiptier)) | ||
+ | executesync("craft 3:1") | ||
+ | }} | ||
+ | |} | ||
+ | |||
+ | ====Belt (8)==== | ||
+ | (pic) | ||
+ | {| class="wikitable" | ||
+ | !Name | ||
+ | !Lines | ||
+ | !Code | ||
+ | |- | ||
+ | |craft 2:8 | ||
+ | |14 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | CWNyYWZ0IDI6OAAAAAAAAAAADgAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2JhbC5p | ||
+ | bnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuOBBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50BAVj | ||
+ | b3VudBFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfY291bnQ6Mi44DmdlbmVyaWMuZ290 | ||
+ | b2lmCGNvbnN0YW50AmMAAAAPY29tcGFyaXNvbi5ib29sD2NvbXBhcmlzb24uYm9vbA9jb21wYXJpc29u | ||
+ | LmJvb2wOY29tcGFyaXNvbi5pbnQNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllcghjb25zdGFudAQB | ||
+ | PAhjb25zdGFudAIBAAAACGNvbnN0YW50BAF8DmNvbXBhcmlzb24uaW50DWxvY2FsLmludC5nZXQIY29u | ||
+ | c3RhbnQEBHRpZXIIY29uc3RhbnQEAT4IY29uc3RhbnQCCgAAAAhjb25zdGFudAQBfBFjb21wYXJpc29u | ||
+ | LmRvdWJsZRBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAVjb3VudAhjb25zdGFudAQBPAhjb25zdGFu | ||
+ | dAMAAAAAAADwPwhjb25zdGFudAQBfA5jb21wYXJpc29uLmludA5nbG9iYWwuaW50LmdldAhjb25zdGFu | ||
+ | dAQMY3JhZnRfc3RhdHVzCGNvbnN0YW50BAE+CGNvbnN0YW50AscAAAATZ2VuZXJpYy5leGVjdXRlc3lu | ||
+ | Ywhjb25zdGFudAQMY3JhZnQgMjo4OmluDmdsb2JhbC5pbnQuc2V0CGNvbnN0YW50BA5jcmFmdF90aWVy | ||
+ | OjMuNg1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyEWdsb2JhbC5kb3VibGUuc2V0CGNvbnN0YW50 | ||
+ | BA9jcmFmdF9jb3VudDozLjYRYXJpdGhtZXRpYy5kb3VibGURYXJpdGhtZXRpYy5kb3VibGUQbG9jYWwu | ||
+ | ZG91YmxlLmdldAhjb25zdGFudAQFY291bnQIY29uc3RhbnQEASoMZG91YmxlLmZsb29yEWFyaXRobWV0 | ||
+ | aWMuZG91YmxlEWFyaXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAAHhmb3ilCCGNvbnN0YW50BAEvEWFy | ||
+ | aXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAAAAAAACRACGNvbnN0YW50BANwb3cDaTJkDWxvY2FsLmlu | ||
+ | dC5nZXQIY29uc3RhbnQEBHRpZXIIY29uc3RhbnQEA21vZAhjb25zdGFudAMAAAAAAAAkQAhjb25zdGFu | ||
+ | dAQBLRFhcml0aG1ldGljLmRvdWJsZRFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52 | ||
+ | ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3RvcnkuaXRlbXMuY291bnQIY29uc3RhbnQED2NhYmxlLmluc3Vs | ||
+ | YXRlZA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyE2dlbmVyaWMuZXhlY3V0ZXN5bmMIY29uc3Rh | ||
+ | bnQECWNyYWZ0IDM6Ng5nbG9iYWwuaW50LnNldAhjb25zdGFudAQOY3JhZnRfdGllcjozLjgNbG9jYWwu | ||
+ | aW50LmdldAhjb25zdGFudAQEdGllchFnbG9iYWwuZG91YmxlLnNldAhjb25zdGFudAQPY3JhZnRfY291 | ||
+ | bnQ6My44EWFyaXRobWV0aWMuZG91YmxlEWFyaXRobWV0aWMuZG91YmxlEGxvY2FsLmRvdWJsZS5nZXQI | ||
+ | Y29uc3RhbnQEBWNvdW50CGNvbnN0YW50BAEqDGRvdWJsZS5mbG9vchFhcml0aG1ldGljLmRvdWJsZRFh | ||
+ | c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zdGFudAQBLRFhcml0aG1ldGljLmRvdWJsZRFn | ||
+ | bG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3Rv | ||
+ | cnkuaXRlbXMuY291bnQIY29uc3RhbnQEDHBsYXRlLnJ1YmJlcg1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50 | ||
+ | BAR0aWVyCGNvbnN0YW50BAdwcmVzc2VyEWdlbmVyaWMud2FpdHdoaWxlFmZhY3RvcnkubWFjaGluZS5h | ||
+ | Y3RpdmUIY29uc3RhbnQEB3ByZXNzZXINZmFjdG9yeS5jcmFmdAhjb25zdGFudAQVbWFjaGluZS50cmFu | ||
+ | c3BvcnRiZWx0DWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIQbG9jYWwuZG91YmxlLmdldAhjb25z | ||
+ | dGFudAQFY291bnQ= | ||
+ | |src= | ||
+ | ; Belt | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.8") | ||
+ | count = global.double.get("craft_count:2.8") | ||
+ | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) | ||
+ | |||
+ | executesync("craft 2:8:in") | ||
+ | |||
+ | ;insulatedcable = count * floor((55554444431.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.6", tier) | ||
+ | global.double.set("craft_count:3.6", count * floor((55554444431.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("cable.insulated", tier)) | ||
+ | executesync("craft 3:6") | ||
+ | |||
+ | ;motors = count * floor((44443333331.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.8", tier) | ||
+ | global.double.set("craft_count:3.8", count * floor((44443333331.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("motor", tier)) | ||
+ | executesync("craft 3:8") | ||
+ | |||
+ | ;rubberplate = count * floor((55554000001.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | waitwhile(active("presser")) | ||
+ | produce("rubber", tier, count * floor((55554000001.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("plate.rubber", tier), "presser") | ||
+ | waitwhile(active("presser")) | ||
+ | |||
+ | craft("machine.transportbelt", tier, count) | ||
+ | }} | ||
+ | |||
+ | |- | ||
+ | |craft 2:8:in | ||
+ | |18 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | DGNyYWZ0IDI6ODppbgAAAAAAAAAAEgAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2Jh | ||
+ | bC5pbnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuOBBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50 | ||
+ | BAVjb3VudBFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfY291bnQ6Mi44EGxvY2FsLmRv | ||
+ | dWJsZS5zZXQIY29uc3RhbnQEBmluZ290cwhjb25zdGFudAMAAAAAAAAAAA5nbG9iYWwuaW50LnNldAhj | ||
+ | b25zdGFudAQQY3JhZnRfdGllcjppbmdvdA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyEWdsb2Jh | ||
+ | bC5kb3VibGUuc2V0CGNvbnN0YW50BBFjcmFmdF9jb3VudDppbmdvdBFhcml0aG1ldGljLmRvdWJsZRBs | ||
+ | b2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAZpbmdvdHMIY29uc3RhbnQEAS0TZmFjdG9yeS5pdGVtcy5j | ||
+ | b3VudAhjb25zdGFudAQFaW5nb3QNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchNnZW5lcmljLmV4 | ||
+ | ZWN1dGVzeW5jCGNvbnN0YW50BAtjcmFmdCBpbmdvdA5nZW5lcmljLmdvdG9pZghjb25zdGFudAJjAAAA | ||
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| b3VibGURZ2xvYmFsLmRvdWJsZS5nZXQIY29uc3RhbnQED2NyYWZ0X2ludmVudG9yeQhjb25zdGFudAQB | ||
+ | KhNmYWN0b3J5Lml0ZW1zLmNvdW50CGNvbnN0YW50BARjaGlwDWxvY2FsLmludC5nZXQIY29uc3RhbnQE | ||
+ | CGNoaXB0aWVyE2dlbmVyaWMuZXhlY3V0ZXN5bmMIY29uc3RhbnQECWNyYWZ0IDM6MQ== | ||
+ | |src= | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | :local double ingots | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.8") | ||
+ | count = global.double.get("craft_count:2.8") | ||
+ | |||
+ | ; Ingots | ||
+ | ingots = 0.0 ; TODO | ||
+ | global.int.set("craft_tier:ingot", tier) | ||
+ | global.double.set("craft_count:ingot", ingots - count("ingot", tier)) | ||
+ | ;global.int.set("craft_verify:ingot", 1) | ||
+ | executesync("craft ingot") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Lower tier inputs | ||
+ | global.int.set("craft_tier:2.8", tier - 1) | ||
+ | global.double.set("craft_count:2.8", count - craft_inventory * count("machine.transportbelt", tier - 1)) | ||
+ | executesync("craft 2:8") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Restore state for this tier | ||
+ | global.int.set("craft_tier:2.8", tier) | ||
+ | global.double.set("craft_count:2.8", count) | ||
+ | |||
+ | ; chips | ||
+ | :local double chips | ||
+ | chips = count * floor((55554440001.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | :local int chiptier | ||
+ | chiptier = d2i(floor((44332210001.0 / (10.0 ^ i2d(tier))) % 10.0)) | ||
+ | global.int.set("craft_tier:3.1", chiptier) | ||
+ | global.double.set("craft_count:3.1", chips - craft_inventory * count("chip", chiptier)) | ||
+ | executesync("craft 3:1") | ||
+ | }} | ||
+ | |} | ||
+ | |||
+ | ====Shaper (9)==== | ||
+ | (pic) | ||
+ | {| class="wikitable" | ||
+ | !Name | ||
+ | !Lines | ||
+ | !Code | ||
+ | |- | ||
+ | |craft 2:9 | ||
+ | |15 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | CWNyYWZ0IDI6OQAAAAAAAAAADwAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2JhbC5p | ||
+ | bnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuORBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50BAVj | ||
+ | b3VudBFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfY291bnQ6Mi45DmdlbmVyaWMuZ290 | ||
+ | b2lmCGNvbnN0YW50AmMAAAAPY29tcGFyaXNvbi5ib29sD2NvbXBhcmlzb24uYm9vbA9jb21wYXJpc29u | ||
+ | LmJvb2wOY29tcGFyaXNvbi5pbnQNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllcghjb25zdGFudAQB | ||
+ | PAhjb25zdGFudAIBAAAACGNvbnN0YW50BAF8DmNvbXBhcmlzb24uaW50DWxvY2FsLmludC5nZXQIY29u | ||
+ | c3RhbnQEBHRpZXIIY29uc3RhbnQEAT4IY29uc3RhbnQCCgAAAAhjb25zdGFudAQBfBFjb21wYXJpc29u | ||
+ | LmRvdWJsZRBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAVjb3VudAhjb25zdGFudAQBPAhjb25zdGFu | ||
+ | dAMAAAAAAADwPwhjb25zdGFudAQBfA5jb21wYXJpc29uLmludA5nbG9iYWwuaW50LmdldAhjb25zdGFu | ||
+ | dAQMY3JhZnRfc3RhdHVzCGNvbnN0YW50BAE+CGNvbnN0YW50AscAAAATZ2VuZXJpYy5leGVjdXRlc3lu | ||
+ | Ywhjb25zdGFudAQMY3JhZnQgMjo5OmluDmdsb2JhbC5pbnQuc2V0CGNvbnN0YW50BA5jcmFmdF90aWVy | ||
+ | OjMuNg1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyEWdsb2JhbC5kb3VibGUuc2V0CGNvbnN0YW50 | ||
+ | BA9jcmFmdF9jb3VudDozLjYRYXJpdGhtZXRpYy5kb3VibGURYXJpdGhtZXRpYy5kb3VibGUQbG9jYWwu | ||
+ | ZG91YmxlLmdldAhjb25zdGFudAQFY291bnQIY29uc3RhbnQEASoMZG91YmxlLmZsb29yEWFyaXRobWV0 | ||
+ | aWMuZG91YmxlEWFyaXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAADpNEqSNCCGNvbnN0YW50BAEvEWFy | ||
+ | aXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAAAAAAACRACGNvbnN0YW50BANwb3cDaTJkDWxvY2FsLmlu | ||
+ | dC5nZXQIY29uc3RhbnQEBHRpZXIIY29uc3RhbnQEA21vZAhjb25zdGFudAMAAAAAAAAkQAhjb25zdGFu | ||
+ | dAQBLRFhcml0aG1ldGljLmRvdWJsZRFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52 | ||
+ | ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3RvcnkuaXRlbXMuY291bnQIY29uc3RhbnQED2NhYmxlLmluc3Vs | ||
+ | YXRlZA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyE2dlbmVyaWMuZXhlY3V0ZXN5bmMIY29uc3Rh | ||
+ | bnQECWNyYWZ0IDM6Ng5nbG9iYWwuaW50LnNldAhjb25zdGFudAQOY3JhZnRfdGllcjozLjgNbG9jYWwu | ||
+ | aW50LmdldAhjb25zdGFudAQEdGllchFnbG9iYWwuZG91YmxlLnNldAhjb25zdGFudAQPY3JhZnRfY291 | ||
+ | bnQ6My44EWFyaXRobWV0aWMuZG91YmxlEWFyaXRobWV0aWMuZG91YmxlEGxvY2FsLmRvdWJsZS5nZXQI | ||
+ | Y29uc3RhbnQEBWNvdW50CGNvbnN0YW50BAEqCGNvbnN0YW50AwAAAAAAAABACGNvbnN0YW50BAEtEWFy | ||
+ | aXRobWV0aWMuZG91YmxlEWdsb2JhbC5kb3VibGUuZ2V0CGNvbnN0YW50BA9jcmFmdF9pbnZlbnRvcnkI | ||
+ | Y29uc3RhbnQEASoTZmFjdG9yeS5pdGVtcy5jb3VudAhjb25zdGFudAQFbW90b3INbG9jYWwuaW50Lmdl | ||
+ | dAhjb25zdGFudAQEdGllchNnZW5lcmljLmV4ZWN1dGVzeW5jCGNvbnN0YW50BAljcmFmdCAzOjgOZ2xv | ||
+ | YmFsLmludC5zZXQIY29uc3RhbnQEEGNyYWZ0X3RpZXI6c2NyZXcNbG9jYWwuaW50LmdldAhjb25zdGFu | ||
+ | dAQEdGllchFnbG9iYWwuZG91YmxlLnNldAhjb25zdGFudAQRY3JhZnRfY291bnQ6c2NyZXcRYXJpdGht | ||
+ | ZXRpYy5kb3VibGURYXJpdGhtZXRpYy5kb3VibGUQbG9jYWwuZG91YmxlLmdldAhjb25zdGFudAQFY291 | ||
+ | bnQIY29uc3RhbnQEASoMZG91YmxlLmZsb29yEWFyaXRobWV0aWMuZG91YmxlEWFyaXRobWV0aWMuZG91 | ||
+ | YmxlCGNvbnN0YW50AwAADG1CCx9CCGNvbnN0YW50BAEvEWFyaXRobWV0aWMuZG91YmxlCGNvbnN0YW50 | ||
+ | AwAAAAAAACRACGNvbnN0YW50BANwb3cDaTJkDWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIIY29u | ||
+ | c3RhbnQEA21vZAhjb25zdGFudAMAAAAAAAAkQAhjb25zdGFudAQBLRFhcml0aG1ldGljLmRvdWJsZRFn | ||
+ | bG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3Rv | ||
+ | cnkuaXRlbXMuY291bnQIY29uc3RhbnQEBXNjcmV3DWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIT | ||
+ | Z2VuZXJpYy5leGVjdXRlc3luYwhjb25zdGFudAQQY3JhZnQgcGFydDpzY3JldxNnZW5lcmljLmV4ZWN1 | ||
+ | dGVzeW5jCGNvbnN0YW50BBBjcmFmdCAyOjk6cGxhdGVzDWZhY3RvcnkuY3JhZnQIY29uc3RhbnQEDm1h | ||
+ | Y2hpbmUuc2hhcGVyDWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIQbG9jYWwuZG91YmxlLmdldAhj | ||
+ | b25zdGFudAQFY291bnQ= | ||
+ | |src= | ||
+ | ; Shaper | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.9") | ||
+ | count = global.double.get("craft_count:2.9") | ||
+ | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) | ||
+ | |||
+ | executesync("craft 2:9:in") | ||
+ | |||
+ | ;insulatedcable = count * floor((42222111111.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.6", tier) | ||
+ | global.double.set("craft_count:3.6", count * floor((42222111111.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("cable.insulated", tier)) | ||
+ | executesync("craft 3:6") | ||
+ | |||
+ | ;motors = count * 2.0 | ||
+ | global.int.set("craft_tier:3.8", tier) | ||
+ | global.double.set("craft_count:3.8", count * 2.0 - craft_inventory * count("motor", tier)) | ||
+ | executesync("craft 3:8") | ||
+ | |||
+ | ;screw = count * floor((33333222211.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:screw", tier) | ||
+ | global.double.set("craft_count:screw", count * floor((33333222211.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("screw", tier)) | ||
+ | executesync("craft part:screw") | ||
+ | |||
+ | executesync("craft 2:9:plates") | ||
+ | |||
+ | craft("machine.shaper", tier, count) | ||
+ | }} | ||
+ | |||
+ | |- | ||
+ | |craft 2:9:in | ||
+ | |13 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | DGNyYWZ0IDI6OTppbgAAAAAAAAAADQAAAA1sb2NhbC5pbnQuc2V0CGNvbnN0YW50BAR0aWVyDmdsb2Jh | ||
+ | bC5pbnQuZ2V0CGNvbnN0YW50BA5jcmFmdF90aWVyOjIuORBsb2NhbC5kb3VibGUuc2V0CGNvbnN0YW50 | ||
+ | BAVjb3VudBFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfY291bnQ6Mi45EGxvY2FsLmRv | ||
+ | dWJsZS5zZXQIY29uc3RhbnQEBmluZ290cwhjb25zdGFudAMAAAAAAAAAAA5nbG9iYWwuaW50LnNldAhj | ||
+ | b25zdGFudAQQY3JhZnRfdGllcjppbmdvdA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyEWdsb2Jh | ||
+ | bC5kb3VibGUuc2V0CGNvbnN0YW50BBFjcmFmdF9jb3VudDppbmdvdBFhcml0aG1ldGljLmRvdWJsZRBs | ||
+ | b2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAZpbmdvdHMIY29uc3RhbnQEAS0TZmFjdG9yeS5pdGVtcy5j | ||
+ | b3VudAhjb25zdGFudAQFaW5nb3QNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchNnZW5lcmljLmV4 | ||
+ | ZWN1dGVzeW5jCGNvbnN0YW50BAtjcmFmdCBpbmdvdA5nZW5lcmljLmdvdG9pZghjb25zdGFudAJjAAAA | ||
+ | DmNvbXBhcmlzb24uaW50Dmdsb2JhbC5pbnQuZ2V0CGNvbnN0YW50BAxjcmFmdF9zdGF0dXMIY29uc3Rh | ||
+ | bnQEAT4IY29uc3RhbnQCxwAAAA5nbG9iYWwuaW50LnNldAhjb25zdGFudAQOY3JhZnRfdGllcjoyLjkO | ||
+ | YXJpdGhtZXRpYy5pbnQNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllcghjb25zdGFudAQBLQhjb25z | ||
+ | dGFudAIBAAAAEWdsb2JhbC5kb3VibGUuc2V0CGNvbnN0YW50BA9jcmFmdF9jb3VudDoyLjkRYXJpdGht | ||
+ | ZXRpYy5kb3VibGUQbG9jYWwuZG91YmxlLmdldAhjb25zdGFudAQFY291bnQIY29uc3RhbnQEAS0RYXJp | ||
+ | dGhtZXRpYy5kb3VibGURZ2xvYmFsLmRvdWJsZS5nZXQIY29uc3RhbnQED2NyYWZ0X2ludmVudG9yeQhj | ||
+ | b25zdGFudAQBKhNmYWN0b3J5Lml0ZW1zLmNvdW50CGNvbnN0YW50BA5tYWNoaW5lLnNoYXBlcg5hcml0 | ||
+ | aG1ldGljLmludA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyCGNvbnN0YW50BAEtCGNvbnN0YW50 | ||
+ | AgEAAAATZ2VuZXJpYy5leGVjdXRlc3luYwhjb25zdGFudAQJY3JhZnQgMjo5DmdlbmVyaWMuZ290b2lm | ||
+ | CGNvbnN0YW50AmMAAAAOY29tcGFyaXNvbi5pbnQOZ2xvYmFsLmludC5nZXQIY29uc3RhbnQEDGNyYWZ0 | ||
+ | X3N0YXR1cwhjb25zdGFudAQBPghjb25zdGFudALHAAAADmdsb2JhbC5pbnQuc2V0CGNvbnN0YW50BA5j | ||
+ | cmFmdF90aWVyOjIuOQ1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyEWdsb2JhbC5kb3VibGUuc2V0 | ||
+ | CGNvbnN0YW50BA9jcmFmdF9jb3VudDoyLjkQbG9jYWwuZG91YmxlLmdldAhjb25zdGFudAQFY291bnQ= | ||
+ | |src= | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | :local double ingots | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.9") | ||
+ | count = global.double.get("craft_count:2.9") | ||
+ | |||
+ | ; Ingots | ||
+ | ingots = 0.0 ; TODO | ||
+ | global.int.set("craft_tier:ingot", tier) | ||
+ | global.double.set("craft_count:ingot", ingots - count("ingot", tier)) | ||
+ | ;global.int.set("craft_verify:ingot", 1) | ||
+ | executesync("craft ingot") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Lower tier inputs | ||
+ | global.int.set("craft_tier:2.9", tier - 1) | ||
+ | global.double.set("craft_count:2.9", count - craft_inventory * count("machine.shaper", tier - 1)) | ||
+ | executesync("craft 2:9") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Restore state for this tier | ||
+ | global.int.set("craft_tier:2.9", tier) | ||
+ | global.double.set("craft_count:2.9", count) | ||
+ | }} | ||
+ | |||
+ | |- | ||
+ | |craft 2:9:plates | ||
+ | |18 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | EGNyYWZ0IDI6OTpwbGF0ZXMAAAAAAAAAABIAAAANbG9jYWwuaW50LnNldAhjb25zdGFudAQEdGllcg5n | ||
+ | bG9iYWwuaW50LmdldAhjb25zdGFudAQOY3JhZnRfdGllcjoyLjkQbG9jYWwuZG91YmxlLnNldAhjb25z | ||
+ | dGFudAQFY291bnQRZ2xvYmFsLmRvdWJsZS5nZXQIY29uc3RhbnQED2NyYWZ0X2NvdW50OjIuORBsb2Nh | ||
+ | bC5kb3VibGUuc2V0CGNvbnN0YW50BAZibG9ja3MRYXJpdGhtZXRpYy5kb3VibGUQbG9jYWwuZG91Ymxl | ||
+ | LmdldAhjb25zdGFudAQFY291bnQIY29uc3RhbnQEASoMZG91YmxlLmZsb29yEWFyaXRobWV0aWMuZG91 | ||
+ | YmxlEWFyaXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAAhsbQ1ShCCGNvbnN0YW50BAEvEWFyaXRobWV0 | ||
+ | aWMuZG91YmxlCGNvbnN0YW50AwAAAAAAACRACGNvbnN0YW50BANwb3cDaTJkDWxvY2FsLmludC5nZXQI | ||
+ | Y29uc3RhbnQEBHRpZXIIY29uc3RhbnQEA21vZAhjb25zdGFudAMAAAAAAAAkQA5nbG9iYWwuaW50LnNl | ||
+ | dAhjb25zdGFudAQOY3JhZnRfdGllcjozLjQNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchFnbG9i | ||
+ | YWwuZG91YmxlLnNldAhjb25zdGFudAQPY3JhZnRfY291bnQ6My40EWFyaXRobWV0aWMuZG91YmxlEGxv | ||
+ | Y2FsLmRvdWJsZS5nZXQIY29uc3RhbnQEBmJsb2Nrcwhjb25zdGFudAQBLRFhcml0aG1ldGljLmRvdWJs | ||
+ | ZRFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52ZW50b3J5CGNvbnN0YW50BAEqEWFy | ||
+ | aXRobWV0aWMuZG91YmxlE2ZhY3RvcnkuaXRlbXMuY291bnQIY29uc3RhbnQEBWJsb2NrDWxvY2FsLmlu | ||
+ | dC5nZXQIY29uc3RhbnQEBHRpZXIIY29uc3RhbnQEASsRYXJpdGhtZXRpYy5kb3VibGUKZG91YmxlLm1h | ||
+ | eAhjb25zdGFudAMAAAAAAAAAABFhcml0aG1ldGljLmRvdWJsZQNpMmQNbG9jYWwuaW50LmdldAhjb25z | ||
+ | dGFudAQEdGllcghjb25zdGFudAQBLQhjb25zdGFudAMAAAAAAAAiQAhjb25zdGFudAQBKhNmYWN0b3J5 | ||
+ | Lml0ZW1zLmNvdW50CGNvbnN0YW50BAtibG9jay5kZW5zZQ1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0 | ||
+ | aWVyE2dlbmVyaWMuZXhlY3V0ZXN5bmMIY29uc3RhbnQECWNyYWZ0IDM6NA5nZW5lcmljLmdvdG9pZghj | ||
+ | b25zdGFudAIMAAAADmNvbXBhcmlzb24uaW50DWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIIY29u | ||
+ | c3RhbnQEAj09CGNvbnN0YW50AgoAAAAOZ2xvYmFsLmludC5zZXQIY29uc3RhbnQEDmNyYWZ0X3RpZXI6 | ||
+ | My4yDWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIRZ2xvYmFs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QBLRFhcml0aG1ldGljLmRvdWJsZRFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRf | ||
+ | aW52ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3RvcnkuaXRlbXMuY291bnQIY29uc3RhbnQEC3BsYXRlLmRl | ||
+ | bnNlDWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXITZ2VuZXJpYy5leGVjdXRlc3luYwhjb25zdGFu | ||
+ | dAQJY3JhZnQgMzozEWdlbmVyaWMud2FpdHdoaWxlEWNvbXBhcmlzb24uZG91YmxlE2ZhY3RvcnkuaXRl | ||
+ | bXMuY291bnQIY29uc3RhbnQEC2Jsb2NrLmRlbnNlDWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXII | ||
+ | Y29uc3RhbnQEATwQbG9jYWwuZG91YmxlLmdldAhjb25zdGFudAQGYmxvY2tzDGdlbmVyaWMud2FpdAhj | ||
+ | b25zdGFudAMAAAAAAAAAAA== | ||
+ | |src= | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.9") | ||
+ | count = global.double.get("craft_count:2.9") | ||
+ | |||
+ | :local double blocks | ||
+ | blocks = count * floor((53333222211.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.4", tier) | ||
+ | global.double.set("craft_count:3.4", blocks - craft_inventory * (count("block", tier) + max(0.0, i2d(tier) - 9.0) * count("block.dense", tier))) | ||
+ | executesync("craft 3:4") | ||
+ | |||
+ | gotoif(t10, tier == 10) | ||
+ | |||
+ | ; plates = count * 4.0 | ||
+ | global.int.set("craft_tier:3.2", tier) | ||
+ | global.double.set("craft_count:3.2", count * 4.0 - craft_inventory * count("plate", tier)) | ||
+ | executesync("craft 3:2") | ||
+ | |||
+ | goto(99) | ||
+ | |||
+ | t10: waitwhile(active("boiler")) | ||
+ | produce("block", tier, blocks, "boiler") | ||
+ | |||
+ | global.int.set("craft_tier:3.3", tier) | ||
+ | global.double.set("craft_count:3.3", count * 4.0 - craft_inventory * count("plate.dense", tier)) | ||
+ | executesync("craft 3:3") | ||
+ | |||
+ | waitwhile(count("block.dense", tier) < blocks) | ||
+ | wait(0.0) | ||
+ | }} | ||
+ | |} | ||
+ | |||
+ | ====Boiler (10)==== | ||
+ | (pic) | ||
+ | {| class="wikitable" | ||
+ | !Name | ||
+ | !Lines | ||
+ | !Code | ||
+ | |||
+ | |- | ||
+ | |craft 2:10 | ||
+ | |18 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | CmNyYWZ0IDI6MTAAAAAAAAAAABIAAAANbG9jYWwuaW50LnNldAhjb25zdGFudAQEdGllcg5nbG9iYWwu | ||
+ | aW50LmdldAhjb25zdGFudAQPY3JhZnRfdGllcjoyLjEwEGxvY2FsLmRvdWJsZS5zZXQIY29uc3RhbnQE | ||
+ | BWNvdW50EWdsb2JhbC5kb3VibGUuZ2V0CGNvbnN0YW50BBBjcmFmdF9jb3VudDoyLjEwDmdlbmVyaWMu | ||
+ | Z290b2lmCGNvbnN0YW50AmMAAAAPY29tcGFyaXNvbi5ib29sD2NvbXBhcmlzb24uYm9vbA9jb21wYXJp | ||
+ | c29uLmJvb2wOY29tcGFyaXNvbi5pbnQNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllcghjb25zdGFu | ||
+ | dAQBPAhjb25zdGFudAIBAAAACGNvbnN0YW50BAF8DmNvbXBhcmlzb24uaW50DWxvY2FsLmludC5nZXQI | ||
+ | Y29uc3RhbnQEBHRpZXIIY29uc3RhbnQEAT4IY29uc3RhbnQCCgAAAAhjb25zdGFudAQBfBFjb21wYXJp | ||
+ | c29uLmRvdWJsZRBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50BAVjb3VudAhjb25zdGFudAQBPAhjb25z | ||
+ | dGFudAMAAAAAAADwPwhjb25zdGFudAQBfA5jb21wYXJpc29uLmludA5nbG9iYWwuaW50LmdldAhjb25z | ||
+ | dGFudAQMY3JhZnRfc3RhdHVzCGNvbnN0YW50BAE+CGNvbnN0YW50AscAAAATZ2VuZXJpYy5leGVjdXRl | ||
+ | c3luYwhjb25zdGFudAQNY3JhZnQgMjoxMDppbg5nbG9iYWwuaW50LnNldAhjb25zdGFudAQOY3JhZnRf | ||
+ | dGllcjozLjkNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchFnbG9iYWwuZG91YmxlLnNldAhjb25z | ||
+ | dGFudAQPY3JhZnRfY291bnQ6My45EWFyaXRobWV0aWMuZG91YmxlEGxvY2FsLmRvdWJsZS5nZXQIY29u | ||
+ | c3RhbnQEBWNvdW50CGNvbnN0YW50BAEtEWFyaXRobWV0aWMuZG91YmxlEWdsb2JhbC5kb3VibGUuZ2V0 | ||
+ | CGNvbnN0YW50BA9jcmFmdF9pbnZlbnRvcnkIY29uc3RhbnQEASoTZmFjdG9yeS5pdGVtcy5jb3VudAhj | ||
+ | b25zdGFudAQEcHVtcA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyE2dlbmVyaWMuZXhlY3V0ZXN5 | ||
+ | bmMIY29uc3RhbnQECWNyYWZ0IDM6OQ5nbG9iYWwuaW50LnNldAhjb25zdGFudAQOY3JhZnRfdGllcjoz | ||
+ | LjgNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchFnbG9iYWwuZG91YmxlLnNldAhjb25zdGFudAQP | ||
+ | Y3JhZnRfY291bnQ6My44EWFyaXRobWV0aWMuZG91YmxlEWFyaXRobWV0aWMuZG91YmxlEGxvY2FsLmRv | ||
+ | dWJsZS5nZXQIY29uc3RhbnQEBWNvdW50CGNvbnN0YW50BAEqDGRvdWJsZS5mbG9vchFhcml0aG1ldGlj | ||
+ | LmRvdWJsZRFhcml0aG1ldGljLmRvdWJsZQhjb25zdGFudAMAAG6CfSAkQghjb25zdGFudAQBLxFhcml0 | ||
+ | aG1ldGljLmRvdWJsZQhjb25zdGFudAMAAAAAAAAkQAhjb25zdGFudAQDc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pZXIRZ2xvYmFsLmRvdWJsZS5zZXQIY29uc3RhbnQEEGNyYWZ0X2NvdW50OndpcmURYXJpdGhtZXRp | ||
+ | Yy5kb3VibGURYXJpdGhtZXRpYy5kb3VibGUQbG9jYWwuZG91YmxlLmdldAhjb25zdGFudAQFY291bnQI | ||
+ | Y29uc3RhbnQEASoMZG91YmxlLmZsb29yEWFyaXRobWV0aWMuZG91YmxlEWFyaXRobWV0aWMuZG91Ymxl | ||
+ | CGNvbnN0YW50AwAA+rUJTSlCCGNvbnN0YW50BAEvEWFyaXRobWV0aWMuZG91YmxlCGNvbnN0YW50AwAA | ||
+ | AAAAACRACGNvbnN0YW50BANwb3cDaTJkDWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIIY29uc3Rh | ||
+ | bnQEA21vZAhjb25zdGFudAMAAAAAAAAkQAhjb25zdGFudAQBLRFhcml0aG1ldGljLmRvdWJsZRFnbG9i | ||
+ | YWwuZG91YmxlLmdldAhjb25zdGFudAQPY3JhZnRfaW52ZW50b3J5CGNvbnN0YW50BAEqE2ZhY3Rvcnku | ||
+ | aXRlbXMuY291bnQIY29uc3RhbnQEBHdpcmUNbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchNnZW5l | ||
+ | cmljLmV4ZWN1dGVzeW5jCGNvbnN0YW50BA9jcmFmdCBwYXJ0OndpcmUTZ2VuZXJpYy5leGVjdXRlc3lu | ||
+ | Ywhjb25zdGFudAQRY3JhZnQgMjoxMDpwbGF0ZXMNZmFjdG9yeS5jcmFmdAhjb25zdGFudAQObWFjaGlu | ||
+ | ZS5ib2lsZXINbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0 | ||
+ | YW50BAVjb3VudA== | ||
+ | |src= | ||
+ | ; Boiler | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.10") | ||
+ | count = global.double.get("craft_count:2.10") | ||
+ | gotoif(99, tier < 1 {{!}} tier > 10 {{!}} count < 1.0 {{!}} global.int.get("craft_status") > 199) | ||
+ | |||
+ | executesync("craft 2:10:in") | ||
+ | |||
+ | ;pumps = count * 1.0 | ||
+ | global.int.set("craft_tier:3.9", tier) | ||
+ | global.double.set("craft_count:3.9", count - craft_inventory * count("pump", tier)) | ||
+ | executesync("craft 3:9") | ||
+ | |||
+ | ;motors = count * floor((43222221111.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.8", tier) | ||
+ | global.double.set("craft_count:3.8", count * floor((43222221111.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("motor", tier)) | ||
+ | executesync("craft 3:8") | ||
+ | |||
+ | ;screw = count * 2.0 | ||
+ | global.int.set("craft_tier:screw", tier) | ||
+ | global.double.set("craft_count:screw", count * 2.0 - craft_inventory * count("screw", tier)) | ||
+ | executesync("craft part:screw") | ||
+ | |||
+ | ;wires = count * floor((54333332221.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:wire", tier) | ||
+ | global.double.set("craft_count:wire", count * floor((54333332221.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("wire", tier)) | ||
+ | executesync("craft part:wire") | ||
+ | |||
+ | executesync("craft 2:10:plates") | ||
+ | |||
+ | craft("machine.boiler", tier, count) | ||
+ | }} | ||
+ | |||
+ | |- | ||
+ | |craft 2:10:in | ||
+ | |13 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | DWNyYWZ0IDI6MTA6aW4AAAAAAAAAAA0AAAANbG9jYWwuaW50LnNldAhjb25zdGFudAQEdGllcg5nbG9i | ||
+ | YWwuaW50LmdldAhjb25zdGFudAQPY3JhZnRfdGllcjoyLjEwEGxvY2FsLmRvdWJsZS5zZXQIY29uc3Rh | ||
+ | bnQEBWNvdW50EWdsb2JhbC5kb3VibGUuZ2V0CGNvbnN0YW50BBBjcmFmdF9jb3VudDoyLjEw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vcnkuaXRlbXMuY291bnQIY29uc3RhbnQEDm1hY2hpbmUuYm9pbGVy | ||
+ | DmFyaXRobWV0aWMuaW50DWxvY2FsLmludC5nZXQIY29uc3RhbnQEBHRpZXIIY29uc3RhbnQEAS0IY29u | ||
+ | c3RhbnQCAQAAABNnZW5lcmljLmV4ZWN1dGVzeW5jCGNvbnN0YW50BApjcmFmdCAyOjEwDmdlbmVyaWMu | ||
+ | Z290b2lmCGNvbnN0YW50AmMAAAAOY29tcGFyaXNvbi5pbnQOZ2xvYmFsLmludC5nZXQIY29uc3RhbnQE | ||
+ | DGNyYWZ0X3N0YXR1cwhjb25zdGFudAQBPghjb25zdGFudALHAAAADmdsb2JhbC5pbnQuc2V0CGNvbnN0 | ||
+ | YW50BA9jcmFmdF90aWVyOjIuMTANbG9jYWwuaW50LmdldAhjb25zdGFudAQEdGllchFnbG9iYWwuZG91 | ||
+ | YmxlLnNldAhjb25zdGFudAQQY3JhZnRfY291bnQ6Mi4xMBBsb2NhbC5kb3VibGUuZ2V0CGNvbnN0YW50 | ||
+ | BAVjb3VudA== | ||
+ | |src= | ||
+ | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | :local double ingots | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.10") | ||
+ | count = global.double.get("craft_count:2.10") | ||
+ | |||
+ | ; Ingots | ||
+ | ingots = 0.0 ; TODO | ||
+ | global.int.set("craft_tier:ingot", tier) | ||
+ | global.double.set("craft_count:ingot", ingots - count("ingot", tier)) | ||
+ | ;global.int.set("craft_verify:ingot", 1) | ||
+ | executesync("craft ingot") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Lower tier inputs | ||
+ | global.int.set("craft_tier:2.10", tier - 1) | ||
+ | global.double.set("craft_count:2.10", count - craft_inventory * count("machine.boiler", tier - 1)) | ||
+ | executesync("craft 2:10") | ||
+ | gotoif(99, global.int.get("craft_status") > 199) | ||
+ | |||
+ | ; Restore state for this tier | ||
+ | global.int.set("craft_tier:2.10", tier) | ||
+ | global.double.set("craft_count:2.10", count) | ||
+ | }} | ||
+ | |||
+ | |- | ||
+ | |craft 2:10:plates | ||
+ | |8 | ||
+ | |{{AIScript | ||
+ | |code= | ||
+ | EWNyYWZ0IDI6MTA6cGxhdGVzAAAAAAAAAAAIAAAADWxvY2FsLmludC5zZXQIY29uc3RhbnQEBHRpZXIO | ||
+ | Z2xvYmFsLmludC5nZXQIY29uc3RhbnQED2NyYWZ0X3RpZXI6Mi4xMBBsb2NhbC5kb3VibGUuc2V0CGNv | ||
+ | bnN0YW50BAVjb3VudBFnbG9iYWwuZG91YmxlLmdldAhjb25zdGFudAQQY3JhZnRfY291bnQ6Mi4xMA5n | ||
+ | bG9iYWwuaW50LnNldAhjb25zdGFudAQOY3JhZnRfdGllcjozLjQNbG9jYWwuaW50LmdldAhjb25zdGFu | ||
+ | dAQEdGllchFnbG9iYWwuZG91YmxlLnNldAhjb25zdGFudAQPY3JhZnRfY291bnQ6My40EWFyaXRobWV0 | ||
+ | aWMuZG91YmxlEWFyaXRobWV0aWMuZG91YmxlEGxvY2FsLmRvdWJsZS5nZXQIY29uc3RhbnQEBWNvdW50 | ||
+ | CGNvbnN0YW50BAEqDGRvdWJsZS5mbG9vchFhcml0aG1ldGljLmRvdWJsZQhjb25zdGFudAMAAAAAAADw | ||
+ | Pwhjb25zdGFudAQBKxFhcml0aG1ldGljLmRvdWJsZRFhcml0aG1ldGljLmRvdWJsZQhjb25zdGFudAMA | ||
+ | APdBnf82Qghjb25zdGFudAQBLxFhcml0aG1ldGljLmRvdWJsZQhjb25zdGFudAMAAAAAAAAkQAhjb25z | ||
+ | dGFudAQDcG93A2kyZA1sb2NhbC5pbnQuZ2V0CGNvbnN0YW50BAR0aWVyCGNvbnN0YW50BANtb2QIY29u | ||
+ | c3RhbnQDAAAAAAAAJEAIY29uc3RhbnQEAS0RYXJpdGhtZXRpYy5kb3VibGURZ2xvYmFsLmRvdWJsZS5n | ||
+ | Z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 | :global double craft_inventory | ||
+ | :local int tier | ||
+ | :local double count | ||
+ | |||
+ | tier = global.int.get("craft_tier:2.10") | ||
+ | count = global.double.get("craft_count:2.10") | ||
+ | |||
+ | ; blocks = count * floor(1.0 + (98777776631.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.4", tier) | ||
+ | global.double.set("craft_count:3.4", count * floor(1.0 + (98777776631.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("block", tier)) | ||
+ | executesync("craft 3:4") | ||
+ | |||
+ | ; denseplates = count * floor((54333332221.0 / (10.0 ^ i2d(tier))) % 10.0) | ||
+ | global.int.set("craft_tier:3.3", tier) | ||
+ | global.double.set("craft_count:3.3", count * floor((54333332221.0 / (10.0 ^ i2d(tier))) % 10.0) - craft_inventory * count("plate.dense", tier)) | ||
+ | executesync("craft 3:3") | ||
+ | }} | ||
|} | |} |
Latest revision as of 03:01, 15 February 2021
Contents
Machine scripts
Oven (1)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:1 | 16 |
| |||
craft 2:1:in | 18 |
| |||
craft 2:1:plates | 11 |
|
Assembler (2)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:2 | 17 |
| |||
craft 2:2:in | 13 |
| |||
craft 2:2:plates | 20 |
|
Refiner (3)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:3 | 16 |
| |||
craft 2:3:in | 17 |
| |||
craft 2:3:misc | 18 |
|
Crusher (4)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:4 | 14 |
| |||
craft 2:4:in | 18 |
|
Cutter (5)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:5 | 15 |
| |||
craft 2:5:in | 17 |
| |||
craft 2:5:plates | 12 |
|
Presser (6)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:6 | 17 |
| |||
craft 2:6:in | 22 |
|
Mixer (7)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:7 | 14 |
| |||
craft 2:7:in | 18 |
|
Belt (8)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:8 | 14 |
| |||
craft 2:8:in | 18 |
|
Shaper (9)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:9 | 15 |
| |||
craft 2:9:in | 13 |
| |||
craft 2:9:plates | 18 |
|
Boiler (10)
(pic)
Name | Lines | Code | |||
---|---|---|---|---|---|
craft 2:10 | 18 |
| |||
craft 2:10:in | 13 |
| |||
craft 2:10:plates | 8 |
|