Module alt-client
Package: @altmp/altv-types
Classes
Interfaces
Enums
Functions
|
Improve this Doc
View Source
addGxtText(string | number, string)
Declaration
addGxtText(key: string | number, value: string): void
Parameters
Type |
Name |
Description |
string | number |
key |
|
string |
value |
|
|
Improve this Doc
View Source
Declaration
beginScaleformMovieMethodMinimap(methodName: string): boolean
Parameters
Type |
Name |
Description |
string |
methodName |
|
Returns
|
Improve this Doc
View Source
emit<K extends never>(K, Parameters<ICustomEmitEvent[K]>)
Declaration
emit<K extends never>(eventName: K, ...args: Parameters<ICustomEmitEvent[K]>): void
Parameters
|
Improve this Doc
View Source
emit<K extends string>(Exclude<K, keyof IClientEvent>, any[])
Declaration
emit<K extends string>(eventName: Exclude<K, keyof IClientEvent>, ...args: any[]): void
Parameters
Type |
Name |
Description |
Exclude<K, keyof IClientEvent> |
eventName |
|
any[] |
args |
|
|
Improve this Doc
View Source
emitRaw<K extends never>(K, Parameters<ICustomEmitEvent[K]>)
Declaration
emitRaw<K extends never>(eventName: K, ...args: Parameters<ICustomEmitEvent[K]>): void
Parameters
|
Improve this Doc
View Source
emitRaw<K extends string>(Exclude<K, keyof IClientEvent>, any[])
Declaration
emitRaw<K extends string>(eventName: Exclude<K, keyof IClientEvent>, ...args: any[]): void
Parameters
Type |
Name |
Description |
Exclude<K, keyof IClientEvent> |
eventName |
|
any[] |
args |
|
|
Improve this Doc
View Source
emitServer<K extends never>(K, Parameters<ICustomClientServerEvent[K]>)
Declaration
emitServer<K extends never>(eventName: K, ...args: Parameters<ICustomClientServerEvent[K]>): void
Parameters
|
Improve this Doc
View Source
emitServer<K extends string>(Exclude<K, never>, any[])
Declaration
emitServer<K extends string>(eventName: Exclude<K, never>, ...args: any[]): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
eventName |
|
any[] |
args |
|
|
Improve this Doc
View Source
emitServerRaw<K extends never>(K, Parameters<ICustomClientServerEvent[K]>)
Declaration
emitServerRaw<K extends never>(eventName: K, ...args: Parameters<ICustomClientServerEvent[K]>): void
Parameters
|
Improve this Doc
View Source
emitServerRaw<K extends string>(Exclude<K, never>, any[])
Declaration
emitServerRaw<K extends string>(eventName: Exclude<K, never>, ...args: any[]): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
eventName |
|
any[] |
args |
|
|
Improve this Doc
View Source
emitServerUnreliable<K extends never>(K, Parameters<ICustomClientServerEvent[K]>)
Declaration
emitServerUnreliable<K extends never>(eventName: K, ...args: Parameters<ICustomClientServerEvent[K]>): void
Parameters
|
Improve this Doc
View Source
emitServerUnreliable<K extends string>(Exclude<K, never>, any[])
Declaration
emitServerUnreliable<K extends string>(eventName: Exclude<K, never>, ...args: any[]): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
eventName |
|
any[] |
args |
|
|
Improve this Doc
View Source
emitRpc<K extends never>(K, Parameters<ICustomClientServerRpc[K]>)
Declaration
emitRpc<K extends never>(rpcName: K, ...args: Parameters<ICustomClientServerRpc[K]>): Promise<ReturnType<shared.ICustomClientServerRpc[K]>>
Parameters
Returns
|
Improve this Doc
View Source
emitRpc<K extends string>(Exclude<K, never>, any[])
Declaration
emitRpc<K extends string>(rpcName: Exclude<K, never>, ...args: any[]): Promise<any>
Parameters
Type |
Name |
Description |
Exclude<K, never> |
rpcName |
|
any[] |
args |
|
Returns
Type |
Description |
Promise<any> |
|
|
Improve this Doc
View Source
onRpc<K extends never>(K, (...args: Parameters<ICustomServerClientRpc[K]>) => ReturnType<ICustomServerClientRpc[K]> | Promise<ReturnType<ICustomServerClientRpc[K]>>)
Declaration
onRpc<K extends never>(rpcName: K, listener: (...args: Parameters<ICustomServerClientRpc[K]>) => ReturnType<ICustomServerClientRpc[K]> | Promise<ReturnType<ICustomServerClientRpc[K]>>): void
Parameters
Type |
Name |
Description |
K |
rpcName |
|
(...args: Parameters<ICustomServerClientRpc[K]>) => ReturnType<ICustomServerClientRpc[K]> | Promise<ReturnType<ICustomServerClientRpc[K]>> |
listener |
|
|
Improve this Doc
View Source
onRpc<K extends string>(Exclude<K, never>, (...args: any[]) => any)
Declaration
onRpc<K extends string>(rpcName: Exclude<K, never>, listener: (...args: any[]) => any): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
rpcName |
|
(...args: any[]) => any |
listener |
|
|
Improve this Doc
View Source
offRpc<K extends never>(K, (...args: Parameters<ICustomServerClientRpc[K]>) => ReturnType<ICustomServerClientRpc[K]> | Promise<ReturnType<ICustomServerClientRpc[K]>>)
Declaration
offRpc<K extends never>(rpcName: K, listener?: (...args: Parameters<ICustomServerClientRpc[K]>) => ReturnType<ICustomServerClientRpc[K]> | Promise<ReturnType<ICustomServerClientRpc[K]>>): void
Parameters
Type |
Name |
Description |
K |
rpcName |
|
(...args: Parameters<ICustomServerClientRpc[K]>) => ReturnType<ICustomServerClientRpc[K]> | Promise<ReturnType<ICustomServerClientRpc[K]>> |
listener |
|
|
Improve this Doc
View Source
offRpc<K extends string>(Exclude<K, never>, (...args: any[]) => any)
Declaration
offRpc<K extends string>(rpcName: Exclude<K, never>, listener?: (...args: any[]) => any): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
rpcName |
|
(...args: any[]) => any |
listener |
|
|
Improve this Doc
View Source
gameControlsEnabled()
Declaration
gameControlsEnabled(): boolean
Returns
|
Improve this Doc
View Source
getCursorPos(boolean)
Declaration
getCursorPos(normalized?: boolean): shared.Vector2
Parameters
Type |
Name |
Description |
boolean |
normalized |
|
Returns
|
Improve this Doc
View Source
getGxtText(string | number)
Declaration
getGxtText(key: string | number): string | null
Parameters
Type |
Name |
Description |
string | number |
key |
|
Returns
Type |
Description |
string | null |
|
|
Improve this Doc
View Source
getLicenseHash()
Declaration
Returns
|
Improve this Doc
View Source
getLocale()
Declaration
Returns
|
Improve this Doc
View Source
getLocale()
Declaration
Returns
|
Improve this Doc
View Source
getMsPerGameMinute()
Declaration
getMsPerGameMinute(): number
Returns
|
Improve this Doc
View Source
getServerTime()
Declaration
Returns
|
Improve this Doc
View Source
getPermissionState(Permission)
Declaration
getPermissionState(permId: Permission): boolean
Parameters
Returns
|
Improve this Doc
View Source
getPermissionState<T extends number>(T)
Declaration
getPermissionState<T extends number>(permId: T): boolean
Parameters
Type |
Name |
Description |
T |
permId |
|
Returns
|
Improve this Doc
View Source
getStat(StatName)
Declaration
getStat(statName: StatName): number
Parameters
Returns
|
Improve this Doc
View Source
getStat("stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability")
Declaration
getStat(statName: "stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability"): number
Parameters
Type |
Name |
Description |
"stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability" |
statName |
|
Returns
|
Improve this Doc
View Source
isConsoleOpen()
Declaration
Returns
|
Improve this Doc
View Source
isGameFocused()
Declaration
Returns
|
Improve this Doc
View Source
isInStreamerMode()
Declaration
isInStreamerMode(): boolean
Returns
|
Improve this Doc
View Source
isKeyToggled(KeyCode)
Declaration
isKeyToggled(key: KeyCode): boolean
Parameters
Returns
|
Improve this Doc
View Source
isKeyDown(KeyCode)
Declaration
isKeyDown(key: KeyCode): boolean
Parameters
Returns
|
Improve this Doc
View Source
Declaration
Returns
|
Improve this Doc
View Source
isTextureExistInArchetype(number, string)
Declaration
isTextureExistInArchetype(modelHash: number, targetTextureName: string): boolean
Parameters
Type |
Name |
Description |
number |
modelHash |
|
string |
targetTextureName |
|
Returns
|
Improve this Doc
View Source
loadModel(number)
Declaration
loadModel(modelHash: number): void
Parameters
Type |
Name |
Description |
number |
modelHash |
|
|
Improve this Doc
View Source
loadModelAsync(number)
Declaration
loadModelAsync(modelHash: number): void
Parameters
Type |
Name |
Description |
number |
modelHash |
|
|
Improve this Doc
View Source
offServer<K extends never>(K, (...args: Parameters<ICustomServerClientEvent[K]>) => void)
Declaration
offServer<K extends never>(eventName: K, listener: (...args: Parameters<ICustomServerClientEvent[K]>) => void): void
Parameters
Type |
Name |
Description |
K |
eventName |
|
(...args: Parameters<ICustomServerClientEvent[K]>) => void |
listener |
|
|
Improve this Doc
View Source
offServer<K extends string>(Exclude<K, never>, (...args: any[]) => void)
Declaration
offServer<K extends string>(eventName: Exclude<K, never>, listener: (...args: any[]) => void): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
eventName |
|
(...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
offServer(string, (...args: any[]) => void)
Declaration
offServer(eventName: string, listener: (...args: any[]) => void): void
Parameters
Type |
Name |
Description |
string |
eventName |
|
(...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
offServer((eventName: string, ...args: any[]) => void)
Declaration
offServer(listener: (eventName: string, ...args: any[]) => void): void
Parameters
Type |
Name |
Description |
(eventName: string, ...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
on<K extends keyof IClientEvent>(K, (...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void)
Declaration
on<K extends keyof IClientEvent>(eventName: K, listener: (...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void): void
Parameters
Type |
Name |
Description |
K |
eventName |
|
(...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void |
listener |
|
|
Improve this Doc
View Source
on<K extends string>(Exclude<K, keyof IClientEvent>, (...args: any[]) => void)
Declaration
on<K extends string>(eventName: Exclude<K, keyof IClientEvent>, listener: (...args: any[]) => void): void
Parameters
Type |
Name |
Description |
Exclude<K, keyof IClientEvent> |
eventName |
|
(...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
once<K extends keyof IClientEvent>(K, (...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void)
Declaration
once<K extends keyof IClientEvent>(eventName: K, listener: (...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void): void
Parameters
Type |
Name |
Description |
K |
eventName |
|
(...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void |
listener |
|
|
Improve this Doc
View Source
once<K extends string>(Exclude<K, keyof IClientEvent>, (...args: any[]) => void)
Declaration
once<K extends string>(eventName: Exclude<K, keyof IClientEvent>, listener: (...args: any[]) => void): void
Parameters
Type |
Name |
Description |
Exclude<K, keyof IClientEvent> |
eventName |
|
(...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
off<K extends keyof IClientEvent>(K, (...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void)
Declaration
off<K extends keyof IClientEvent>(eventName: K, listener: (...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void): void
Parameters
Type |
Name |
Description |
K |
eventName |
|
(...args: Parameters<K extends keyof IClientEvent ? IClientEvent[K] : K extends never ? ICustomEmitEvent[K] : never>) => void |
listener |
|
|
Improve this Doc
View Source
off<K extends string>(Exclude<K, keyof IClientEvent>, (...args: any[]) => void)
Declaration
off<K extends string>(eventName: Exclude<K, keyof IClientEvent>, listener: (...args: any[]) => void): void
Parameters
Type |
Name |
Description |
Exclude<K, keyof IClientEvent> |
eventName |
|
(...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
onServer<K extends never>(K, (...args: Parameters<ICustomServerClientEvent[K]>) => void)
Declaration
onServer<K extends never>(eventName: K, listener: (...args: Parameters<ICustomServerClientEvent[K]>) => void): void
Parameters
Type |
Name |
Description |
K |
eventName |
|
(...args: Parameters<ICustomServerClientEvent[K]>) => void |
listener |
|
|
Improve this Doc
View Source
onServer<K extends string>(Exclude<K, never>, (...args: any[]) => void)
Declaration
onServer<K extends string>(eventName: Exclude<K, never>, listener: (...args: any[]) => void): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
eventName |
|
(...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
onServer((eventName: string, ...args: any[]) => void)
Declaration
onServer(listener: (eventName: string, ...args: any[]) => void): void
Parameters
Type |
Name |
Description |
(eventName: string, ...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
onceServer<K extends never>(K, (...args: Parameters<ICustomServerClientEvent[K]>) => void)
Declaration
onceServer<K extends never>(eventName: K, listener: (...args: Parameters<ICustomServerClientEvent[K]>) => void): void
Parameters
Type |
Name |
Description |
K |
eventName |
|
(...args: Parameters<ICustomServerClientEvent[K]>) => void |
listener |
|
|
Improve this Doc
View Source
onceServer<K extends string>(Exclude<K, never>, (...args: any[]) => void)
Declaration
onceServer<K extends string>(eventName: Exclude<K, never>, listener: (...args: any[]) => void): void
Parameters
Type |
Name |
Description |
Exclude<K, never> |
eventName |
|
(...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
onceServer((eventName: string, ...args: any[]) => void)
Declaration
onceServer(listener: (eventName: string, ...args: any[]) => void): void
Parameters
Type |
Name |
Description |
(eventName: string, ...args: any[]) => void |
listener |
|
|
Improve this Doc
View Source
removeGxtText(string)
Declaration
removeGxtText(key: string): void
Parameters
Type |
Name |
Description |
string |
key |
|
|
Improve this Doc
View Source
removeIpl(string)
Declaration
removeIpl(iplName: string): void
Parameters
Type |
Name |
Description |
string |
iplName |
|
|
Improve this Doc
View Source
requestIpl(string)
Declaration
requestIpl(iplName: string): void
Parameters
Type |
Name |
Description |
string |
iplName |
|
|
Improve this Doc
View Source
takeScreenshot()
Declaration
takeScreenshot(): Promise<string>
Returns
Type |
Description |
Promise<string> |
|
|
Improve this Doc
View Source
takeScreenshotGameOnly()
Declaration
takeScreenshotGameOnly(): Promise<string>
Returns
Type |
Description |
Promise<string> |
|
|
Improve this Doc
View Source
resetStat(StatName)
Declaration
resetStat(statName: StatName): void
Parameters
|
Improve this Doc
View Source
resetStat("stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability")
Declaration
resetStat(statName: "stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability"): void
Parameters
Type |
Name |
Description |
"stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability" |
statName |
|
|
Improve this Doc
View Source
setCamFrozen(boolean)
Declaration
setCamFrozen(state: boolean): void
Parameters
Type |
Name |
Description |
boolean |
state |
|
|
Improve this Doc
View Source
isCamFrozen()
Declaration
Returns
|
Improve this Doc
View Source
setConfigFlag(ConfigFlag, boolean)
Declaration
setConfigFlag(flag: ConfigFlag, state: boolean): void
Parameters
Type |
Name |
Description |
ConfigFlag |
flag |
|
boolean |
state |
|
|
Improve this Doc
View Source
setConfigFlag("DISABLE_AUTO_WEAPON_SWAP" | "DISABLE_PED_PROP_KNOCK_OFF" | "DISABLE_IDLE_CAMERA" | "DISABLE_VEHICLE_ENGINE_SHUTDOWN_ON_LEAVE" | "DISABLE_SP_ENTER_VEHICLE_CLIPSET" | "FORCE_RENDER_SNOW" | "FORCE_HIDE_NIGHT_PROPS" | "FORCE_SHOW_NIGHT_PROPS" | "DISABLE_EMISSIVE_LIGHTS_RENDERING" | "FORCE_VEHICLE_TYRE_BURST", boolean)
Declaration
setConfigFlag(flag: "DISABLE_AUTO_WEAPON_SWAP" | "DISABLE_PED_PROP_KNOCK_OFF" | "DISABLE_IDLE_CAMERA" | "DISABLE_VEHICLE_ENGINE_SHUTDOWN_ON_LEAVE" | "DISABLE_SP_ENTER_VEHICLE_CLIPSET" | "FORCE_RENDER_SNOW" | "FORCE_HIDE_NIGHT_PROPS" | "FORCE_SHOW_NIGHT_PROPS" | "DISABLE_EMISSIVE_LIGHTS_RENDERING" | "FORCE_VEHICLE_TYRE_BURST", state: boolean): void
Parameters
Type |
Name |
Description |
"DISABLE_AUTO_WEAPON_SWAP" | "DISABLE_PED_PROP_KNOCK_OFF" | "DISABLE_IDLE_CAMERA" | "DISABLE_VEHICLE_ENGINE_SHUTDOWN_ON_LEAVE" | "DISABLE_SP_ENTER_VEHICLE_CLIPSET" | "FORCE_RENDER_SNOW" | "FORCE_HIDE_NIGHT_PROPS" | "FORCE_SHOW_NIGHT_PROPS" | "DISABLE_EMISSIVE_LIGHTS_RENDERING" | "FORCE_VEHICLE_TYRE_BURST" |
flag |
|
boolean |
state |
|
|
Improve this Doc
View Source
getConfigFlag(ConfigFlag)
Declaration
getConfigFlag(flag: ConfigFlag): boolean
Parameters
Returns
|
Improve this Doc
View Source
getConfigFlag("DISABLE_AUTO_WEAPON_SWAP" | "DISABLE_PED_PROP_KNOCK_OFF" | "DISABLE_IDLE_CAMERA" | "DISABLE_VEHICLE_ENGINE_SHUTDOWN_ON_LEAVE" | "DISABLE_SP_ENTER_VEHICLE_CLIPSET" | "FORCE_RENDER_SNOW" | "FORCE_HIDE_NIGHT_PROPS" | "FORCE_SHOW_NIGHT_PROPS" | "DISABLE_EMISSIVE_LIGHTS_RENDERING" | "FORCE_VEHICLE_TYRE_BURST")
Declaration
getConfigFlag(flag: "DISABLE_AUTO_WEAPON_SWAP" | "DISABLE_PED_PROP_KNOCK_OFF" | "DISABLE_IDLE_CAMERA" | "DISABLE_VEHICLE_ENGINE_SHUTDOWN_ON_LEAVE" | "DISABLE_SP_ENTER_VEHICLE_CLIPSET" | "FORCE_RENDER_SNOW" | "FORCE_HIDE_NIGHT_PROPS" | "FORCE_SHOW_NIGHT_PROPS" | "DISABLE_EMISSIVE_LIGHTS_RENDERING" | "FORCE_VEHICLE_TYRE_BURST"): boolean
Parameters
Type |
Name |
Description |
"DISABLE_AUTO_WEAPON_SWAP" | "DISABLE_PED_PROP_KNOCK_OFF" | "DISABLE_IDLE_CAMERA" | "DISABLE_VEHICLE_ENGINE_SHUTDOWN_ON_LEAVE" | "DISABLE_SP_ENTER_VEHICLE_CLIPSET" | "FORCE_RENDER_SNOW" | "FORCE_HIDE_NIGHT_PROPS" | "FORCE_SHOW_NIGHT_PROPS" | "DISABLE_EMISSIVE_LIGHTS_RENDERING" | "FORCE_VEHICLE_TYRE_BURST" |
flag |
|
Returns
|
Improve this Doc
View Source
doesConfigFlagExist(string)
Declaration
doesConfigFlagExist(flag: string): boolean
Parameters
Type |
Name |
Description |
string |
flag |
|
Returns
|
Improve this Doc
View Source
setCursorPos(IVector2, boolean)
Declaration
setCursorPos(pos: IVector2, normalized?: boolean): void
Parameters
Type |
Name |
Description |
IVector2 |
pos |
|
boolean |
normalized |
|
|
Improve this Doc
View Source
setMsPerGameMinute(number)
Declaration
setMsPerGameMinute(milliseconds: number): void
Parameters
Type |
Name |
Description |
number |
milliseconds |
|
|
Improve this Doc
View Source
setRotationVelocity(number, number, number, number)
Declaration
setRotationVelocity(scriptID: number, x: number, y: number, z: number): void
Parameters
Type |
Name |
Description |
number |
scriptID |
|
number |
x |
|
number |
y |
|
number |
z |
|
|
Improve this Doc
View Source
setStat(StatName, number)
Declaration
setStat(statName: StatName, value: number): void
Parameters
Type |
Name |
Description |
StatName |
statName |
|
number |
value |
|
|
Improve this Doc
View Source
setStat("stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability", number)
Declaration
setStat(statName: "stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability", value: number): void
Parameters
Type |
Name |
Description |
"stamina" | "strength" | "lung_capacity" | "wheelie_ability" | "flying_ability" | "shooting_ability" | "stealth_ability" |
statName |
|
number |
value |
|
|
Improve this Doc
View Source
setWeatherCycle(number[], number[])
Declaration
setWeatherCycle(weathers: number[], multipliers: number[]): void
Parameters
Type |
Name |
Description |
number[] |
weathers |
|
number[] |
multipliers |
|
|
Improve this Doc
View Source
setWeatherSyncActive(boolean)
Declaration
setWeatherSyncActive(isActive: boolean): void
Parameters
Type |
Name |
Description |
boolean |
isActive |
|
|
Improve this Doc
View Source
showCursor(boolean)
Declaration
showCursor(state: boolean): void
Parameters
Type |
Name |
Description |
boolean |
state |
|
|
Improve this Doc
View Source
isCursorVisible()
Declaration
isCursorVisible(): boolean
Returns
|
Improve this Doc
View Source
toggleGameControls(boolean)
Declaration
toggleGameControls(state: boolean): void
Parameters
Type |
Name |
Description |
boolean |
state |
|
|
Improve this Doc
View Source
toggleVoiceControls(boolean)
Declaration
toggleVoiceControls(state: boolean): void
Parameters
Type |
Name |
Description |
boolean |
state |
|
|
Improve this Doc
View Source
isFullScreen()
Declaration
Returns
|
Improve this Doc
View Source
getPoolSize(string)
Declaration
getPoolSize(poolName: string): number
Parameters
Type |
Name |
Description |
string |
poolName |
|
Returns
|
Improve this Doc
View Source
getPoolCount(string)
Declaration
getPoolCount(poolName: string): number
Parameters
Type |
Name |
Description |
string |
poolName |
|
Returns
|
Improve this Doc
View Source
getPoolEntities(string)
Declaration
getPoolEntities(poolName: string): number[]
Parameters
Type |
Name |
Description |
string |
poolName |
|
Returns
Type |
Description |
number[] |
|
|
Improve this Doc
View Source
getVoicePlayers()
Declaration
getVoicePlayers(): number[]
Returns
Type |
Description |
number[] |
|
|
Improve this Doc
View Source
removeVoicePlayer(number)
Declaration
removeVoicePlayer(player: number): void
Parameters
Type |
Name |
Description |
number |
player |
|
|
Improve this Doc
View Source
getVoiceSpatialVolume(number)
Declaration
getVoiceSpatialVolume(player: number): number
Parameters
Type |
Name |
Description |
number |
player |
|
Returns
|
Improve this Doc
View Source
setVoiceSpatialVolume(number, number)
Declaration
setVoiceSpatialVolume(player: number, volume: number): void
Parameters
Type |
Name |
Description |
number |
player |
|
number |
volume |
|
|
Improve this Doc
View Source
getVoiceNonSpatialVolume(number)
Declaration
getVoiceNonSpatialVolume(player: number): number
Parameters
Type |
Name |
Description |
number |
player |
|
Returns
|
Improve this Doc
View Source
setVoiceNonSpatialVolume(number, number)
Declaration
setVoiceNonSpatialVolume(player: number, volume: number): void
Parameters
Type |
Name |
Description |
number |
player |
|
number |
volume |
|
|
Improve this Doc
View Source
addVoiceFilter(number, AudioFilter)
Declaration
addVoiceFilter(player: number, filter: AudioFilter): void
Parameters
|
Improve this Doc
View Source
removeVoiceFilter(number)
Declaration
removeVoiceFilter(player: number): void
Parameters
Type |
Name |
Description |
number |
player |
|
|
Improve this Doc
View Source
getVoiceFilter(number)
Declaration
getVoiceFilter(player: number): AudioFilter
Parameters
Type |
Name |
Description |
number |
player |
|
Returns
|
Improve this Doc
View Source
updateClipContext(Record<string, string>)
Declaration
updateClipContext(context: Record<string, string>): void
Parameters
Type |
Name |
Description |
Record<string, string> |
context |
|
|
Improve this Doc
View Source
loadYtyp(string)
Declaration
loadYtyp(path: string): boolean
Parameters
Type |
Name |
Description |
string |
path |
|
Returns
|
Improve this Doc
View Source
unloadYtyp(string)
Declaration
unloadYtyp(path: string): boolean
Parameters
Type |
Name |
Description |
string |
path |
|
Returns
|
Improve this Doc
View Source
evalModule(string)
Declaration
evalModule(code: string): Record<string, any>
Parameters
Type |
Name |
Description |
string |
code |
|
Returns
Type |
Description |
Record<string, any> |
|
|
Improve this Doc
View Source
getRemoteEventListeners(null | string)
Declaration
getRemoteEventListeners(eventName: null | string): readonly (...args: any[]) => void[]
Parameters
Type |
Name |
Description |
null | string |
eventName |
|
Returns
Type |
Description |
readonly (...args: any[]) => void[] |
|
|
Improve this Doc
View Source
getHeadshotBase64(number)
Declaration
getHeadshotBase64(id: number): string
Parameters
Type |
Name |
Description |
number |
id |
|
Returns
|
Improve this Doc
View Source
setPedDlcClothes(number, number, number, number, number, number)
Declaration
setPedDlcClothes(scriptID: number, dlc: number, component: number, drawable: number, texture: number, palette?: number): void
Parameters
Type |
Name |
Description |
number |
scriptID |
|
number |
dlc |
|
number |
component |
|
number |
drawable |
|
number |
texture |
|
number |
palette |
|
|
Improve this Doc
View Source
setPedDlcProp(number, number, number, number, number)
Declaration
setPedDlcProp(scriptID: number, dlc: number, component: number, drawable: number, texture: number): void
Parameters
Type |
Name |
Description |
number |
scriptID |
|
number |
dlc |
|
number |
component |
|
number |
drawable |
|
number |
texture |
|
|
Improve this Doc
View Source
clearPedProp(number, number)
Declaration
clearPedProp(scriptID: number, component: number): void
Parameters
Type |
Name |
Description |
number |
scriptID |
|
number |
component |
|
|
Improve this Doc
View Source
setWatermarkPosition(WatermarkPosition)
Declaration
setWatermarkPosition(position: WatermarkPosition): void
Parameters
|
Improve this Doc
View Source
setWatermarkPosition<T extends number>(T)
Declaration
setWatermarkPosition<T extends number>(position: T): void
Parameters
Type |
Name |
Description |
T |
position |
|
|
Improve this Doc
View Source
getPing()
Declaration
Returns
|
Improve this Doc
View Source
getFps()
Declaration
Returns
|
Improve this Doc
View Source
getTotalPacketsSent()
Declaration
getTotalPacketsSent(): bigint
Returns
|
Improve this Doc
View Source
getTotalPacketsLost()
Declaration
getTotalPacketsLost(): bigint
Returns
|
Improve this Doc
View Source
getServerIp()
Declaration
Returns
|
Improve this Doc
View Source
getServerPort()
Declaration
Returns
|
Improve this Doc
View Source
copyToClipboard(string)
Declaration
copyToClipboard(val: string): void
Parameters
Type |
Name |
Description |
string |
val |
|
|
Improve this Doc
View Source
toggleRmlControls(boolean)
Declaration
toggleRmlControls(state: boolean): void
Parameters
Type |
Name |
Description |
boolean |
state |
|
|
Improve this Doc
View Source
rmlControlsEnabled()
Declaration
rmlControlsEnabled(): boolean
Returns
|
Improve this Doc
View Source
loadRmlFont(string, string, boolean, boolean)
Declaration
loadRmlFont(path: string, name: string, italic?: boolean, bold?: boolean): void
Parameters
Type |
Name |
Description |
string |
path |
|
string |
name |
|
boolean |
italic |
|
boolean |
bold |
|
|
Improve this Doc
View Source
worldToScreen(number, number, number)
Declaration
worldToScreen(x: number, y: number, z: number): shared.Vector3
Parameters
Type |
Name |
Description |
number |
x |
|
number |
y |
|
number |
z |
|
Returns
|
Improve this Doc
View Source
worldToScreen(IVector3)
Declaration
worldToScreen(value: IVector3): shared.Vector3
Parameters
Returns
|
Improve this Doc
View Source
screenToWorld(number, number)
Declaration
screenToWorld(x: number, y: number): shared.Vector3
Parameters
Type |
Name |
Description |
number |
x |
|
number |
y |
|
Returns
|
Improve this Doc
View Source
screenToWorld(IVector2)
Declaration
screenToWorld(value: IVector2): shared.Vector3
Parameters
Returns
|
Improve this Doc
View Source
getCamPos()
Declaration
getCamPos(): shared.Vector3
Returns
|
Improve this Doc
View Source
getScreenResolution()
Declaration
getScreenResolution(): shared.Vector2
Returns
|
Improve this Doc
View Source
Declaration
getLocalMeta<K extends string>(key: Exclude<K, never>): unknown
Parameters
Type |
Name |
Description |
Exclude<K, never> |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
getLocalMeta<K extends never>(key: K): shared.ICustomPlayerLocalMeta[K] | undefined
Parameters
Type |
Name |
Description |
K |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
getLocalMeta<V extends unknown>(key: string): V | undefined
Parameters
Type |
Name |
Description |
string |
key |
|
Returns
Type |
Description |
V | undefined |
|
|
Improve this Doc
View Source
Declaration
hasLocalMeta(key: string): boolean
Parameters
Type |
Name |
Description |
string |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
hasLocalMeta<K extends never>(key: K): boolean
Parameters
Type |
Name |
Description |
K |
key |
|
Returns
|
Improve this Doc
View Source
setMinimapComponentPosition(string, string, string, IVector2, IVector2)
Declaration
setMinimapComponentPosition(name: string, alignX: string, alignY: string, pos: IVector2, size: IVector2): void
Parameters
Type |
Name |
Description |
string |
name |
|
string |
alignX |
|
string |
alignY |
|
IVector2 |
pos |
|
IVector2 |
size |
|
|
Improve this Doc
View Source
setMinimapComponentPosition(string, string, string, number, number, number, number)
Declaration
setMinimapComponentPosition(name: string, alignX: string, alignY: string, posX: number, posY: number, sizeX: number, sizeY: number): void
Parameters
Type |
Name |
Description |
string |
name |
|
string |
alignX |
|
string |
alignY |
|
number |
posX |
|
number |
posY |
|
number |
sizeX |
|
number |
sizeY |
|
|
Improve this Doc
View Source
resetMinimapComponentPosition(string)
Declaration
resetMinimapComponentPosition(name: string): void
Parameters
Type |
Name |
Description |
string |
name |
|
|
Improve this Doc
View Source
setMinimapIsRectangle(boolean)
Declaration
setMinimapIsRectangle(state: boolean): void
Parameters
Type |
Name |
Description |
boolean |
state |
|
|
Improve this Doc
View Source
loadDefaultIpls()
Declaration
|
Improve this Doc
View Source
isPointOnScreen(number, number, number)
Declaration
isPointOnScreen(x: number, y: number, z: number): boolean
Parameters
Type |
Name |
Description |
number |
x |
|
number |
y |
|
number |
z |
|
Returns
|
Improve this Doc
View Source
isPointOnScreen(IVector3)
Declaration
isPointOnScreen(value: IVector3): boolean
Parameters
Returns
|
Improve this Doc
View Source
getPedBonePos(number, number)
Declaration
getPedBonePos(ped: number, boneId: number): shared.Vector3
Parameters
Type |
Name |
Description |
number |
ped |
|
number |
boneId |
|
Returns
|
Improve this Doc
View Source
Declaration
deleteMeta(key: string): void
Parameters
Type |
Name |
Description |
string |
key |
|
|
Improve this Doc
View Source
Declaration
deleteMeta<K extends never>(key: K): void
Parameters
Type |
Name |
Description |
K |
key |
|
|
Improve this Doc
View Source
Declaration
getMeta<K extends string>(key: Exclude<K, never>): unknown
Parameters
Type |
Name |
Description |
Exclude<K, never> |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
getMeta<K extends never>(key: K): ICustomGlobalMeta[K] | undefined
Parameters
Type |
Name |
Description |
K |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
getMeta<V extends unknown>(key: string): V | undefined
Parameters
Type |
Name |
Description |
string |
key |
|
Returns
Type |
Description |
V | undefined |
|
|
Improve this Doc
View Source
Declaration
getMetaKeys(): readonly string[]
Returns
Type |
Description |
readonly string[] |
|
|
Improve this Doc
View Source
Declaration
hasMeta(key: string): boolean
Parameters
Type |
Name |
Description |
string |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
hasMeta<K extends never>(key: K): boolean
Parameters
Type |
Name |
Description |
K |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
setMeta<K extends string>(key: K, value: InterfaceValueByKey<ICustomGlobalMeta, K, unknown, void>): void
Parameters
Type |
Name |
Description |
K |
key |
|
InterfaceValueByKey<ICustomGlobalMeta, K, unknown, void> |
value |
|
|
Improve this Doc
View Source
Declaration
setMeta<K extends never>(key: K, value: ICustomGlobalMeta[K]): void
Parameters
|
Improve this Doc
View Source
Declaration
setMeta<V extends unknown, K extends string>(key: K, value: InterfaceValueByKey<ICustomGlobalMeta, K, V, void>): void
Parameters
|
Improve this Doc
View Source
Declaration
getSyncedMeta<K extends string>(key: Exclude<K, never>): unknown
Parameters
Type |
Name |
Description |
Exclude<K, never> |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
getSyncedMeta<K extends never>(key: K): ICustomGlobalSyncedMeta[K] | undefined
Parameters
Type |
Name |
Description |
K |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
getSyncedMeta<V extends unknown>(key: string): V | undefined
Parameters
Type |
Name |
Description |
string |
key |
|
Returns
Type |
Description |
V | undefined |
|
|
Improve this Doc
View Source
Declaration
getSyncedMetaKeys(): readonly string[]
Returns
Type |
Description |
readonly string[] |
|
|
Improve this Doc
View Source
Declaration
hasSyncedMeta(key: string): boolean
Parameters
Type |
Name |
Description |
string |
key |
|
Returns
|
Improve this Doc
View Source
Declaration
hasSyncedMeta<K extends never>(key: K): boolean
Parameters
Type |
Name |
Description |
K |
key |
|
Returns
|
Improve this Doc
View Source
clearEveryTick(number)
Declaration
clearEveryTick(id: number): void
Parameters
Type |
Name |
Description |
number |
id |
|
|
Improve this Doc
View Source
clearInterval(number)
Declaration
clearInterval(id: number): void
Parameters
Type |
Name |
Description |
number |
id |
|
|
Improve this Doc
View Source
clearNextTick(number)
Declaration
clearNextTick(id: number): void
Parameters
Type |
Name |
Description |
number |
id |
|
|
Improve this Doc
View Source
clearTimeout(number)
Declaration
clearTimeout(id: number): void
Parameters
Type |
Name |
Description |
number |
id |
|
|
Improve this Doc
View Source
everyTick((...args: any[]) => void)
Declaration
everyTick(handler: (...args: any[]) => void): number
Parameters
Type |
Name |
Description |
(...args: any[]) => void |
handler |
|
Returns
|
Improve this Doc
View Source
hash(string)
Declaration
hash(str: string): number
Parameters
Type |
Name |
Description |
string |
str |
|
Returns
|
Improve this Doc
View Source
hasResource(string)
Declaration
hasResource(name: string): boolean
Parameters
Type |
Name |
Description |
string |
name |
|
Returns
|
Improve this Doc
View Source
log(any, any[])
Declaration
log(arg: any, ...args: any[]): void
Parameters
Type |
Name |
Description |
any |
arg |
|
any[] |
args |
|
|
Improve this Doc
View Source
logError(any, any[])
Declaration
logError(arg: any, ...args: any[]): void
Parameters
Type |
Name |
Description |
any |
arg |
|
any[] |
args |
|
|
Improve this Doc
View Source
logWarning(any, any[])
Declaration
logWarning(arg: any, ...args: any[]): void
Parameters
Type |
Name |
Description |
any |
arg |
|
any[] |
args |
|
|
Improve this Doc
View Source
logDebug(any, any[])
Declaration
logDebug(arg: any, ...args: any[]): void
Parameters
Type |
Name |
Description |
any |
arg |
|
any[] |
args |
|
|
Improve this Doc
View Source
nextTick((...args: any[]) => void)
Declaration
nextTick(handler: (...args: any[]) => void): number
Parameters
Type |
Name |
Description |
(...args: any[]) => void |
handler |
|
Returns
|
Improve this Doc
View Source
setInterval((...args: any[]) => void, number)
Declaration
setInterval(handler: (...args: any[]) => void, miliseconds: number): number
Parameters
Type |
Name |
Description |
(...args: any[]) => void |
handler |
|
number |
miliseconds |
|
Returns
|
Improve this Doc
View Source
setTimeout((...args: any[]) => void, number)
Declaration
setTimeout(handler: (...args: any[]) => void, miliseconds: number): number
Parameters
Type |
Name |
Description |
(...args: any[]) => void |
handler |
|
number |
miliseconds |
|
Returns
|
Improve this Doc
View Source
getAllResources()
Declaration
getAllResources(): readonly IResource[]
Returns
|
Improve this Doc
View Source
time(string)
Declaration
time(timerName: string): void
Parameters
Type |
Name |
Description |
string |
timerName |
|
|
Improve this Doc
View Source
time()
Declaration
|
Improve this Doc
View Source
timeEnd(string)
Declaration
timeEnd(timerName: string): void
Parameters
Type |
Name |
Description |
string |
timerName |
|
|
Improve this Doc
View Source
timeEnd()
Declaration
|
Improve this Doc
View Source
getEventListeners(null | string)
Declaration
getEventListeners(eventName: null | string): readonly (...args: any[]) => void[]
Parameters
Type |
Name |
Description |
null | string |
eventName |
|
Returns
Type |
Description |
readonly (...args: any[]) => void[] |
|
|
Improve this Doc
View Source
stringToSHA256(string)
Declaration
stringToSHA256(string: string): string
Parameters
Type |
Name |
Description |
string |
string |
|
Returns
|
Improve this Doc
View Source
getVoiceConnectionState()
Declaration
getVoiceConnectionState(): VoiceConnectionState
Returns
|
Improve this Doc
View Source
getNetTime()
Declaration
Returns
Variables
|
Improve this Doc
View Source
resourceName
Declaration
const resourceName: string
|
Improve this Doc
View Source
version
Declaration
|
Improve this Doc
View Source
sdkVersion
Declaration
|
Improve this Doc
View Source
branch
Declaration
|
Improve this Doc
View Source
debug
Declaration
|
Improve this Doc
View Source
defaultDimension
Declaration
const defaultDimension: number
|
Improve this Doc
View Source
globalDimension
Declaration
const globalDimension: number
|
Improve this Doc
View Source
isClient
Declaration
|
Improve this Doc
View Source
isServer
Declaration