SA-MP Forums Archive
Toys - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Toys (/showthread.php?tid=484257)



Toys - FaZeRs - 29.12.2013

Who can help update my toy system to 0.3e?

PHP код:
CMD:toys(playeridparams[])
{
    
ShowPlayerDialogplayeridTOYSDIALOG_STYLE_LIST"Toy Menu""Attach/Dettach a Toy\nEdit a Toy\nDelete a Toy","Select""Cancel" );
    return 
1;

PHP код:
stock ShowEditMenu(playerid)
{
    if(
IsPlayerAttachedObjectSlotUsed(playeridslotselection[playerid]))
    {
         
RemovePlayerAttachedObject(playeridslotselection[playerid]);
    }
    
SetPlayerAttachedObject(playeridslotselection[playerid], PlayerToyInfo[playerid][slotselection[playerid]][ptModelID],
    
PlayerToyInfo[playerid][slotselection[playerid]][ptBone], PlayerToyInfo[playerid][slotselection[playerid]][ptPosX],
    
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY], PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ],
    
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX], PlayerToyInfo[playerid][slotselection[playerid]][ptRotY],
    
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ], PlayerToyInfo[playerid][slotselection[playerid]][ptScaleX],
     
PlayerToyInfo[playerid][slotselection[playerid]][ptScaleY], PlayerToyInfo[playerid][slotselection[playerid]][ptScaleZ]);
    new 
stringg[512];
    
format(stringgsizeof(stringg), "%sBone (%s)\n"stringgHoldingBones[PlayerToyInfo[playerid][slotselection[playerid]][ptBone]]);
    
format(stringgsizeof(stringg), "%sOffset X (%f)\n"stringg,(PlayerToyInfo[playerid][slotselection[playerid]][ptPosX]*100));
    
format(stringgsizeof(stringg), "%sOffset Y (%f)\n"stringg,(PlayerToyInfo[playerid][slotselection[playerid]][ptPosY]*100));
    
format(stringgsizeof(stringg), "%sOffset Z (%f)\n"stringg,(PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ]*100));
    
format(stringgsizeof(stringg), "%sRotation X (%f)\n"stringgPlayerToyInfo[playerid][slotselection[playerid]][ptRotX]);
    
format(stringgsizeof(stringg), "%sRotation Y (%f)\n"stringgPlayerToyInfo[playerid][slotselection[playerid]][ptRotY]);
    
format(stringgsizeof(stringg), "%sRotation Z (%f)\n",stringgPlayerToyInfo[playerid][slotselection[playerid]][ptRotZ]);
    
format(stringgsizeof(stringg), "%sScale X (%f)\n",stringgPlayerToyInfo[playerid][slotselection[playerid]][ptScaleX]);
    
format(stringgsizeof(stringg), "%sScale Y (%f)\n",stringgPlayerToyInfo[playerid][slotselection[playerid]][ptScaleY]);
    
format(stringgsizeof(stringg), "%sScale Z (%f)\n" ,stringgPlayerToyInfo[playerid][slotselection[playerid]][ptScaleZ]);
     
ShowPlayerDialog(playeridEDITTOYS2DIALOG_STYLE_LIST"Toy Menu: Edit"stringg"Select""Cancel");

PHP код:
    if((dialogid == BUYTOYSCOP) && response)
    {
        new 
stringg[512];
        for(new 
x;x<MAX_PLAYERTOYS;x++)
        {
              new 
name[24] = "None";
            for(new 
i;i<sizeof(HoldingObjectsAll);i++)
               {
                if(
HoldingObjectsAll[i][holdingmodelid] == PlayerToyInfo[playerid][x][ptModelID])
                {
                       
format(namesizeof(name), "%s"HoldingObjectsAll[i][holdingmodelname]);
                }
            }
            
format(stringgsizeof(stringg), "%s(%d) %s (Bone: %s)\n"stringgxnameHoldingBones[PlayerToyInfo[playerid][x][ptBone]]);
        }
        
ShowPlayerDialog(playeridBUYTOYSCOP2DIALOG_STYLE_LIST"Select a Slot"stringg"Select""Cancel");
    }
    if((
dialogid == BUYTOYSCOP2) && response)
    {
        if(
listitem >= && PlayerInfo[playerid][pDonateRank] < || listitem >= && PlayerInfo[playerid][pBuddyInvited] == 1) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Bronze VIP + to use that slot!");
        if(
listitem >= && PlayerInfo[playerid][pDonateRank] < 2) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Silver VIP + to use that slot!");
        if(
listitem >= && PlayerInfo[playerid][pDonateRank] < 3) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Gold VIP + to use that slot!");
        if(
PlayerToyInfo[playerid][listitem][ptModelID] != 0) return SendClientMessageEx(playeridCOLOR_YELLOW"* You already have something in that slot. Delete it with /toys");
        
slotselection[playerid] = listitem;
        new 
stringg[1024];
        for(new 
x;x<sizeof(HoldingObjectsCop);x++)
        {
            
format(stringgsizeof(stringg), "%s%s ($%d)\n"stringgHoldingObjectsCop[x][holdingmodelname], HoldingObjectsCop[x][holdingprice]);
        }
        
ShowPlayerDialog(playeridBUYTOYSCOP3DIALOG_STYLE_LIST"Select an Item"stringg"Buy""Cancel");
    }
    if((
dialogid == BUYTOYSCOP3) && response)
    {
        if(
GetPlayerCash(playerid) < HoldingObjectsCop[listitem][holdingprice])
        {
            
SendClientMessageEx(playeridCOLOR_WHITE"* You can't afford that!");
        }
        else
        {
            
GivePlayerCash(playerid, -HoldingObjectsCop[listitem][holdingprice]);
            
PlayerToyInfo[playerid][slotselection[playerid]][ptModelID] = HoldingObjectsCop[listitem][holdingmodelid];
               new 
modelid PlayerToyInfo[playerid][slotselection[playerid]][ptModelID];
            if((
modelid >= 19006 && modelid <= 19035) || (modelid >= 19138 && modelid <= 19140))
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.9;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.35;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if(
modelid >= 18891 && modelid <= 18910)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.15;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 90.0;
            }
            else if(
modelid >= 18926 && modelid <= 18935)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.1;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if(
modelid >= 18911 && modelid <= 18920)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.1;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.035;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 90.0;
            }
            else if(
modelid == 19078 || modelid == 19078)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 16;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if((
modelid >= 18641 && modelid <= 18644) || (modelid >= 19080 && modelid <= 19084) || modelid == 18890)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 6;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            
format(stringsizeof(string), "* You have purchased %s for $%d (Slot: %d)"HoldingObjectsCop[listitem][holdingmodelname], HoldingObjectsCop[listitem][holdingprice], slotselection[playerid]);
            
SendClientMessageEx(playeridCOLOR_REDstring);
            
SendClientMessageEx(playeridCOLOR_WHITE"HINT: Use /toys to wear/edit this");
        }
    }
    if((
dialogid == BUYTOYSGOLD) && response)
    {
         if(
PlayerInfo[playerid][pDonateRank] < 3) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Gold VIP +");
        new 
stringg[512];
        for(new 
x;x<MAX_PLAYERTOYS;x++)
        {
              new 
name[24] = "None";
            for(new 
i;i<sizeof(HoldingObjectsAll);i++)
               {
                if(
HoldingObjectsAll[i][holdingmodelid] == PlayerToyInfo[playerid][x][ptModelID])
                {
                       
format(namesizeof(name), "%s"HoldingObjectsAll[i][holdingmodelname]);
                }
            }
            
format(stringgsizeof(stringg), "%s(%d) %s (Bone: %s)\n"stringgxnameHoldingBones[PlayerToyInfo[playerid][x][ptBone]]);
        }
        
ShowPlayerDialog(playeridBUYTOYSGOLD2DIALOG_STYLE_LIST"Select a Slot"stringg"Select""Cancel");
    }
    if((
dialogid == BUYTOYSGOLD2) && response)
    {
        if(
PlayerInfo[playerid][pDonateRank] < 3) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Gold VIP +");
        if(
PlayerToyInfo[playerid][listitem][ptModelID] != 0) return SendClientMessageEx(playeridCOLOR_YELLOW"* You already have something in that slot. Delete it with /toys");
        
slotselection[playerid] = listitem;
        new 
stringg[5256];
        for(new 
x;x<sizeof(HoldingObjectsAll);x++)
        {
            
format(stringgsizeof(stringg), "%s%s ($%d)\n"stringgHoldingObjectsAll[x][holdingmodelname], HoldingObjectsAll[x][holdingprice]);
        }
        
ShowPlayerDialog(playeridBUYTOYSGOLD3DIALOG_STYLE_LIST"Select an Item"stringg"Buy""Cancel");
    }
    if((
dialogid == BUYTOYSGOLD3) && response)
    {
        if(
PlayerInfo[playerid][pDonateRank] < 3) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Gold VIP +");
        if(
GetPlayerCash(playerid) < HoldingObjects[listitem][holdingprice])
        {
            
SendClientMessageEx(playeridCOLOR_WHITE"* You can't afford that!");
        }
        else
        {
            
GivePlayerCash(playerid, -HoldingObjectsAll[listitem][holdingprice]);
            
PlayerToyInfo[playerid][slotselection[playerid]][ptModelID] = HoldingObjectsAll[listitem][holdingmodelid];
               new 
modelid PlayerToyInfo[playerid][slotselection[playerid]][ptModelID];
            if((
modelid >= 19006 && modelid <= 19035) || (modelid >= 19138 && modelid <= 19140))
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.9;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.35;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if(
modelid >= 18891 && modelid <= 18910)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.15;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 90.0;
            }
            else if(
modelid >= 18926 && modelid <= 18935)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.1;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if(
modelid >= 18911 && modelid <= 18920)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.1;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.035;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 90.0;
            }
            else if(
modelid == 19078 || modelid == 19078)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 16;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if((
modelid >= 18641 && modelid <= 18644) || (modelid >= 19080 && modelid <= 19084) || modelid == 18890)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 6;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            
format(stringsizeof(string), "* You have purchased %s for $%d (Slot: %d)"HoldingObjectsAll[listitem][holdingmodelname], HoldingObjectsAll[listitem][holdingprice], slotselection[playerid]);
            
SendClientMessageEx(playeridCOLOR_REDstring);
            
SendClientMessageEx(playeridCOLOR_WHITE"HINT: Use /toys to wear/edit this");
        }
    }
    if((
dialogid == BUYTOYS) && response)
    {
        new 
stringg[512];
        for(new 
x;x<MAX_PLAYERTOYS;x++)
        {
              new 
name[24];
            
format(namesizeof(name), "None");
            for(new 
i;i<sizeof(HoldingObjectsAll);i++)
               {
                if(
HoldingObjectsAll[i][holdingmodelid] == PlayerToyInfo[playerid][x][ptModelID])
                {
                       
format(namesizeof(name), "%s"HoldingObjectsAll[i][holdingmodelname]);
                }
            }
            
format(stringgsizeof(stringg), "%s(%d) %s (Bone: %s)\n"stringgxnameHoldingBones[PlayerToyInfo[playerid][x][ptBone]]);
        }
        
ShowPlayerDialog(playeridBUYTOYS2DIALOG_STYLE_LIST"Select a Slot"stringg"Select""Cancel");
    }
    if((
dialogid == BUYTOYS2) && response)
    {
        if(
listitem >= && PlayerInfo[playerid][pDonateRank] < || listitem >= && PlayerInfo[playerid][pBuddyInvited] == 1) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Bronze VIP + to use that slot!");
        if(
listitem >= && PlayerInfo[playerid][pDonateRank] < 2) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Silver VIP + to use that slot!");
        if(
listitem >= && PlayerInfo[playerid][pDonateRank] < 3) return SendClientMessageEx(playeridCOLOR_WHITE"* You must be a Gold VIP + to use that slot!");
        if(
PlayerToyInfo[playerid][listitem][ptModelID] != 0) return SendClientMessageEx(playeridCOLOR_YELLOW"* You already have something in that slot. Delete it with /toys");
        
slotselection[playerid] = listitem;
        new 
stringg[5000];
        for(new 
x;x<sizeof(HoldingObjects);x++)
        {
            
format(stringgsizeof(stringg), "%s%s ($%d)\n"stringgHoldingObjects[x][holdingmodelname], HoldingObjects[x][holdingprice]);
        }
        
ShowPlayerDialog(playeridBUYTOYS3DIALOG_STYLE_LIST"Select an Item"stringg"Buy""Cancel");
    }
    if((
dialogid == BUYTOYS3) && response)
    {
        if(
GetPlayerCash(playerid) < HoldingObjects[listitem][holdingprice])
        {
            
SendClientMessageEx(playeridCOLOR_WHITE"* You can't afford that!");
        }
        else
        {
            
GivePlayerCash(playerid, -HoldingObjects[listitem][holdingprice]);
            
PlayerToyInfo[playerid][slotselection[playerid]][ptModelID] = HoldingObjects[listitem][holdingmodelid];
            new 
modelid PlayerToyInfo[playerid][slotselection[playerid]][ptModelID];
            if((
modelid >= 19006 && modelid <= 19035) || (modelid >= 19138 && modelid <= 19140))
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.9;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.35;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if(
modelid >= 18891 && modelid <= 18910)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.15;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 90.0;
            }
            else if(
modelid >= 18926 && modelid <= 18935)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.1;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if(
modelid >= 18911 && modelid <= 18920)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.1;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.035;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 90.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 90.0;
            }
            else if(
modelid == 19078 || modelid == 19078)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 16;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 180.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else if((
modelid >= 18641 && modelid <= 18644) || (modelid >= 19080 && modelid <= 19084) || modelid == 18890)
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 6;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            else
            {
                
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = 2;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = 0.0;
                
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = 0.0;
            }
            
format(stringsizeof(string), "* You have purchased %s for $%d (Slot: %d)"HoldingObjects[listitem][holdingmodelname], HoldingObjects[listitem][holdingprice], slotselection[playerid]);
            
SendClientMessageEx(playeridCOLOR_REDstring);
            
SendClientMessageEx(playeridCOLOR_WHITE"HINT: Use /toys to wear/edit this");
        }
    }
    if((
dialogid == TOYS) && response)
    {
        if(
listitem == 0)
        {
            new 
stringg[512];
            for(new 
x;x<MAX_PLAYERTOYS;x++)
            {
                new 
name[24];
                
format(namesizeof(name), "None");
                for(new 
i;i<sizeof(HoldingObjectsAll);i++)
                {
                       if(
HoldingObjectsAll[i][holdingmodelid] == PlayerToyInfo[playerid][x][ptModelID])
                    {
                           
format(namesizeof(name), "%s"HoldingObjectsAll[i][holdingmodelname]);
                    }
                }
                
format(stringgsizeof(stringg), "%s(%d) %s (Bone: %s)\n"stringgxnameHoldingBones[PlayerToyInfo[playerid][x][ptBone]]);
            }
               
ShowPlayerDialog(playeridWEARTOYDIALOG_STYLE_LIST"Select a Toy"stringg"Select""Cancel");
        }
        else if(
listitem == 1)
        {
            new 
stringg[512];
            for(new 
x;x<MAX_PLAYERTOYS;x++)
            {
                new 
name[24];
                
format(namesizeof(name), "None");
                for(new 
i;i<sizeof(HoldingObjectsAll);i++)
                {
                       if(
HoldingObjectsAll[i][holdingmodelid] == PlayerToyInfo[playerid][x][ptModelID])
                    {
                           
format(namesizeof(name), "%s"HoldingObjectsAll[i][holdingmodelname]);
                    }
                }
                
format(stringgsizeof(stringg), "%s(%d) %s (Bone: %s)\n"stringgxnameHoldingBones[PlayerToyInfo[playerid][x][ptBone]]);
            }
               
ShowPlayerDialog(playeridEDITTOYSDIALOG_STYLE_LIST"Select a Toy"stringg"Select""Cancel");
           }
        else if(
listitem == 2)
        {
            new 
stringg[512];
            for(new 
x;x<MAX_PLAYERTOYS;x++)
            {
                new 
name[24];
                
format(namesizeof(name), "None");
                for(new 
i;i<sizeof(HoldingObjectsAll);i++)
                {
                       if(
HoldingObjectsAll[i][holdingmodelid] == PlayerToyInfo[playerid][x][ptModelID])
                    {
                           
format(namesizeof(name), "%s"HoldingObjectsAll[i][holdingmodelname]);
                    }
                }
                
format(stringgsizeof(stringg), "%s(%d) %s (Bone: %s)\n"stringgxnameHoldingBones[PlayerToyInfo[playerid][x][ptBone]]);
            }
               
ShowPlayerDialog(playeridDELETETOYDIALOG_STYLE_LIST"Select a Toy"stringg"Delete""Cancel");
        }
    }
    if((
dialogid == EDITTOYS) && response)
    {
        if(
PlayerToyInfo[playerid][listitem][ptModelID] == 0)
        {
            
ShowPlayerDialog(playerid0DIALOG_STYLE_MSGBOX"Toy Menu: Edit""Woops! You don't have anything on that slot""OK""");
        }
        else
        {
            
SendClientMessageEx(playeridCOLOR_WHITE"{AA3333}HINT:{FFFF00} Position your camera differently to better see where your editing.");
            
slotselection[playerid] = listitem;
            
ShowEditMenu(playerid);
        }
    }
    if((
dialogid == EDITTOYS2))
    {
        if(
response)
        {
            if(
listitem == 0)
            {
                
ShowPlayerDialog(playeridEDITTOYSBONEDIALOG_STYLE_LIST"Select a Bone""Spine\nHead\nLeft upper arm\nRight upper arm\nLeft hand\nRight hand\nLeft thigh\nRight thigh\nLeft foot\nRight foot\nRight calf\nLeft calf\nLeft forearm\nRight forearm\nLeft clavicle\nRight clavicle\nNeck\nJaw""Select""Cancel");
            }
            else if(
listitem == 1)
            {
                
ShowPlayerDialog(playeridEDITTOYSPXDIALOG_STYLE_INPUT"Toy Menu: Edit""Input an X Offset from -100 to 100 (Ex: 55, or 33.4)""Enter""Cancel");
            }
            else if(
listitem == 2)
            {
                
ShowPlayerDialog(playeridEDITTOYSPYDIALOG_STYLE_INPUT"Toy Menu: Edit""Input an Y Offset from -100 to 100 (Ex: 55, or 33.4)""Enter""Cancel");
            }
            else if(
listitem == 3)
            {
                
ShowPlayerDialog(playeridEDITTOYSPZDIALOG_STYLE_INPUT"Toy Menu: Edit""Input an Z Offset from -100 to 100 (Ex: 55, or 33.4)""Enter""Cancel");
            }
            else if(
listitem == 4)
            {
                
ShowPlayerDialog(playeridEDITTOYSRXDIALOG_STYLE_INPUT"Toy Menu: Edit""Input an X Rotation from 0 to 360 (Ex: 90, or 270.4)""Enter""Cancel");
            }
            else if(
listitem == 5)
            {
                
ShowPlayerDialog(playeridEDITTOYSRYDIALOG_STYLE_INPUT"Toy Menu: Edit""Input an Y Rotation from 0 to 360 (Ex: 90, or 270.4)""Enter""Cancel");
            }
            else if(
listitem == 6)
            {
                
ShowPlayerDialog(playeridEDITTOYSRZDIALOG_STYLE_INPUT"Toy Menu: Edit""Input an Z Rotation from 0 to 360 (Ex: 90, or 270.4)""Enter""Cancel");
            }
        }
        else
        {
            new 
stringg[512];
            for(new 
x;x<MAX_PLAYERTOYS;x++)
            {
                new 
name[24];
                
format(namesizeof(name), "None");
                for(new 
i;i<sizeof(HoldingObjectsAll);i++)
                {
                       if(
HoldingObjectsAll[i][holdingmodelid] == PlayerToyInfo[playerid][x][ptModelID])
                    {
                           
format(namesizeof(name), "%s"HoldingObjectsAll[i][holdingmodelname]);
                    }
                }
                
format(stringgsizeof(stringg), "%s(%d) %s (Bone: %s)\n"stringgxnameHoldingBones[PlayerToyInfo[playerid][x][ptBone]]);
            }
               
ShowPlayerDialog(playeridEDITTOYSDIALOG_STYLE_LIST"Select a Toy"stringg"Select""Cancel");
        }
    }
    if(
dialogid == EDITTOYSPX)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset < -100offset 0;
            else if(
offset 100offset 100;
            
offset offset/100;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptPosX] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSPY)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset < -100offset 0;
            else if(
offset 100offset 100;
            
offset offset/100;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptPosY] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSPZ)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset < -100offset 0;
            else if(
offset 100offset 100;
            
offset offset/100;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptPosZ] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSRX)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset < -100offset 0;
            else if(
offset 360offset 360;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptRotX] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSRY)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset < -100offset 0;
            else if(
offset 360offset 360;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptRotY] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSRZ)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset < -100offset 0;
            else if(
offset 360offset 360;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptRotZ] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSSX)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset 0.5 && PlayerInfo[playerid][pAdmin] < 1337offset 0.5;
            else if(
offset && PlayerInfo[playerid][pAdmin] < 1337offset 2;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptScaleX] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSSY)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset 0.5 && PlayerInfo[playerid][pAdmin] < 1337offset 0.5;
            else if(
offset && PlayerInfo[playerid][pAdmin] < 1337offset 2;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptScaleY] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSSZ)
    {
        if(
response)
        {
            new 
Float:offset floatstr(inputtext);
            if(
offset 0.5 && PlayerInfo[playerid][pAdmin] < 1337offset 0.5;
            else if(
offset && PlayerInfo[playerid][pAdmin] < 1337offset 2;
            
PlayerToyInfo[playerid][slotselection[playerid]][ptScaleZ] = offset;
        }
        
ShowEditMenu(playerid);
    }
    if(
dialogid == EDITTOYSBONE)
    {
        if(
response)
        {
            
PlayerToyInfo[playerid][slotselection[playerid]][ptBone] = listitem+1;
        }
        
ShowEditMenu(playerid);
    } 
And how can i add in my server 0.3x skin selector?