SA-MP Forums Archive
How do I make a spawn car command? And more. read topic please. - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: How do I make a spawn car command? And more. read topic please. (/showthread.php?tid=160927)



How do I make a spawn car command? And more. read topic please. - markjaysonpinoy - 18.07.2010

How do I make a spawn car command? Like, when they type /vehicle, a dialog box will show up showing the names of cars then they will pick a car they want to spawn?


And, how do I add something to the persons name like, on world 2, roleplay world, I wanna add something like, when they talk, "Carl_Johnson Says: Hello."

But It only applys on world 2
The spawn car command only on world 1
Because world 0 is for the DM world


Re: How do I make a spawn car command? And more. read topic please. - bartje01 - 18.07.2010

pawn Код:
if(!strcmp(cmd, "/vec", true))
    {
        tmp = strtok(cmdtext, idx);
        if(!strlen(tmp))
        {
            SendClientMessage(playerid, COLOR_WHITE, "Use: /vec [voertuig ID]");
            return 1;
        }
        new vecid = strval(tmp);
        if(vecid >= 400 && vecid <= 611)
        {
         
                new Float:pX, Float:pY, Float:pZ, Float: pA;
                GetPlayerPos(playerid, pX, pY, pZ); GetPlayerFacingAngle(playerid, pA);

                CreateVehicle(vecid, pX, pY, pZ, pA, -1, -1, 900);
               
               
                SendClientMessage(playerid, COLOR_RED, string);
                return 1;
            }
       
        else
        {
            SendClientMessage(playerid, COLOR_RED, "Wrong vehicle ID");
        }
        return 1;
    }
Just a simple /vec command


Re: How do I make a spawn car command? And more. read topic please. - markjaysonpinoy - 18.07.2010

Thanks but I want a dialog box to appear, then players will choose what car they want then press "OK"


Re: How do I make a spawn car command? And more. read topic please. - Jonni8 - 18.07.2010

You have to make a really huge array with all the cars and names so you can categorize em and list them in the box.


Re: How do I make a spawn car command? And more. read topic please. - Mystique - 18.07.2010

https://sampwiki.blast.hk/wiki/ShowPlayerDialog


Re: How do I make a spawn car command? And more. read topic please. - markjaysonpinoy - 19.07.2010

Quote:
Originally Posted by Mystique
Посмотреть сообщение
You aren't helping at all, I know how to make a DIALOG BOX, But I can't make a code to spawn vehlces


Re: How do I make a spawn car command? And more. read topic please. - Mystique - 19.07.2010

Oh, sorry.


Re: How do I make a spawn car command? And more. read topic please. - matthewdriftking - 19.07.2010

Didn't you try to search on sa-mp forum Vehicle FS'S?