Configuration
Shared Configuration (shared.lua)
Debug Configuration
The debug configuration controls whether debug messages are displayed and what types of messages are enabled.
Enabled: Enables or disables all debug prints.
Levels: Controls specific debug message types:
Info
: General information messages.Success
: Messages for successful operations.Warning
: Warnings and potential issues.
DevHub Skill Tree Integration
This setting enables integration with the DevHub Skill Tree System.
DEVHUB_SKILLTREE_ENABLED: Set to
true
if you're using the DevHub Skill Tree system.The skill tree system can be purchased at: DevHub Store.
Recepie Configuration
This section contains generated code from How to create table
Recepie: Stores generated recipe data.
Client Configuration (client.lua)
Developer Mode
Enables developer commands, such as /tablegenerator
.
DeveloperMode: Set to
true
to enable developer commands.
Skill Tree Boosts
Defines various skill-based bonuses that apply when using the skill tree integration.
SkillTreeBoosts: Defines the various skill effects that can be applied during crafting.
double_xp
: 10% chance to earn double XP from crafting.xp_multiplier
: 10% XP gain multiplier.double_reward
: 10% chance to receive double rewards.needed_items_recover
: 10% chance to recover 50% of required crafting items.
Crafting Table Interaction
Table Check Interval
Defines how often the system checks if a player is near a crafting table.
TablesCheckInterval: Time in milliseconds between each proximity check (default:
2000ms
).
Sound Configuration
Controls the volume of all crafting-related sound effects.
SoundVolume: The global volume for crafting sounds (
0.0
-1.0
).
Camera Offsets
Defines camera positions for different crafting table models.
CameraOffsets: Configures camera behavior when interacting with different crafting tables.
cameraAimOffset
: Adjusts where the camera is aiming (relative to the table).cameraOffset
: Controls the position of the camera relative to the table.
Server Configuration (server.lua)
Crafting Tables Configuration
Defines crafting table locations and settings. This script can be used to spawn crafting tables, or you can spawn them via your own scripts.
Tables: A list of predefined crafting tables.
coords
: The vector4 position of the table in the world.tableUid
: A unique identifier for the table.snapToGround
: Iftrue
, the table will be placed on the ground automatically.
Alternative: Triggering the Client-Side Event
If you prefer not to use Config.Tables
, you can manually trigger the client-side event instead:
Triggering this event manually allows you to use your own logic for spawning crafting tables.
The event takes two arguments:
entity
: The table entity.tableUid
: The unique identifier of the table.
This provides flexibility in integrating the crafting system into custom scripts.
XP System Integration
This function awards XP to players after crafting if the DevHub Skill Tree System is enabled.
AddXP: A function that adds XP to the player.
Uses
exports['devhub_skillTree']:addXp()
when DevHub Skill Tree is enabled.XP is applied to the personal skill tree.
Last updated