GetObjectModel help
#9

Quote:
Originally Posted by jlalt
Посмотреть сообщение
PHP код:
AttachAble(objectmodel)
{
    switch(
objectmodel)
    {
        case 
19601,19843,19796: return 1;
    }
    return 
0;
}
CMD:attachobject(playeridparams[])
{
    new 
objectmodelcar;
    if(
sscanf(params"ii"objectmodelcar))
    {
        
SendServerMessage(playerid"Use: /attachobject [object model] [SAMP Car ID]");
        return 
1;
    }
    if(!
AttachAble(objectmodel))
        return 
SendErrorMessage(playerid"Invaild objectid use /attachableids");
     if(
car MAX_VEHICLES)
     {
          new 
Float:pxFloat:pyFloat:pz;
          
GetPlayerPos(playeridpxpypz);
          
AttachingObjects[playerid] = CreateObject(objectmodelpxpypz0.00.00.0);
          
SendClientMessage(playerid0xfce80cFF"Object created. Editing...");
          
EditObject(playeridAttachingObjects[playerid]);
          
SetPVarInt(playerid"AttachingTo"car);
    }
    else
    {
        
SendErrorMessage(playerid"Invalid vehicle");
    }
    return 
1;

You should use object model in every where not getting object model id, cause you're not attaching object on your car, you creating new one, so
Код:
GetObjectModel(objectid)
were unless

about the stock
https://sampforum.blast.hk/showthread.php?tid=570635
Thank you alot, rep
Reply


Messages In This Thread
GetObjectModel help - by N0FeaR - 31.03.2016, 14:01
Re: GetObjectModel help - by N0FeaR - 01.04.2016, 09:18
Re: GetObjectModel help - by Konstantinos - 01.04.2016, 09:37
Re: GetObjectModel help - by Antoniohl - 01.04.2016, 09:38
Re: GetObjectModel help - by N0FeaR - 01.04.2016, 10:08
Re: GetObjectModel help - by BroZeus - 01.04.2016, 10:15
Re: GetObjectModel help - by N0FeaR - 01.04.2016, 11:17
Re: GetObjectModel help - by jlalt - 01.04.2016, 11:26
Re: GetObjectModel help - by N0FeaR - 01.04.2016, 11:48

Forum Jump:


Users browsing this thread: 1 Guest(s)