ladmin4v2 kills
#1

I'm using this admin script

ladmin4v2

I have a blank gamemode but how to do so that the kills in the admin script represent the score ingame?
Reply
#2

i don't understand... you want if you kill some1 to get +1 score?

try with: SetPlayerScore(killerid,GetPlayerScore(killerid)+1 );
Reply
#3

You can check the amount of kills of the player and according the amount will depict his in game score.

Maybe:

PHP код:
if(PlayerInfo[playerid][Kills] == 10)
{
    
SetPlayerScore(playeridGetPlayerScore(playerid), +1);

Reply
#4

where should I put it?
Reply
#5

Код:
C:\Users\Julius\Desktop\samp03x_svr_R1-2_win32\filterscripts\ladmin4v2.pwn(692) : error 029: invalid expression, assumed zero
C:\Users\Julius\Desktop\samp03x_svr_R1-2_win32\filterscripts\ladmin4v2.pwn(692) : warning 215: expression has no effect
C:\Users\Julius\Desktop\samp03x_svr_R1-2_win32\filterscripts\ladmin4v2.pwn(692) : error 001: expected token: ";", but found ")"
C:\Users\Julius\Desktop\samp03x_svr_R1-2_win32\filterscripts\ladmin4v2.pwn(692) : error 029: invalid expression, assumed zero
C:\Users\Julius\Desktop\samp03x_svr_R1-2_win32\filterscripts\ladmin4v2.pwn(692) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#6

Just put this under OnPlayerDeath
pawn Код:
if(killerid!=INVALID_PLAYER_ID)
{
    PlayerInfo[playerid][Deaths]++;
    PlayerInfo[killerid][Kills]++;
    SetPlayerScore(playerid, GetPlayerScore(playerid) -1);
    SetPlayerScore(killerid, GetPlayerScore(killerid) +1);
}
return 1;
This will increase the killer's score by 1, victim's by -1.
Reply
#7

but I mean the admin script doesnt save player score :S
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)