Module:Vehicles/data

From Dune: Awakening Community Wiki
Jump to navigation Jump to search

Module:Vehicles/data

Dataset of vehicles.

Schema

The dataset is a table keyed by vehicle name.

Each value is a table with the following fields:

type
string
Classification of the vehicle based on its mode of propulsion.
Valid values:
"Ground"
"Aerial"
category
string
Official in-game vehicle classification indicating its size and role.
Examples:
"One-Man Groundcar"
"Four-Man Groundcar"
"Light Ornithopter"
"Medium Ornithopter"
minimum_tier
string
The lowest progression tier at which the vehicle schematics are unlocked.
Examples:
Copper
Steel
Duraluminum
crew_capacity
string
The number of seats available in the vehicle. If this value can vary due to installed modules, display it as a range (e.g. 3–4).
Examples:
1
3-4
backup_compatible
boolean
Denotes whether vehicle can be stored using the Vehicle Backup Tool.

local vehicles = {
    ["Sandbike"] = {
        type = "Ground",
        category = "One-Man Groundcar",
        minimum_tier = "Copper",
        crew_capacity = "1-2",
        backup_compatible = true,
    },
    ["Treadwheel"] = {
        type = "Ground",
        category = "One-Man Groundcar",
        minimum_tier = "Aluminum",
        crew_capacity = "1-2",
        backup_compatible = true,
    },
    ["Buggy"] = {
        type = "Ground",
        category = "Four-Man Groundcar",
        minimum_tier = "Steel",
        crew_capacity = "3-4",
        backup_compatible = false,
    },
    ["Sandcrawler"] = {
        type = "Ground",
        category = "Sandcrawler",
        minimum_tier = "Plastanium",
        crew_capacity = "2",
        backup_compatible = false,
    },
    ["Scout Ornithopter"] = {
        type = "Aerial",
        category = "Light Ornithopter",
        minimum_tier = "Aluminum",
        crew_capacity = "1",
        backup_compatible = true,
    },
    ["Assault Ornithopter"] = {
        type = "Aerial",
        category = "Medium Ornithopter",
        minimum_tier = "Duraluminum",
        crew_capacity = "4",
        backup_compatible = false,
    },
    ["Carrier Ornithopter"] = {
        type = "Aerial",
        category = "Carryall",
        minimum_tier = "Plastanium",
        crew_capacity = "6",
        backup_compatible = false,
    },
    ["Cargo Container"] = {
        type = "Special",
        category = "Module",
        minimum_tier = "Plastanium",
        crew_capacity = "N/A",
        backup_compatible = false,
    },
}

-- ==================================================
-- Fallback behaviour for unknown vehicle key input
-- Do not add vehicles below this point
-- ==================================================

local PLACEHOLDER = {
    type = "Unknown",
    category = "Unknown",
    minimum_tier = "Unknown",
    crew_capacity = "?",
    backup_compatible = false,
}

local vehicleTypes = {
    Ground = "Ground Vehicles",
    Aerial = "Aerial Vehicles",
}

setmetatable(vehicles, { __index = function() return PLACEHOLDER end })

return {
    vehicles = vehicles,
    vehicleTypes = vehicleTypes,
}