18.08.2014, 19:13
Hello,
So i added a line to my users folder for the amount of death and kills they rack up :
However, when i look into my own user file in scripfile after having /die myself and jump off buildings numerous times my " Death " value is stuck on 1 even though i killed myself in all the way possible.
Hope someone can find me find the issue at hand.
Cheers.
So i added a line to my users folder for the amount of death and kills they rack up :
Код:
public OnPlayerDeath(playerid, killerid, reason) { /////// KILL AND DEATH SYSTEM. new n[MAX_PLAYER_NAME], on[MAX_PLAYER_NAME], file[256], file2[256]; GetPlayerName(playerid, n, sizeof(n)); GetPlayerName(killerid, on, sizeof(on)); format (file, sizeof(file), "MyAdmin/Users/%s.txt",n); format (file2, sizeof(file2), "MyAdmin/Users/%s.txt", on); if(dini_Exists(file)) { dini_IntSet(file,"Deaths", PInfo[playerid][Deaths] + 1 ); return 1; } if(dini_Exists(file2)) { dini_IntSet(file2,"Kills", PInfo[playerid][Kills] + 1 ); return 1; } return 1; }
Hope someone can find me find the issue at hand.
Cheers.