From fb2225e373de01a0b44adc8996702f2776b96947 Mon Sep 17 00:00:00 2001 From: Linden <65407488+thelindat@users.noreply.github.com> Date: Tue, 18 Mar 2025 18:46:09 +1100 Subject: [PATCH] chore: add copyright notices to each file Some people accidentally, mistakenly, and without any malicious intent forget to attribute code from this resource to its source. This change will hopefully assist people, so that they do not make that mistake again. --- imports/__addCommand/server.lua | 8 + imports/addCommand/server.lua | 8 + imports/addKeybind/client.lua | 8 + imports/array/shared.lua | 8 + imports/callback/client.lua | 8 + imports/callback/server.lua | 8 + imports/class/shared.lua | 8 + imports/cron/server.lua | 8 + imports/disableControls/client.lua | 8 + imports/dui/client.lua | 8 + imports/getClosestObject/shared.lua | 8 + imports/getClosestPed/shared.lua | 8 + imports/getClosestPlayer/client.lua | 8 + imports/getClosestPlayer/server.lua | 8 + imports/getClosestVehicle/shared.lua | 8 + imports/getFilesInDirectory/server.lua | 8 + imports/getNearbyObjects/shared.lua | 8 + imports/getNearbyPeds/shared.lua | 8 + imports/getNearbyPlayers/client.lua | 8 + imports/getNearbyPlayers/server.lua | 8 + imports/getNearbyVehicles/shared.lua | 8 + imports/getRelativeCoords/shared.lua | 8 + imports/locale/shared.lua | 8 + imports/logger/server.lua | 8 + imports/marker/client.lua | 338 +++++++++--------- imports/math/shared.lua | 8 + imports/playAnim/client.lua | 8 + imports/points/client.lua | 8 + imports/print/shared.lua | 8 + imports/raycast/client.lua | 8 + imports/requestAnimDict/client.lua | 8 + imports/requestAnimSet/client.lua | 8 + imports/requestAudioBank/client.lua | 8 + imports/requestModel/client.lua | 8 + imports/requestNamedPtfxAsset/client.lua | 8 + imports/requestScaleformMovie/client.lua | 8 + imports/requestStreamedTextureDict/client.lua | 8 + imports/requestWeaponAsset/client.lua | 8 + imports/require/shared.lua | 8 + imports/scaleform/client.lua | 8 + imports/streamingRequest/client.lua | 8 + imports/string/shared.lua | 8 + imports/table/shared.lua | 8 + imports/timer/shared.lua | 8 + imports/triggerClientEvent/server.lua | 8 + imports/waitFor/shared.lua | 8 + imports/zones/shared.lua | 8 + init.lua | 10 +- resource/acl/server.lua | 8 + resource/cache/client.lua | 8 + resource/callbacks/shared.lua | 8 + resource/client.lua | 8 + resource/interface/client/alert.lua | 8 + resource/interface/client/clipboard.lua | 10 +- resource/interface/client/context.lua | 8 + resource/interface/client/input.lua | 8 + resource/interface/client/main.lua | 8 + resource/interface/client/menu.lua | 8 + resource/interface/client/notify.lua | 8 + resource/interface/client/progress.lua | 8 + resource/interface/client/radial.lua | 8 + resource/interface/client/skillcheck.lua | 8 + resource/interface/client/textui.lua | 10 +- resource/interface/server/txadmin.lua | 8 + resource/locale/client.lua | 8 + resource/locale/server.lua | 8 + resource/vehicleProperties/client.lua | 8 + resource/vehicleProperties/server.lua | 8 + resource/version/server.lua | 8 + resource/version/shared.lua | 8 + resource/zoneCreator/client.lua | 8 + resource/zoneCreator/server.lua | 41 +-- 72 files changed, 739 insertions(+), 206 deletions(-) diff --git a/imports/__addCommand/server.lua b/imports/__addCommand/server.lua index 4fc32df..7d511fb 100644 --- a/imports/__addCommand/server.lua +++ b/imports/__addCommand/server.lua @@ -1,6 +1,14 @@ -- DO NOT USE! Old syntax for addCommand (prior to v3.0) ---@todo convert input and call standard function? +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local commands = {} SetTimeout(1000, function() diff --git a/imports/addCommand/server.lua b/imports/addCommand/server.lua index da5f90e..4191424 100644 --- a/imports/addCommand/server.lua +++ b/imports/addCommand/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class OxCommandParams ---@field name string ---@field help? string diff --git a/imports/addKeybind/client.lua b/imports/addKeybind/client.lua index 4c6909d..a6d123a 100644 --- a/imports/addKeybind/client.lua +++ b/imports/addKeybind/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + if cache.game == 'redm' then return end ---@class KeybindProps diff --git a/imports/array/shared.lua b/imports/array/shared.lua index 28a3d6b..0f0151d 100644 --- a/imports/array/shared.lua +++ b/imports/array/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class Array : OxClass, { [number]: T } lib.array = lib.class('Array') diff --git a/imports/callback/client.lua b/imports/callback/client.lua index 8b20380..bc355e9 100644 --- a/imports/callback/client.lua +++ b/imports/callback/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local pendingCallbacks = {} local timers = {} local cbEvent = '__ox_cb_%s' diff --git a/imports/callback/server.lua b/imports/callback/server.lua index 41eb346..bd1b313 100644 --- a/imports/callback/server.lua +++ b/imports/callback/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local pendingCallbacks = {} local cbEvent = '__ox_cb_%s' local callbackTimeout = GetConvarInt('ox:callbackTimeout', 300000) diff --git a/imports/class/shared.lua b/imports/class/shared.lua index a089df0..d85a327 100644 --- a/imports/class/shared.lua +++ b/imports/class/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@diagnostic disable: invisible local getinfo = debug.getinfo diff --git a/imports/cron/server.lua b/imports/cron/server.lua index ce95b4b..78e0287 100644 --- a/imports/cron/server.lua +++ b/imports/cron/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + lib.cron = {} ---@alias Date { year: number, month: number, day: number, hour: number, min: number, sec: number, wday: number, yday: number, isdst: boolean } diff --git a/imports/disableControls/client.lua b/imports/disableControls/client.lua index 1f8a26f..c2afb3c 100644 --- a/imports/disableControls/client.lua +++ b/imports/disableControls/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + --- Call on frame to disable all stored keys. --- ``` --- disableControls() diff --git a/imports/dui/client.lua b/imports/dui/client.lua index 6d464df..493d879 100644 --- a/imports/dui/client.lua +++ b/imports/dui/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class DuiProperties ---@field url string ---@field width number diff --git a/imports/getClosestObject/shared.lua b/imports/getClosestObject/shared.lua index ead1dfe..f810ef5 100644 --- a/imports/getClosestObject/shared.lua +++ b/imports/getClosestObject/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@return number? object diff --git a/imports/getClosestPed/shared.lua b/imports/getClosestPed/shared.lua index a00974b..1ab0c0a 100644 --- a/imports/getClosestPed/shared.lua +++ b/imports/getClosestPed/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@return number? ped diff --git a/imports/getClosestPlayer/client.lua b/imports/getClosestPlayer/client.lua index 249ee5b..df15e2d 100644 --- a/imports/getClosestPlayer/client.lua +++ b/imports/getClosestPlayer/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@param includePlayer? boolean Whether or not to include the current player. diff --git a/imports/getClosestPlayer/server.lua b/imports/getClosestPlayer/server.lua index f600e74..4683e8a 100644 --- a/imports/getClosestPlayer/server.lua +++ b/imports/getClosestPlayer/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@return number? playerId diff --git a/imports/getClosestVehicle/shared.lua b/imports/getClosestVehicle/shared.lua index dc7d717..1d3f9af 100644 --- a/imports/getClosestVehicle/shared.lua +++ b/imports/getClosestVehicle/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@param includePlayerVehicle? boolean Whether or not to include the player's current vehicle. Ignored on the server. diff --git a/imports/getFilesInDirectory/server.lua b/imports/getFilesInDirectory/server.lua index 7e10157..10ac8b5 100644 --- a/imports/getFilesInDirectory/server.lua +++ b/imports/getFilesInDirectory/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param path string ---@param pattern string ---@return table string[] diff --git a/imports/getNearbyObjects/shared.lua b/imports/getNearbyObjects/shared.lua index 17054a0..ae735e4 100644 --- a/imports/getNearbyObjects/shared.lua +++ b/imports/getNearbyObjects/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@return { object: number, coords: vector3 }[] diff --git a/imports/getNearbyPeds/shared.lua b/imports/getNearbyPeds/shared.lua index 4abd6c8..0417112 100644 --- a/imports/getNearbyPeds/shared.lua +++ b/imports/getNearbyPeds/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@return { ped: number, coords: vector3 }[] diff --git a/imports/getNearbyPlayers/client.lua b/imports/getNearbyPlayers/client.lua index 5e4a0c7..8388715 100644 --- a/imports/getNearbyPlayers/client.lua +++ b/imports/getNearbyPlayers/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@param includePlayer? boolean Whether or not to include the current player. diff --git a/imports/getNearbyPlayers/server.lua b/imports/getNearbyPlayers/server.lua index 20f2b28..6257e44 100644 --- a/imports/getNearbyPlayers/server.lua +++ b/imports/getNearbyPlayers/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@return { id: number, ped: number, coords: vector3 }[] diff --git a/imports/getNearbyVehicles/shared.lua b/imports/getNearbyVehicles/shared.lua index 2c38c71..b83ae7b 100644 --- a/imports/getNearbyVehicles/shared.lua +++ b/imports/getNearbyVehicles/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param coords vector3 The coords to check from. ---@param maxDistance? number The max distance to check. ---@param includePlayerVehicle? boolean Whether or not to include the player's current vehicle. diff --git a/imports/getRelativeCoords/shared.lua b/imports/getRelativeCoords/shared.lua index 238f34b..6366399 100644 --- a/imports/getRelativeCoords/shared.lua +++ b/imports/getRelativeCoords/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local glm_sincos = require 'glm'.sincos --[[@as fun(n: number): number, number]] local glm_rad = require 'glm'.rad --[[@as fun(n: number): number]] diff --git a/imports/locale/shared.lua b/imports/locale/shared.lua index e78d54d..e91ceb4 100644 --- a/imports/locale/shared.lua +++ b/imports/locale/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@type { [string]: string } local dict = {} diff --git a/imports/logger/server.lua b/imports/logger/server.lua index 460165a..a36832d 100644 --- a/imports/logger/server.lua +++ b/imports/logger/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local service = GetConvar('ox:logger', 'datadog') local buffer local bufferSize = 0 diff --git a/imports/marker/client.lua b/imports/marker/client.lua index b8b5ef6..f0705d5 100644 --- a/imports/marker/client.lua +++ b/imports/marker/client.lua @@ -1,165 +1,173 @@ ----@diagnostic disable: param-type-mismatch -lib.marker = {} - -local defaultRotation = vector3(0, 0, 0) -local defaultDirection = vector3(0, 0, 0) -local defaultColor = { r = 255, g = 255, b = 255, a = 100 } -local defaultSize = { width = 2, height = 1 } -local defaultTextureDict = nil -local defaultTextureName = nil - -local markerTypesMap = { - UpsideDownCone = 0, - VerticalCylinder = 1, - ThickChevronUp = 2, - ThinChevronUp = 3, - CheckeredFlagRect = 4, - CheckeredFlagCircle = 5, - VerticleCircle = 6, - PlaneModel = 7, - LostMCTransparent = 8, - LostMC = 9, - Number0 = 10, - Number1 = 11, - Number2 = 12, - Number3 = 13, - Number4 = 14, - Number5 = 15, - Number6 = 16, - Number7 = 17, - Number8 = 18, - Number9 = 19, - ChevronUpx1 = 20, - ChevronUpx2 = 21, - ChevronUpx3 = 22, - HorizontalCircleFat = 23, - ReplayIcon = 24, - HorizontalCircleSkinny = 25, - HorizontalCircleSkinny_Arrow = 26, - HorizontalSplitArrowCircle = 27, - DebugSphere = 28, - DollarSign = 29, - HorizontalBars = 30, - WolfHead = 31, - QuestionMark = 32, - PlaneSymbol = 33, - HelicopterSymbol = 34, - BoatSymbol = 35, - CarSymbol = 36, - MotorcycleSymbol = 37, - BikeSymbol = 38, - TruckSymbol = 39, - ParachuteSymbol = 40, - Unknown41 = 41, - SawbladeSymbol = 42, - Unknown43 = 43, -} - ----@alias MarkerType ----| "UpsideDownCone" ----| "VerticalCylinder" ----| "ThickChevronUp" ----| "ThinChevronUp" ----| "CheckeredFlagRect" ----| "CheckeredFlagCircle" ----| "VerticleCircle" ----| "PlaneModel" ----| "LostMCTransparent" ----| "LostMC" ----| "Number0" ----| "Number1" ----| "Number2" ----| "Number3" ----| "Number4" ----| "Number5" ----| "Number6" ----| "Number7" ----| "Number8" ----| "Number9" ----| "ChevronUpx1" ----| "ChevronUpx2" ----| "ChevronUpx3" ----| "HorizontalCircleFat" ----| "ReplayIcon" ----| "HorizontalCircleSkinny" ----| "HorizontalCircleSkinny_Arrow" ----| "HorizontalSplitArrowCircle" ----| "DebugSphere" ----| "DollarSign" ----| "HorizontalBars" ----| "WolfHead" ----| "QuestionMark" ----| "PlaneSymbol" ----| "HelicopterSymbol" ----| "BoatSymbol" ----| "CarSymbol" ----| "MotorcycleSymbol" ----| "BikeSymbol" ----| "TruckSymbol" ----| "ParachuteSymbol" ----| "Unknown41" ----| "SawbladeSymbol" ----| "Unknown43" - ----@class MarkerProps ----@field type MarkerType | number ----@field coords { x: number, y: number, z: number } ----@field width? number ----@field height? number ----@field color? { r: number, g: number, b: number, a: number } ----@field rotation? { x: number, y: number, z: number } ----@field direction? { x: number, y: number, z: number } ----@field bobUpAndDown? boolean ----@field faceCamera? boolean ----@field rotate? boolean ----@field textureDict? string ----@field textureName? string - ----@param self MarkerProps -local function drawMarker(self) - DrawMarker( - self.type, - self.coords.x, self.coords.y, self.coords.z, - self.direction.x, self.direction.y, self.direction.z, - self.rotation.x, self.rotation.y, self.rotation.z, - self.width, self.width, self.height, - self.color.r, self.color.g, self.color.b, self.color.a, - self.bobUpAndDown, self.faceCamera, 2, self.rotate, self.textureDict, self.textureName, false) -end - ----@param options MarkerProps -function lib.marker.new(options) - local markerType - if type(options.type) == "string" then - markerType = markerTypesMap[options.type] - if markerType == nil then - error(("unknown marker type '%s'"):format(options.type)) - end - elseif type(options.type) == "number" then - markerType = options.type - else - error(("expected marker type to have type 'string' or 'number' (received %s)"):format(type(options.type))) - end - - local self = {} - self.type = markerType - self.coords = options.coords - self.color = options.color or defaultColor - self.width = options.width or defaultSize.width - self.height = options.height or defaultSize.height - self.rotation = options.rotation or defaultRotation - self.direction = options.direction or defaultDirection - self.bobUpAndDown = type(options.bobUpAndDown) == 'boolean' and options.bobUpAndDown - self.faceCamera = type(options.faceCamera) ~= 'boolean' or options.faceCamera - self.rotate = type(options.rotate) == 'boolean' and options.rotate - self.textureDict = options.textureDict or defaultTextureDict - self.textureName = options.textureName or defaultTextureName - self.draw = drawMarker - - self.width += 0.0 - self.height += 0.0 - - return self -end - -return lib.marker +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + +---@diagnostic disable: param-type-mismatch +lib.marker = {} + +local defaultRotation = vector3(0, 0, 0) +local defaultDirection = vector3(0, 0, 0) +local defaultColor = { r = 255, g = 255, b = 255, a = 100 } +local defaultSize = { width = 2, height = 1 } +local defaultTextureDict = nil +local defaultTextureName = nil + +local markerTypesMap = { + UpsideDownCone = 0, + VerticalCylinder = 1, + ThickChevronUp = 2, + ThinChevronUp = 3, + CheckeredFlagRect = 4, + CheckeredFlagCircle = 5, + VerticleCircle = 6, + PlaneModel = 7, + LostMCTransparent = 8, + LostMC = 9, + Number0 = 10, + Number1 = 11, + Number2 = 12, + Number3 = 13, + Number4 = 14, + Number5 = 15, + Number6 = 16, + Number7 = 17, + Number8 = 18, + Number9 = 19, + ChevronUpx1 = 20, + ChevronUpx2 = 21, + ChevronUpx3 = 22, + HorizontalCircleFat = 23, + ReplayIcon = 24, + HorizontalCircleSkinny = 25, + HorizontalCircleSkinny_Arrow = 26, + HorizontalSplitArrowCircle = 27, + DebugSphere = 28, + DollarSign = 29, + HorizontalBars = 30, + WolfHead = 31, + QuestionMark = 32, + PlaneSymbol = 33, + HelicopterSymbol = 34, + BoatSymbol = 35, + CarSymbol = 36, + MotorcycleSymbol = 37, + BikeSymbol = 38, + TruckSymbol = 39, + ParachuteSymbol = 40, + Unknown41 = 41, + SawbladeSymbol = 42, + Unknown43 = 43, +} + +---@alias MarkerType +---| "UpsideDownCone" +---| "VerticalCylinder" +---| "ThickChevronUp" +---| "ThinChevronUp" +---| "CheckeredFlagRect" +---| "CheckeredFlagCircle" +---| "VerticleCircle" +---| "PlaneModel" +---| "LostMCTransparent" +---| "LostMC" +---| "Number0" +---| "Number1" +---| "Number2" +---| "Number3" +---| "Number4" +---| "Number5" +---| "Number6" +---| "Number7" +---| "Number8" +---| "Number9" +---| "ChevronUpx1" +---| "ChevronUpx2" +---| "ChevronUpx3" +---| "HorizontalCircleFat" +---| "ReplayIcon" +---| "HorizontalCircleSkinny" +---| "HorizontalCircleSkinny_Arrow" +---| "HorizontalSplitArrowCircle" +---| "DebugSphere" +---| "DollarSign" +---| "HorizontalBars" +---| "WolfHead" +---| "QuestionMark" +---| "PlaneSymbol" +---| "HelicopterSymbol" +---| "BoatSymbol" +---| "CarSymbol" +---| "MotorcycleSymbol" +---| "BikeSymbol" +---| "TruckSymbol" +---| "ParachuteSymbol" +---| "Unknown41" +---| "SawbladeSymbol" +---| "Unknown43" + +---@class MarkerProps +---@field type MarkerType | number +---@field coords { x: number, y: number, z: number } +---@field width? number +---@field height? number +---@field color? { r: number, g: number, b: number, a: number } +---@field rotation? { x: number, y: number, z: number } +---@field direction? { x: number, y: number, z: number } +---@field bobUpAndDown? boolean +---@field faceCamera? boolean +---@field rotate? boolean +---@field textureDict? string +---@field textureName? string + +---@param self MarkerProps +local function drawMarker(self) + DrawMarker( + self.type, + self.coords.x, self.coords.y, self.coords.z, + self.direction.x, self.direction.y, self.direction.z, + self.rotation.x, self.rotation.y, self.rotation.z, + self.width, self.width, self.height, + self.color.r, self.color.g, self.color.b, self.color.a, + self.bobUpAndDown, self.faceCamera, 2, self.rotate, self.textureDict, self.textureName, false) +end + +---@param options MarkerProps +function lib.marker.new(options) + local markerType + if type(options.type) == "string" then + markerType = markerTypesMap[options.type] + if markerType == nil then + error(("unknown marker type '%s'"):format(options.type)) + end + elseif type(options.type) == "number" then + markerType = options.type + else + error(("expected marker type to have type 'string' or 'number' (received %s)"):format(type(options.type))) + end + + local self = {} + self.type = markerType + self.coords = options.coords + self.color = options.color or defaultColor + self.width = options.width or defaultSize.width + self.height = options.height or defaultSize.height + self.rotation = options.rotation or defaultRotation + self.direction = options.direction or defaultDirection + self.bobUpAndDown = type(options.bobUpAndDown) == 'boolean' and options.bobUpAndDown + self.faceCamera = type(options.faceCamera) ~= 'boolean' or options.faceCamera + self.rotate = type(options.rotate) == 'boolean' and options.rotate + self.textureDict = options.textureDict or defaultTextureDict + self.textureName = options.textureName or defaultTextureName + self.draw = drawMarker + + self.width += 0.0 + self.height += 0.0 + + return self +end + +return lib.marker diff --git a/imports/math/shared.lua b/imports/math/shared.lua index bdc38a5..5d0f689 100644 --- a/imports/math/shared.lua +++ b/imports/math/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class oxmath : mathlib lib.math = math diff --git a/imports/playAnim/client.lua b/imports/playAnim/client.lua index 59e2237..52137af 100644 --- a/imports/playAnim/client.lua +++ b/imports/playAnim/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@alias AnimationFlags number ---| 0 DEFAULT ---| 1 LOOPING diff --git a/imports/points/client.lua b/imports/points/client.lua index e763523..f6cd79d 100644 --- a/imports/points/client.lua +++ b/imports/points/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class PointProperties ---@field coords vector3 ---@field distance number diff --git a/imports/print/shared.lua b/imports/print/shared.lua index 38d7ff1..3874381 100644 --- a/imports/print/shared.lua +++ b/imports/print/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@enum PrintLevel local printLevel = { error = 1, diff --git a/imports/raycast/client.lua b/imports/raycast/client.lua index 6dec52a..1ee3bd1 100644 --- a/imports/raycast/client.lua +++ b/imports/raycast/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + lib.raycast = {} local StartShapeTestLosProbe = StartShapeTestLosProbe diff --git a/imports/requestAnimDict/client.lua b/imports/requestAnimDict/client.lua index 51ea5fd..46bd98f 100644 --- a/imports/requestAnimDict/client.lua +++ b/imports/requestAnimDict/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Load an animation dictionary. When called from a thread, it will yield until it has loaded. ---@param animDict string ---@param timeout number? Approximate milliseconds to wait for the dictionary to load. Default is 10000. diff --git a/imports/requestAnimSet/client.lua b/imports/requestAnimSet/client.lua index 062eab2..5ba9f4a 100644 --- a/imports/requestAnimSet/client.lua +++ b/imports/requestAnimSet/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Load an animation clipset. When called from a thread, it will yield until it has loaded. ---@param animSet string ---@param timeout number? Approximate milliseconds to wait for the clipset to load. Default is 10000. diff --git a/imports/requestAudioBank/client.lua b/imports/requestAudioBank/client.lua index 419681d..9047a9a 100644 --- a/imports/requestAudioBank/client.lua +++ b/imports/requestAudioBank/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Loads an audio bank. ---@param audioBank string ---@param timeout number? diff --git a/imports/requestModel/client.lua b/imports/requestModel/client.lua index 336ef97..ccdc04d 100644 --- a/imports/requestModel/client.lua +++ b/imports/requestModel/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Load a model. When called from a thread, it will yield until it has loaded. ---@param model number | string ---@param timeout number? Approximate milliseconds to wait for the model to load. Default is 10000. diff --git a/imports/requestNamedPtfxAsset/client.lua b/imports/requestNamedPtfxAsset/client.lua index ef9451d..2f28b04 100644 --- a/imports/requestNamedPtfxAsset/client.lua +++ b/imports/requestNamedPtfxAsset/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Load a named particle effect. When called from a thread, it will yield until it has loaded. ---@param ptFxName string ---@param timeout number? Approximate milliseconds to wait for the particle effect to load. Default is 10000. diff --git a/imports/requestScaleformMovie/client.lua b/imports/requestScaleformMovie/client.lua index 70e3a3c..3fe58ec 100644 --- a/imports/requestScaleformMovie/client.lua +++ b/imports/requestScaleformMovie/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Load a scaleform movie. When called from a thread, it will yield until it has loaded. ---@param scaleformName string ---@param timeout number? Approximate milliseconds to wait for the scaleform movie to load. Default is 1000. diff --git a/imports/requestStreamedTextureDict/client.lua b/imports/requestStreamedTextureDict/client.lua index eefe75c..cab482b 100644 --- a/imports/requestStreamedTextureDict/client.lua +++ b/imports/requestStreamedTextureDict/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Load a texture dictionary. When called from a thread, it will yield until it has loaded. ---@param textureDict string ---@param timeout number? Approximate milliseconds to wait for the dictionary to load. Default is 10000. diff --git a/imports/requestWeaponAsset/client.lua b/imports/requestWeaponAsset/client.lua index 61965c0..e02c823 100644 --- a/imports/requestWeaponAsset/client.lua +++ b/imports/requestWeaponAsset/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@alias WeaponResourceFlags ---| 1 WRF_REQUEST_BASE_ANIMS ---| 2 WRF_REQUEST_COVER_ANIMS diff --git a/imports/require/shared.lua b/imports/require/shared.lua index 54373d3..ee16dc4 100644 --- a/imports/require/shared.lua +++ b/imports/require/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local loaded = {} local _require = require diff --git a/imports/scaleform/client.lua b/imports/scaleform/client.lua index fd18094..46cd9f0 100644 --- a/imports/scaleform/client.lua +++ b/imports/scaleform/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class renderTargetTable ---@field name string ---@field model string | number diff --git a/imports/streamingRequest/client.lua b/imports/streamingRequest/client.lua index 0a72b12..0a5dae3 100644 --- a/imports/streamingRequest/client.lua +++ b/imports/streamingRequest/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@async ---@generic T : string | number ---@param request function diff --git a/imports/string/shared.lua b/imports/string/shared.lua index a6579b3..bd4760f 100644 --- a/imports/string/shared.lua +++ b/imports/string/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class oxstring : stringlib lib.string = string diff --git a/imports/table/shared.lua b/imports/table/shared.lua index d35c2f7..dfea3c7 100644 --- a/imports/table/shared.lua +++ b/imports/table/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + -- Add additional functions to the standard table library ---@class oxtable : tablelib diff --git a/imports/timer/shared.lua b/imports/timer/shared.lua index f39daae..d652881 100644 --- a/imports/timer/shared.lua +++ b/imports/timer/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class TimerPrivateProps ---@field initialTime number the initial duration of the timer. ---@field async? boolean wether the timer should run asynchronously or not diff --git a/imports/triggerClientEvent/server.lua b/imports/triggerClientEvent/server.lua index fc49af0..18e1c8b 100644 --- a/imports/triggerClientEvent/server.lua +++ b/imports/triggerClientEvent/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Triggers an event for the given playerIds, sending additional parameters as arguments.\ ---Implements functionality from [this pending pull request](https://github.com/citizenfx/fivem/pull/1210) and may be deprecated. --- diff --git a/imports/waitFor/shared.lua b/imports/waitFor/shared.lua index 2470562..c519015 100644 --- a/imports/waitFor/shared.lua +++ b/imports/waitFor/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---Yields the current thread until a non-nil value is returned by the function. ---@generic T ---@param cb fun(): T? diff --git a/imports/zones/shared.lua b/imports/zones/shared.lua index 24cb075..67a0103 100644 --- a/imports/zones/shared.lua +++ b/imports/zones/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local glm = require 'glm' ---@class ZoneProperties diff --git a/init.lua b/init.lua index c96c29d..7759e51 100644 --- a/init.lua +++ b/init.lua @@ -1,7 +1,11 @@ ---@meta ----ox_lib ----Copyright (C) 2021 Linden ----LGPL-3.0-or-later +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] if not _VERSION:find('5.4') then error('Lua 5.4 must be enabled in the resource manifest!', 2) diff --git a/resource/acl/server.lua b/resource/acl/server.lua index d233636..6c12469 100644 --- a/resource/acl/server.lua +++ b/resource/acl/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local function allowAce(allow) return allow == false and 'deny' or 'allow' end diff --git a/resource/cache/client.lua b/resource/cache/client.lua index 6a8e585..4e60bc7 100644 --- a/resource/cache/client.lua +++ b/resource/cache/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local cache = _ENV.cache cache.playerId = PlayerId() cache.serverId = GetPlayerServerId(cache.playerId) diff --git a/resource/callbacks/shared.lua b/resource/callbacks/shared.lua index b7788cb..3aeb6cb 100644 --- a/resource/callbacks/shared.lua +++ b/resource/callbacks/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local registeredCallbacks = {} AddEventHandler('onResourceStop', function(resourceName) diff --git a/resource/client.lua b/resource/client.lua index 78e5865..fa756f8 100644 --- a/resource/client.lua +++ b/resource/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local _registerCommand = RegisterCommand ---@param commandName string diff --git a/resource/interface/client/alert.lua b/resource/interface/client/alert.lua index 76d42fc..3726732 100644 --- a/resource/interface/client/alert.lua +++ b/resource/interface/client/alert.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@type promise? local alert = nil local alertId = 0 diff --git a/resource/interface/client/clipboard.lua b/resource/interface/client/clipboard.lua index 984c319..a5fe69a 100644 --- a/resource/interface/client/clipboard.lua +++ b/resource/interface/client/clipboard.lua @@ -1,7 +1,15 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param value string function lib.setClipboard(value) SendNUIMessage({ action = 'setClipboard', data = value }) -end \ No newline at end of file +end diff --git a/resource/interface/client/context.lua b/resource/interface/client/context.lua index 7d4dbcf..dda90d9 100644 --- a/resource/interface/client/context.lua +++ b/resource/interface/client/context.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local contextMenus = {} local openContextMenu = nil diff --git a/resource/interface/client/input.lua b/resource/interface/client/input.lua index 549e318..052f335 100644 --- a/resource/interface/client/input.lua +++ b/resource/interface/client/input.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local input ---@class InputDialogRowProps diff --git a/resource/interface/client/main.lua b/resource/interface/client/main.lua index 7ee309b..f90a5ad 100644 --- a/resource/interface/client/main.lua +++ b/resource/interface/client/main.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@alias IconProp 'fas' | 'far' | 'fal' | 'fat' | 'fad' | 'fab' | 'fak' | 'fass' local keepInput = IsNuiFocusKeepingInput() diff --git a/resource/interface/client/menu.lua b/resource/interface/client/menu.lua index d055695..3019a6d 100644 --- a/resource/interface/client/menu.lua +++ b/resource/interface/client/menu.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@type { [string]: MenuProps } local registeredMenus = {} ---@type MenuProps | nil diff --git a/resource/interface/client/notify.lua b/resource/interface/client/notify.lua index 7f97cc7..8c04bc7 100644 --- a/resource/interface/client/notify.lua +++ b/resource/interface/client/notify.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@alias NotificationPosition 'top' | 'top-right' | 'top-left' | 'bottom' | 'bottom-right' | 'bottom-left' | 'center-right' | 'center-left' ---@alias NotificationType 'info' | 'warning' | 'success' | 'error' ---@alias IconAnimationType 'spin' | 'spinPulse' | 'spinReverse' | 'pulse' | 'beat' | 'fade' | 'beatFade' | 'bounce' | 'shake' diff --git a/resource/interface/client/progress.lua b/resource/interface/client/progress.lua index 43779b6..4d0fee0 100644 --- a/resource/interface/client/progress.lua +++ b/resource/interface/client/progress.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local progress local DisableControlAction = DisableControlAction local DisablePlayerFiring = DisablePlayerFiring diff --git a/resource/interface/client/radial.lua b/resource/interface/client/radial.lua index 2649d73..53408b2 100644 --- a/resource/interface/client/radial.lua +++ b/resource/interface/client/radial.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class RadialItem ---@field icon string | {[1]: IconProp, [2]: string}; ---@field label string diff --git a/resource/interface/client/skillcheck.lua b/resource/interface/client/skillcheck.lua index a7f3908..5c8f76f 100644 --- a/resource/interface/client/skillcheck.lua +++ b/resource/interface/client/skillcheck.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@type promise? local skillcheck diff --git a/resource/interface/client/textui.lua b/resource/interface/client/textui.lua index 26ab240..f8c4687 100644 --- a/resource/interface/client/textui.lua +++ b/resource/interface/client/textui.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@class TextUIOptions ---@field position? 'right-center' | 'left-center' | 'top-center' | 'bottom-center'; ---@field icon? string | {[1]: IconProp, [2]: string}; @@ -38,4 +46,4 @@ end ---@return boolean, string | nil function lib.isTextUIOpen() return isOpen, currentText -end \ No newline at end of file +end diff --git a/resource/interface/server/txadmin.lua b/resource/interface/server/txadmin.lua index 259efc6..b6697d0 100644 --- a/resource/interface/server/txadmin.lua +++ b/resource/interface/server/txadmin.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + if GetConvarInt('ox:txAdminNotifications', 0) == 0 then return end if GetConvarInt('txAdmin-hideDefaultAnnouncement', 0) == 1 then diff --git a/resource/locale/client.lua b/resource/locale/client.lua index baaebfc..5d16edd 100644 --- a/resource/locale/client.lua +++ b/resource/locale/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local settings = require 'resource.settings' local function loadLocaleFile(key) diff --git a/resource/locale/server.lua b/resource/locale/server.lua index 552696f..0988bc9 100644 --- a/resource/locale/server.lua +++ b/resource/locale/server.lua @@ -1 +1,9 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + function lib.getLocaleKey() return GetConvar('ox:locale', 'en') end diff --git a/resource/vehicleProperties/client.lua b/resource/vehicleProperties/client.lua index c930624..79b2844 100644 --- a/resource/vehicleProperties/client.lua +++ b/resource/vehicleProperties/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + if cache.game == 'redm' then return end ---@class VehicleProperties diff --git a/resource/vehicleProperties/server.lua b/resource/vehicleProperties/server.lua index 39faf7d..b738130 100644 --- a/resource/vehicleProperties/server.lua +++ b/resource/vehicleProperties/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + ---@param vehicle number ---@param props VehicleProperties ---@diagnostic disable-next-line: duplicate-set-field diff --git a/resource/version/server.lua b/resource/version/server.lua index 87f95d7..b92ab4f 100644 --- a/resource/version/server.lua +++ b/resource/version/server.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + function lib.versionCheck(repository) local resource = GetInvokingResource() or GetCurrentResourceName() diff --git a/resource/version/shared.lua b/resource/version/shared.lua index 737b3c4..4a366dc 100644 --- a/resource/version/shared.lua +++ b/resource/version/shared.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + function lib.checkDependency(resource, minimumVersion, printMessage) local currentVersion = GetResourceMetadata(resource, 'version', 0) currentVersion = currentVersion and currentVersion:match('%d+%.%d+%.%d+') or 'unknown' diff --git a/resource/zoneCreator/client.lua b/resource/zoneCreator/client.lua index 61ba45a..ba6ad44 100644 --- a/resource/zoneCreator/client.lua +++ b/resource/zoneCreator/client.lua @@ -1,3 +1,11 @@ +--[[ + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden +]] + local creatorActive = false local controlsActive = false local zoneType, step, xCoord, yCoord, zCoord, heading, height, width, length diff --git a/resource/zoneCreator/server.lua b/resource/zoneCreator/server.lua index 5b72000..17d9ebf 100644 --- a/resource/zoneCreator/server.lua +++ b/resource/zoneCreator/server.lua @@ -1,40 +1,9 @@ --[[ - -- function -local poly = lib.zones.poly({ - name = poly, - points = { - vec(447.9, -998.8, 25.8), - vec(450.3, -998.2, 25.8), - vec(449.9, -995.5, 25.8), - vec(447.2, -995.6, 25.8), - vec(446.3, -997.9, 25.8), - }, - thickness = 2, -}) - -- array -{ - name = poly, - points = { - vec(447.9, -998.8, 25.8), - vec(450.3, -998.2, 25.8), - vec(449.9, -995.5, 25.8), - vec(447.2, -995.6, 25.8), - vec(446.3, -997.9, 25.8), - }, - thickness = 2, -}, - -- target -exports.ox_target:addPolyZone({ - name = poly, - points = { - vec(447.9, -998.8, 25.8), - vec(450.3, -998.2, 25.8), - vec(449.9, -995.5, 25.8), - vec(447.2, -995.6, 25.8), - vec(446.3, -997.9, 25.8), - }, - thickness = 2, -}) + https://github.com/overextended/ox_lib + + This file is licensed under LGPL-3.0 or higher + + Copyright (c) 2025 Linden ]] local function formatNumber(num)