a library to speed up the development of Fivem scripts and frameworks
fivem-ts - Documentation v0.7.5 • Docs
fivem-ts - Documentation v0.7.5 / Client / Model
Class to create and manage entity models.
new Model(
hash
):Model
• hash: string
| number
get
Dimensions():Vector3
Gets the model dimensions.
This model dimensions.
get
Hash():number
Gets hash of the model
number
The hash key
get
IsBicycle():boolean
Gets if the model is a bicycle or not.
boolean
Whether this model is a bicycle.
get
IsBike():boolean
Gets if the model is a motorbike or not.
boolean
Whether this model is a motorbike.
get
IsBoat():boolean
Gets if the model is a boat or not.
boolean
Whether this model is a boat.
get
IsCar():boolean
Gets if the model is a car or not.
boolean
Whether this model is a car.
get
IsCargobob():boolean
boolean
get
IsCollisionLoaded():boolean
Gets if the model collision is loaded or not.
boolean
Whether this model collision is loaded.
get
IsHelicopter():boolean
Gets if the model is a helicopter or not.
boolean
Whether this model is a helicopter.
get
IsInCdImage():boolean
Gets if the model is in cd image or not.
boolean
Whether this model is in cd image.
get
IsLoaded():boolean
Gets if the model is loaded or not.
boolean
Whether this model is loaded.
get
IsPed():boolean
Gets if the model is a Ped or not.
boolean
Whether this model is a Ped.
get
IsPlane():boolean
Gets if the model is a plane or not.
boolean
Whether this model is a plane.
get
IsProp():boolean
Gets if the model is a prop or not.
boolean
Whether this model is a prop.
get
IsQuadbike():boolean
Gets if the model is a quadbike or not.
boolean
Whether this model is a quadbike.
get
IsTrain():boolean
Gets if the model is a train or not.
boolean
Whether this model is a train.
get
IsValid():boolean
Gets if the model is valid or not.
boolean
Whether this model is valid.
get
IsVehicle():boolean
Gets if the model is a Cargobob or not.
boolean
Whether this model is a Cargobob.
markAsNoLongerNeeded():
void
Sets the model as no longer needed allowing the game engine to free memory.
void
request(
timeout
):Promise
<boolean
>
Request and load the model with a specified timeout. Advised timeout - 1000.
• timeout: number
{number} Maximum allowed time for model to load.
Promise
<boolean
>