Not Spawning the Vehicle
#1

hello guys,,


I have Created Vehicle System and it shows with pic but when i try to spawn a vehicle it shows doesnt spawn any vehicle

Код:
CMD:v (playerid)
{
 ShowModelSelectionMenu(playerid, vehlist, "Vehicles - Click To Spawn");
 return 1;
}
please help me
Reply
#2

Did you add:
PHP код:
new vehlist mS_INVALID_LISTID;
GamemodeInit
vehlist 
LoadModelSelectionMenu("wherethemodelidsareat.txt); 
?
Reply
#3

i did it and still it doesnt works
Reply
#4

What about your selected callback?
PHP код:
public OnPlayerModelSelection(playeridresponselistidmodelid)
{
    if(!
response) return 1;
    
CreateVehicle(..)
    return 
1;

?
Reply
#5

is it blank over here
Код:
CreateVehicle(..)
?
Reply
#6

(..)
Means the params (parameters) like x, y, z and so on.
Fill those in. (If you haven't had this callback & function allready)
Reply
#7

Nop i dont have
Reply
#8

PHP код:
public OnPlayerModelSelection(playeridresponselistidmodelid)
{
    if(
listid == vehlist)
    {
        if(!
response) return 1;
        new 
Float:xFloat:yFloat:zFloat:a;
        
GetPlayerPos(playeridxyz);
        
GetPlayerFacingAngle(playerida);
        new 
tmpcar CreateVehicle(modelidxyza, -1, -1, -10);
        
PutPlayerInVehicle(playeridtmpcar0);
    }
    return 
1;

Reply
#9

this error i got

Код:
C:\Users\DELL\Desktop\Server\gamemodes\freeroam.pwn(4501) : error 017: undefined symbol "listiem"
C:\Users\DELL\Desktop\Server\gamemodes\freeroam.pwn(4507) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
error for 4507
Код:
new tmpcar = CreateVehicle(modelid, x, y, z, a, -1, -1, -1, 0);
Reply
#10

I edited the script I forgot it wasn't a dialog, replace it with listid.

PHP код:
new tmpcar;
tmpcar CreateVehicle 
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)