Skip to main content

Craft Table

Craft mechanic items at workbenches with 3D preview

This section

Craft Table

Craft mechanic items at physical workbenches with 3D rotating preview, server-validated ingredients, and configurable recipes.

Features

  • Physical bench prop spawned in world (configurable model)
  • 3D rotating item preview while crafting
  • Custom camera positioning per bench
  • Multiple craft locations per mechanic
  • Server-validated ingredient requirements
  • Configurable craft duration per recipe
  • Interaction: E key or ox_target/qb-target

Recipe Structure

lua
Config.Craft.recipes = {
['mechanic_parts'] = {
{
id = 'toolbox_basic',
label = 'Tool Box',
description = 'Basic mechanic toolbox.',
category = 'tools',
resultItem = 'toolbox',
resultCount = 1,
craftTimeMs = 10500,
previewProp = 'prop_tool_box_04',
requirements = {
{ name = 'steel', count = 3, label = 'Steel' },
{ name = 'rubber', count = 2, label = 'Rubber' },
}
},
},
}

Configuration

OptionDefaultDescription
enabledtrueEnable craft system
benchModelDefaultprop_tool_bench02Default bench prop model
defaultInteractionRadius3.0Interaction distance
previewDefaults.rotationSpeed0.05Preview rotation speed

Per-Mechanic Setup

lua
craft = {
enabled = true,
coords = vector3(-214.02, -1331.59, 30.89),
heading = 180.94,
propModel = 'xm3_prop_xm3_bench_03b',
recipes = 'mechanic_parts',
interactionType = 'interaction',
interactionRadius = 5.0,
}