How to identify the winner??
#1

Hello,
I was trying to make last man standing event recently
I just have faced a problem,How can I get the winner ? (the remaining player)
Reply
#2

Make a new function "CheckLMS" and check it once when someone disconnects/leaves the event.
It would be good if you could post your codes. We can't guess your codes..
Reply
#3

I'm already working on a Last Man Standing filterscript..

I do it like this:
I make a variable that counts the total players, increment it on joining and decrement on leaving and OnPlayerDeath. I check it on OnPlayerDeath callback:
- rough code
pawn Код:
//OnPlayerDeath
if (playerCount == 1)
{
     //loop through all the players present in last man standing and get the name & id (it will get the name and id   of the remaining player because there is only 1 player present in LMS (which was found by our playerCount variable)
     // send message to all
}
I still have to test it, but i don't think there is any other way..
Reply
#4

It seems the simplest and easier way
thanks.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)