11.03.2014, 23:24
Hello, this is my first tutorial on how to make a model viewer for sa-mp i really wanted to release this when i learn't it! please do rep if it helped in any way shape or form.
Requirement's
ZCMD (If not use some other Command program)
Knowledge of basic scripting.
----------------------------------------------
Requirement's
ZCMD (If not use some other Command program)
Knowledge of basic scripting.
----------------------------------------------
Step 1:Add this after you're Defines.
Step 2: Add this to you're Public OnGameModeInit
Step 3:Create This if you dont already have it in you're Script.
Last Step: Add the Command.
Hope this Helped.
P.S I've attached a txt you need to put into you're "Scriptfiles" for the script to know the skin id's
Code:
new skinList = mS_INVALID_LISTID;//This Mean's its ignoring the Invalid Skins
Code:
public OnGameModeInit() { skinList = LoadModelSelectionMenu("skins.txt"); return 1; }
Code:
public OnPlayerModelSelection(playerid, response, listid, modelid) { if(listid == skinList) { if(response) { SendClientMessage(playerid, 0xFF0000FF, "Skin Changed"); SetPlayerSkin(playerid, modelid); } else SendClientMessage(playerid, 0xFF0000FF, "Canceled skin selection"); return 1; } return 1; }
Code:
COMMAND:skin(playerid, params[]) // or CMD:mycommand(playerid, params[]) { ShowModelSelectionMenu(playerid, skinList, "Select Skin"); return 1; }
P.S I've attached a txt you need to put into you're "Scriptfiles" for the script to know the skin id's