[HELP] How can i do that?
#1

if player shot with gun,the player take 1 wanted level?
Reply
#2

If you want that if someone kills a player, then he would gain one wanted level and the wanted level will increase with his kills

IF YES then here is the answer

Under OnPlayerDeath(..........){

put this code
pawn Код:
new wlvl=GetPlayerWantedLevel(killerid);
if(wlvl<6) SetPlayerWantedLevel(killerid, wlvl+1);
-Abhinav
Reply
#3

I know that! i want if player shot with gun get wanted
Reply
#4

hmm use "search" maybe there is a same topic
Reply
#5

Read on the wiki about OnPlayerKeyStateChange and then do something like:

pawn Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
  if (PRESSED(KEY_FIRE))
  {
    // change wanted level here
  }
}
Reply
#6

thanxs!!!
Reply
#7

You can also throw in a check if a player which is close enough to get shot by this player, looses health.
Then you "know" that the player gets hit by the player firing rounds.

This will never be 100% working, but if you want to, you can try this out. :P
Reply
#8

can you show this in scripting mode?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)