Skip to content

TracerDS/mta-modelloader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MTA Modelloader

About

This resource has been created to ease the process of creating custom models via engineRequestModel.

API is simple to use and easy to maintain. Enjoy :>

Install

  • Go to the Releases panel
  • Download recent version
  • Put it in your resources folder
  • Enjoy

API

element CreateModel(string modelType, ...)

Type: Shared

Creates model with specified model type (ped, vehicle, object). Returns the created model.


number RequestModel(string modelType, string modelName, table modelData)

Type: Client

Requests a new ID for the model with model data to replace (col, txd, dff, conf). Returns valid id on success.


boolean ReplaceModel(element/table model, number id)

Type: Shared

Replaces model with the requested ID. When model is a table, it is assumed that the table is indexed numerically and thus it will try to replace all elements in the table. Returns true when model has been successfully replaced.


boolean FreeModel(number id)

Type: Client

Frees the requested model ID. Returns true on success.


table GetModels()

Type: Shared

Returns synced and replaced models.


table GetIDs([ player playerToFetch ])

Type: Shared

Returns requested model IDs. When called on the server, it will return requested ids for every player unless specified otherwise via the playerToFetch parameter. This parameter exists only on the server.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages