Space Engineers

Space Engineers

Not enough ratings
Admin Economy Command Guide
By hyprcoob
This is a basic walkthrough for commands related the "Admin Economy" mod.
   
Award
Favorite
Favorited
Unfavorite
Commands
********************************
USER GUIDE:

NOTES
- All occurances of "<>" denotes a variable and should be replaced by appropriate values.
- An item must be coupled with an item type separated by an underscore.
- All items and item types must be referenced case sensitive (usually initcap).
- Time command always on the first line in custom data.
- Each command must be entered on a new line.
- An Admin Core block must be present on a grid for any commands to function.
- Payments must be resolved by depositing specified payment items into the cargo with the respective command in it's custom data.
********************************

- Admin Blocks -
Admin blocks function the same as vanilla blocks with enhanced outputs, the Admin Core acts as a battery and enables trade, fill, and trigger functions for any grid.

- Custom Data -
Any grid with an Admin Core will allow for commands to be entered into the custom data of any cargo container, these commands allow for configuration of depots, trades, and triggers and apply ONLY to the block that it is enter into.

---------------------
Commands:
---------------------
1. "time" - represents a time loop that commands use to reset.
2. "fill" - Keeps specified item at a specific level.
3. "trade" - Allows items to be deposited and converted to another item at a specific ratio.
4. "trigger" - Allows items to be deposited which kicks off a named timer's trigger.

1. "time":
time_<timer reset value>,<remaining time>
..........................examples..........................
time_3600,3600
time_3,3

2. "fill":
fill{<quantity>},<item SID>_<item type>,<apply timer>
..........................examples..........................
fill{1000},Ice,O
fill{1000},ZoneChip

3. "trade":
trade_<inventory amount>{<inventory remaining>;<goods rate>:<payment rate>},<goods SID>_goods type,<payment item SID>_<payment item type>,<minimum payment>,<one off indicator>
..........................examples..........................
trade_1200{1200;3:1},Iron_Ingot,Cobalt_Ore,100
trade_10000{10000;1000:1},Iron_Ore,SpaceCredit,1

4. "trigger":
trigger_<seconds amount>{<seconds left left>;<payment item price>},<name of timer block>,<payment item SID>_<payment item type>,<trigger block type>,<one off indicator>
..........................examples..........................
trigger_900{900;100},named timer block A,Iron_Ingot,T
trigger_60{60;1000},named timer block 1,SpaceCredit_PhysicalObject,T,O

---------------------
Examples Continued:
---------------------
<in custom data field of any cargo container>
---------------------------------------------------------------------------------
To set up a cargo container as a depot the custom data must include both the time command and at least one fill command.

time_3600,325
fill{1000},Uranium_Ingot
fill{2000},Ice,O
fill{1000},ZoneChip

The above example will keep the quantity of uranium fuel and zonechips at 1000 and ice at 2000 in the cargo container that has the above manifest. Uranium and zonechips are refreshed hourly when the timer reaches 0 (the remain seconds resolve at just over 5 minutes) while ice ignores the timer (set to "O").
---------------------------------------------------------------------------------
To set up a cargo container as a trade repository the custom data must include both the time command and at least one trade command.

time_500,224
trade_1200{1200;3:1},Iron_Ingot,Cobalt_Ore,100
trade_3000{3000;100:3},Iron,Cobalt_Ingot,30
trade_10000{10000;1000:1},Iron_Ore,SpaceCredit,1
trade_30000{30000;1:1},SteelPlate,Iron,1

The above example has a refresh rate of just over 8 minutes and has just under 4 minutes remaining. Here is the function by contract:

Trade 1)
A inventory of 1200 iron ingots can be bought at an exchange rate of 3 iron ingots for every 1 cobalt ore with a minimum trade requirement of 100 cobalt ore. (minimum trade of 300 iron ingots for 100 cobalt ore).

Trade 2)
An inventory of 3000 iron ore (type wasn't specified so it goes to default) can be bought at an exchange rate of 100 iron ore for evey 3 cobalt ingots with a minimum trade requirement of 30 cobalt ingots. (minimum trade of 1000 iron ore for 30 cobalt ingots).

Trade 3)
An inventory of 10000 iron ore can be bought at an exchange rate of 1000 iron ore per space credit with a minimum trade requirement of 1 space credit. (minimum trade of 1000 iron ore for 1 space credit).

Trade 4)
An inventory of 30000 iron ore can be bought at an exchange rate of 1 steel plate per iron ore with a minimum trade requirement of 1 iron ore. (minimum trade of 1 steel plate for 1 iron).

--Notice the trade above will immediate convert the previous output into steel plates so be careful.

Each trade will remain available as long as there is availble inventory, when the timer resets, the available inventory will reset to the max value.
---------------------------------------------------------------------------------
To set up a cargo container as a trigger manifest the custom data must include both the time command and at least one trigger command.

time_3600,923
trigger_900{900;100},named timer block A,Iron_Ingot,T
trigger_60{60;1000},named timer block 1,SpaceCredit_PhysicalObject,T,O

The above example has a refresh rate of 1 hour and has just over 15 minutes remaining. Here is the function by contract:

Trigger 1)
A price of 100 iron ingots must be payed in order to actuate the trigger of timer block "named timer block A" with a lockout time of 15 minutes, during that lockout time the contract cannot be triggered again.

Trigger 2)
A price of 1000 space credits must be payed in order to actuate the trigger of timer block "named timer block 1" with a lockout time of 60 seconds, during that lockout time the contract cannot be triggered again.
Items and Item Types
"Ore:Stone",
"Ore:Iron",
"Ore:Nickel",
"Ore:Cobalt",
"Ore:Magnesium",
"Ore:Silicon",
"Ore:Silver",
"Ore:Gold",
"Ore:Platinum",
"Ore:Uranium",
"Ingot:Iron",
"Ingot:Nickel",
"Ingot:Cobalt",
"Ingot:Magnesium",
"Ingot:Silicon",
"Ingot:Silver",
"Ingot:Gold",
"Ingot:Platinum",
"Ingot:Uranium",
"Component:Construction",
"Component:MetalGrid",
"Component:InteriorPlate",
"Component:SteelPlate",
"Component:Girder",
"Component:SmallTube",
"Component:LargeTube",
"Component:Motor",
"Component:Display",
"Component:BulletproofGlass",
"Component:Superconductor",
"Component:Computer",
"Component:Reactor",
"Component:Thrust",
"Component:GravityGenerator",
"Component:Medical",
"Component:RadioCommunication",
"Component:Detector",
"Component:Explosives",
"Component:SolarCell",
"Component:PowerCell",
"Component:Canvas",
"Component:ZoneChip",
"PhysicalGunObject:SemiAutoPistolItem",
"PhysicalGunObject:FullAutoPistolItem",
"PhysicalGunObject:ElitePistolItem",
"PhysicalGunObject:AutomaticRifleItem",
"PhysicalGunObject:PreciseAutomaticRifleItem",
"PhysicalGunObject:RapidFireAutomaticRifleItem",
"PhysicalGunObject:UltimateAutomaticRifleItem",
"PhysicalGunObject:BasicHandHeldLauncherItem",
"PhysicalGunObject:AdvancedHandHeldLauncherItem",
"OxygenContainerObject:OxygenBottle",
"GasContainerObject:HydrogenBottle",
"PhysicalGunObject:WelderItem",
"PhysicalGunObject:Welder2Item",
"PhysicalGunObject:Welder3Item",
"PhysicalGunObject:Welder4Item",
"PhysicalGunObject:AngleGrinderItem",
"PhysicalGunObject:AngleGrinder2Item",
"PhysicalGunObject:AngleGrinder3Item",
"PhysicalGunObject:AngleGrinder4Item",
"PhysicalGunObject:HandDrillItem",
"PhysicalGunObject:HandDrill2Item",
"PhysicalGunObject:HandDrill3Item",
"PhysicalGunObject:HandDrill4Item",
"Ore:Scrap",
"Ore:Ice",
"Ore:Organic",
"ConsumableItem:ClangCola",
"ConsumableItem:CosmicCoffee",
"AmmoMagazine:SemiAutoPistolMagazine",
"AmmoMagazine:FullAutoPistolMagazine",
"AmmoMagazine:ElitePistolMagazine",
"AmmoMagazine:AutomaticRifleGun_Mag_20rd",
"AmmoMagazine:RapidFireAutomaticRifleGun_Mag_50rd",
"AmmoMagazine:PreciseAutomaticRifleGun_Mag_5rd",
"AmmoMagazine:UltimateAutomaticRifleGun_Mag_30rd",
"AmmoMagazine:NATO_5p56x45mm",
"AmmoMagazine:AutocannonClip",
"AmmoMagazine:NATO_25x184mm",
"AmmoMagazine:Missile200mm",
"AmmoMagazine:LargeCalibreAmmo",
"AmmoMagazine:MediumCalibreAmmo",
"AmmoMagazine:LargeRailgunAmmo",
"AmmoMagazine:SmallRailgunAmmo",
"Datapad:Datapad",
"Package:Package",
"ConsumableItem:Medkit",
"ConsumableItem:Powerkit",
"PhysicalObject:SpaceCredit"