Jump to content
  • 0

pomoc správy po killoch


Emmyson172

Dotaz

Potreboval by som spraviť niečo také.

Hráč Killne 2. hráčov za sebou bez toho aby zomrel a do chatu to napíše Zabil si 2 hráčov za sebou,

Hráč Killne 3. hráčov ........................................................................................si 3 hráčov za sebou.

 

 

a tak ďalej až po 5 

ale keď umrie tak aby mu to počítalo odznova

prosím o pomoc ak to niekto vie

Link to comment
Share on other sites

3 odpovědí na tuto otázku

Recommended Posts

  • 0


new neco[MAX_PLAYERS];


OnPlayerDeath:


neco[playerid] = 0;
neco[killerid]++;
switch(neco[killerid])
{
case 2: SCM(killerid,-1,"Zabil jsi 2 hráče jsi BOSS");
case 3: SCM(killerid,-1,"Zabil jsi 3 hráče jsi BOSS");
case 4: SCM(killerid,-1,"Zabil jsi 4 hráče jsi BOSS");
case 5: SCM(killerid,-1,"Zabil jsi 5 hráčů jsi BOSS");
}
Link to comment
Share on other sites

  • 0

Prečo si neulahčiť prácu ?

 

#include <a_samp>


#define MaxPlayers 50


new KillStreak[MaxPlayers];


public OnPlayerDeath(playerid, killerid, reason)
{
KillStreak[killerid] ++;
KillStreak[playerid] = 0;
if(KillStreak[killerid] <= 5 || KillStreak[killerid] == 1) return false;
new MSG[18];
format(MSG,sizeof(MSG),"Zabil si %d hráčov",KillStreak[killerid]);
SendClientMessage(killerid,-1,MSG);
return true;
}
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...