I want to explain more about the Item Editor. I want to make it clear why we're bothering, and why it's awesome. So let me walk you through how the
Camp Fire item works.
If you click the link above you will see a number of modules. For any item these modules can be turned on and off.
World Model controls what the item looks like when you drop it into the world (right click > drop). This could be a different model to what it normally looks like. It could be a sack for example.
Container means that this item can contain other items. You can specify what type of items, and whether these items are accessible in the inventory, world model and deployed.
Crafting lets you define blueprints to make this item.
Deployable
means this item can be placed in the world when selected in the belt bar.
The oven lets you specify the temperature this item and its contents reaches when switched on.
And then we have events.. these events all add context options to the fireplace. So when you right click in the inventory or 'use' in the world, you are presented with these options.
These events have conditions. So for example.. the "
Ignite" option won't show if the fire is already on, or if the fire doesn't contain fuel.
So here's how that looks in game when you use the item.
So the fire works. What about cooking stuff? Well, that's generic too.
Take a look at this page. As you can probably see.. this event gets run when the temperature is between 150 and 250. When the cooked var reaches 100 the action gets run. Which is to swap the current item with a cooked version.
This is nice and generic, nice and open. We can easily add an event to cooked chicken so that if t's cooked for another 60 seconds, it becomes burnt chicken. Then if it's cooked for another 60 seconds it becomes charcoal. This exact same logic can be applied to a furnace object, or a freezer - without any extra coding.
So what about fuel? You need to put wood in the fire, right? Well technically not any more. We can add the
burnable module to anything and it instantly becomes a fuel source for an oven.