Starbound

Starbound

Auto Crafting Table (for modders)
 This topic has been pinned, so it's probably important
swefpifh  [developer] 3 Mar, 2024 @ 7:16pm
Information to personalise your craft table
⋮ RECIPES_3i.json

⋮ AUTOCRAFTINGTABLE_3i.object

⋮ AUTOCRAFTINGTABLE_3i.animation
Last edited by swefpifh; 15 Mar, 2024 @ 5:16pm
< >
Showing 1-5 of 5 comments
swefpifh  [developer] 3 Mar, 2024 @ 7:16pm 
⋮ RECIPES_3i.JSON INFORMATIONS

To use this crafting table with your items, simply edit the recipes_3i.json file in the object folder.

Here's how a recipe is structured :
{ "input1": {"ITEM ID": [NUMBER, CONSUMPTION]}, "input2": {}, "input3": {}, "outputs": [ {"item": ["ITEM ID",NUMBER], "chance": POURCENT OF CHANCE} ], "time" : TIME },

ITEM ID
⤷ The item id for the ingredient (input) or for the final construction item (output)
NUMBER
⤷ Number of items to be consumed or produced
CONSUMPTION
⤷ Defines the number of items consumed. 0 = no item consumed, 1 = one item consumed, 2 = two items consumed, etc...
POURCENT OF CHANCE
⤷ This is the percentage chance of producing an object. 100 = Production guaranteed, 50 = One chance in two of producing the object, etc...
TIME
⤷ This is the object's production time, calculated in seconds.



Each Input corresponds to an ingredient in your recipe. You can create a recipe with just one or two ingredients if you wish. Like this example:
{ "input1": {"acfONE": [1, 1]}, "input2": {"acfTWO": [1, 1]}, "input3": {}, "outputs": [ {"item": ["acfTHREE",1], "chance": 100} ], "time" : 1 },

You can also add several ingredients to an input element and you can also add several output items. For example, with the recipe below, by mixing green with red, white or cyan, you can generate yellow and black.
{ "input1": {"acfRED": [1, 1], "acfWHITE": [1, 1], "acfCYAN": [1, 1]}, "input2": {"acfGREEN": [1, 1]}, "input3": {}, "outputs": [ {"item": ["acfYELLOW",1], "chance": 100}, {"item": ["acfBLACK",1], "chance": 5} ], "time" : 1 },
Last edited by swefpifh; 15 Mar, 2024 @ 5:16pm
swefpifh  [developer] 3 Mar, 2024 @ 7:17pm 
⋮ AUTOCRAFTINGTABLE_3i.OBJECT INFORMATIONS

You can customise the bubble. To do this, simply open the autocraftingtable_3i.object file. You can see that the text in the file corresponds to this:
"progressbardisplay" : 1, "progressbartitle" : "Crafting progress:", "progressbartitlecolor" : "white", "progressbarpercentcolor" : "#ec9630",

progressbardisplay
⤷ You can show or hide the progress bubble
  • 0 = Hidden
  • 1 = Displayed (by default)

progressbartitle
⤷ You can customise the title that will be displayed before the percentage progression. (By default "Crafting progress:").

progressbartitlecolor
⤷ You can now choose the colour of the text preceding the percentage progression. You can type the name of the colour (white, blue, red, etc) or use a hexadecimal code, remembering to write # before the desired code (#123456, #FFF456, etc).

progressbarpercentcolor
⤷ You can now choose the colour of percentage progression. You can type the name of the colour (white, blue, red, etc) or use a hexadecimal code, remembering to write # before the desired code (#123456, #FFF456, etc).
Last edited by swefpifh; 30 Apr, 2024 @ 11:00am
swefpifh  [developer] 4 Mar, 2024 @ 1:47am 
⋮ AUTOCRAFTINGTABLE_3i.ANIMATION INFORMATIONS

As well as a passive sound effect, you can change the sound effect of the machine when it is activated.. To do this, simply open the autocraftingtable_3i.animation file and navigate to the variable named "persistentSound".

You can see that the text in the file corresponds to this:
"properties" : { "persistentSound" : "/sfx/objects/server_loop.ogg" }
Simply choose a new vanilla sound or add your own.
Last edited by swefpifh; 4 Mar, 2024 @ 1:48am
swefpifh  [developer] 23 Apr, 2024 @ 12:27pm 
⋮ AUTOCRAFTINGTABLE_3i.OBJECT INFORMATIONS

To do this, simply open the autocraftingtable_3i.object file. You can see that the text in the file corresponds to this:
"areadetection" : 0, "areadetectionrange" : 10, "areadetectionitem" : ["flowerblue", "basictoilet"],

areadetection
⤷ You'll be able to activate proximity detection of environmental objects to activate recipe crafting.
  • 0 = Deactivated (by default)
  • 1 = Enabled

areadetectionrange
⤷ You can configure the detection radius with any block radius value. (10 blocks by default)

areadetectionitem
⤷ You will need to enter the names of the environmental objects to be detected.
  • ["flowerblue"] (For one)
  • ["flowerblue", "basictoilet", "etc"] (For many)
Last edited by swefpifh; 30 Apr, 2024 @ 11:01am
swefpifh  [developer] 24 Apr, 2024 @ 2:53am 
⋮ AUTOCRAFTINGTABLE_3i.OBJECT INFORMATIONS

To do this, simply open the autocraftingtable_3i.object file. You can see that the text in the file corresponds to this:
"dailycycle" : 0,

dailycycle
⤷ You can configure the table to operate either during the day or at night, or without any cycle restriction.
  • 0 = Deactivated (by default)
  • 1 = Day only
  • 2 = Night only
Last edited by swefpifh; 30 Apr, 2024 @ 11:03am
< >
Showing 1-5 of 5 comments
Per page: 1530 50