Question
#1

Hello
Can someone tell me how to make that if a Civilian enter
a cop car he will get wanted level like 4 stars

cause i dont know how to make one

Thanks,
DarkLored
Reply
#2

Post this in scripting requests not inside of scripting help.
Reply
#3

I am not requesting for a script i am requesting for help so i need to post it in Scripting help
so i posted where i needed i just want to know how do i make this
Reply
#4

pawn Код:
new definedcar;


OnGameModeInit()
{
    definedcar = CreateVehicle(blah,blah,blah,....);
    return 1;
}

OnPlayerStateChange(playerid, newstate, oldstate)
{
    if(newstate == PLAYER_STATE_DRIVER)
    {
        if(GetPlayerVehicleID(playerid) == definedcar)
        {
            if(gTeam[playerid] != COPS)
            {
                new string[80];
                SendClientMessage(playerid,COLOR_RED,"__**CRIME**__{FFFFFF} You've stolen a police Vehicle.");
                format(string,sizeof(string),"{FF0000}__**CRIME**__{FFFFFF} %s[%i] Has stolen a police  Vehicle.",pname,playerid);
                SendClientMessage(-1,string);          
               SetPlayerWantedLevel(playerid,4);
               return 1;    
            }
        }
    }
    return 1;
}
Reply
#5

I get this following errors and warning:
Код:
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(583) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(584) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(585) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(586) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(587) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(588) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(589) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(590) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(591) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(592) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(593) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(594) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(595) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(596) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(597) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(598) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(602) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(603) : warning 215: expression has no effect
C:\Program Files (x86)\Microsoft Power\GTA San Andreas\TeamDeathMatch\gamemodes\CNR.pwn(2211) : error 076: syntax error in the expression, or invalid function call
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
Reply
#6

Did you just copy the code? -.-'
You have to edit it by yourself, using your variables
Reply
#7

No i edited it and i got these errors and i used AddStaticVehicle for that
Reply
#8

Then, Post the lines

Edit:

First Error I see on my code is this:


pawn Код:
definedcar == CreateVehicle(blah,blah,blah,....);
should be like this (Just one of this =)

pawn Код:
definedcar = CreateVehicle(blah,blah,blah,....);
Reply
#9

I will post one line only
pawn Код:
definedcar = AddStaticVehicle (blabla)
The original line has its own settings I just posted a example
Because my brother is using my computer so I cant get the full code
Reply
#10

Make sure you typed it with one of these "=", In the code I gave you first, I made a mistake. I typed two = insted of 1.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)