Efficient Map Changing System...
#8

Right,

You are requesting us to make you an efficient map changing system are you not? Well this isn't the section for that. if however you're just asking what you need in order to make an efficient map changing system? Simple:

pawn Code:
new Tickets[MAX_TEAMS];

public OnPlayerDeath(playerid, killerid, reason)
{
    // check if guy is in team
    if(playerid == team)
    {
         Tickets[team]--;
    }
    for(new i = 0; i < MAX_TEAMS; i++)
    {
        if(!Tickets[i]) ChangeMap();
}
No timer involved, all you do is count the tickets on death which you would have anyway and you then check if one of the teams has reached zero tickets - and change the map. How else would you be doing it? You could obviously if you believe that those couple nanoseconds are too much on every kill, simply write a multithreaded plugin that holds your tickets and you call a native everytime that calculates the tickets internally and calls the callback on ProcessTick that one team has run out of tickets, but I highly doubt that is necessary.

The rest is up to you. We are not here to make the scripts for you but to point you in the right direction =).

Regards.
Reply


Messages In This Thread
Efficient Map Changing System... - by Littlehelper - 11.06.2012, 16:02
Re: Efficient Map Changing System... - by JhnzRep - 11.06.2012, 16:12
Re: Efficient Map Changing System... - by Littlehelper - 11.06.2012, 17:02
Re: Efficient Map Changing System... - by JhnzRep - 11.06.2012, 18:08
Re: Efficient Map Changing System... - by Littlehelper - 12.06.2012, 04:44
AW: Efficient Map Changing System... - by Extremo - 12.06.2012, 04:58
Re: AW: Efficient Map Changing System... - by Littlehelper - 12.06.2012, 04:59
AW: Efficient Map Changing System... - by Extremo - 12.06.2012, 05:06
Re: Efficient Map Changing System... - by Littlehelper - 12.06.2012, 05:09
AW: Re: Efficient Map Changing System... - by Extremo - 12.06.2012, 05:11

Forum Jump:


Users browsing this thread: 1 Guest(s)