CraftTweaker for Terminal - GregTechCEu/GregTech GitHub Wiki

API:

  1. registerDevice(deviceItemStack, deviceName): Register the custom device.
  2. createAppRegistryBuilder(appName): Create the registryBuilder according to the app name.
  3. isDefaultApp(default): Make it as a default app.
  4. battery(euTier, cost): Set battery requirements for all tier.
  5. battery(appTier, euTier, cost): Set battery requirements for the specific tier.
  6. device(deviceName...): Set device requirements for all tier. (available by default: "scanner", "wireless", "camera", "solar_lv")
  7. device(appTier, device...): Set device requirements for the specific tier.
  8. upgrade(upgradeItemStack...): Set upgrade requirements for all tier.
  9. upgrade(appTier, upgradeItemStack...): Set upgrade requirements for the specific tier.
  10. build(): finish and register.

ZS Demo:

import mods.gregtech.TerminalRegistry;

TerminalRegistry.registerDevice(<ore:ingotIron>.firstItem, "ingot_iron");

TerminalRegistry.createAppRegistryBuilder("ore_prospector")
    .isDefaultApp(true)
    .battery(1, 500)
    .battery(3, 3, 1000)
    .device("camera", "wireless")
    .device(4, "ingot_iron")
    .upgrade(<minecraft:apple> * 9)
    .upgrade(2, <minecraft:apple> * 9, <minecraft:grass> * 12)
    .build();

Result:

Custom Device

20e2972c486dd30030b4047cd549e5a

Register Battery, Device, and Upgrade

6f162e3410edddcc209eb344c0b2cd9 dd9139f65229dfae54f87014fb3161b