💾X SafeZones

Table of Contents

  1. What is X SafeZones?

  2. Installation

  3. Full Configuration


What is X SafeZones?

X SafeZones creates invisible force-fields anywhere on your map. Walk inside → bullets stop, cars slow down, weapons lock, and a shiny glass shield appears. Think of it as a protective bubble that keeps airports, hospitals, or event areas completely safe and peaceful.


Installation (5 minutes)

  1. Download from Tebex

  2. Drop into resources/x_safezones

  3. Add ensure X_SafeZones to server.cfg

  4. Restart server → done!


Full Configuration

Main Settings (config.lua)

Config = {}

-- Language (en, de, fr, it, es)
Config.Language = 'en'

-- Safe zone locations (unlimited)
Config.Safezones = {
    {
        coords = vector3(-1057.2662, -2773.8074, 21.3610), -- Airport
        radius = 150.0,
        blip = true
    },
    {
        coords = vector3(310.7283, -584.1788, 43.2491), -- Medical Pillbox
        radius = 30.0,
        blip = true
    },
    {
        coords = vector3(968.0748, 20.1876, 80.9001), -- Casino
        radius = 95.0,
        blip = true
    },
    {
        coords = vector3(191.1166, -932.4631, 30.6913), -- Legion Square
        radius = 100.0,
        blip = true
    }
}

-- Visual settings
Config.Blips = {
    enabled = true,          -- Show blips on map
    showRadius = true,       -- Show radius circle
    sprite = 461,            -- Blip icon (shield)
    color = 2,               -- Green color
    scale = 1.0,
    alpha = 128,
    radiusColor = 2,
    name = "Safe Zone"       -- Display name
}

-- Vehicle controls
Config.VehicleSpeedLimit = {
    enabled = true,          -- Enable speed limiting
    maxSpeed = 50.0,         -- Max speed in km/h
    smoothTransition = true, -- Gentle slowdown
    displayWarning = true    -- Show speed warning
}

-- Weapon restrictions
Config.Protection = {
    disableFriendlyFire = true,     -- No friendly fire
    enableInvincibility = true,     -- God mode inside
    disableRagdoll = true,          -- No falling over
    clearDamageEffects = true,      -- Clear blood
    enableEntityProofs = true,      -- Explosion/fire proof
    allowWeaponSwitching = true,    -- Can switch weapons
    disableWeaponsFiring = true,    -- Cannot shoot
    disableWeaponMeleeAttack = true, -- No melee attacks
    restrictWeapons = true,         -- Weapon whitelist
    allowedWeapons = {              -- Allowed weapons
        "WEAPON_UNARMED",
        "WEAPON_FLASHLIGHT"
    }
}

-- Routing buckets (zones only work in these buckets)
Config.RoutingBuckets = {
    0,  -- Default bucket
    -- Add more buckets here
}

-- UI position (glass shield indicator)
Config.UI = {
    position = {
        bottom = "4%",      -- From bottom
        left = "50%"        -- Centered
    }
}

-- Notifications (auto-detects framework)
Config.Notifications = {
    enabled = true,
    autoDetect = true,     -- Auto-find best notification system
    framework = "x_hud",   -- Manual override if needed
    
    -- X_HUD_Notify settings
    x_hud = {
        enterIcon = "shield-checkmark-outline",
        enterColor = "#2ECC71",     -- Green
        exitIcon = "shield-outline",
        exitColor = "#E74C3C",      -- Red
        speedIcon = "speedometer-outline",
        speedColor = "#F39C12"      -- Orange
    }
}

Last updated