mirror of
https://github.com/CommunityOx/ox_lib.git
synced 2026-08-17 06:56:03 +01:00
refactor(imports): assign modules directly to lib namespace
Mostly a change for improved intellisense with sumneko lua. Includes some type fixes and deprecation notices.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
--[[
|
||||
This module was experimental and won't be worked on or used further.
|
||||
May be removed in the future.
|
||||
]]
|
||||
|
||||
local CPlayer = {}
|
||||
|
||||
function CPlayer:__index(index, ...)
|
||||
@@ -23,13 +28,11 @@ function CPlayer:getDistance(coords)
|
||||
end
|
||||
|
||||
function CPlayer:getPed()
|
||||
if update or not self.ped then
|
||||
self.ped = GetPlayerPed(self.source)
|
||||
end
|
||||
|
||||
self.ped = GetPlayerPed(self.source)
|
||||
return self.ped
|
||||
end
|
||||
|
||||
---@deprecated
|
||||
function lib.getPlayer()
|
||||
return CPlayer
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user