Prefab Database
Usage: Use the search box to filter prefabs by ID or type. Click on a prefab ID to copy it to clipboard.
Incomplete Database: This prefab database is currently under development and does not contain all prefabs available in the game. More entries will be added in future updates.
Prefab ID | Type | Description |
---|---|---|
No prefabs match your search criteria |
Example Usage
lua
-- Check if a prefab exists
if DoesPrefabExist("container_box_small") then
Log("Container box prefab exists")
-- Get the prefab
local prefab = GetPrefab("container_box_small")
if prefab then
Log("Got container box prefab")
-- Now you can spawn it at a position
local pos = Vector3(10, 0, 10)
local instance = InstantiateGameObject(prefab, pos)
if instance then
Log("Spawned container at " .. pos.x .. ", " .. pos.y .. ", " .. pos.z)
end
end
end
-- Check if a constructable exists (for building system)
if DoesConstructableExist("furniture_bed_single") then
local constructable = GetConstructable("furniture_bed_single")
-- Work with constructable...
end