AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   First[id] still remains (https://forums.alliedmods.net/showthread.php?t=144071)

DoviuX 11-28-2010 12:55

First[id] still remains
 
PHP Code:

public round_end(id)
{
    if(!
is_user_alive(id))
       return 
PLUGIN_HANDLED;

    
First[id] = false;
    return 
PLUGIN_HANDLED;


It has to make that First[id] was false at the end of the round.
But it doesn't, if it doesn't I can't use another function next round.

YamiKaitou 11-28-2010 12:57

Re: First[id] still remains
 
How are you calling round_end?

DoviuX 11-28-2010 13:01

Re: First[id] still remains
 
PHP Code:

    register_logevent("round_end"2"1=Round_End"); 


YamiKaitou 11-28-2010 13:13

Re: First[id] still remains
 
id is not passed to that event as it is only called once, not per user.

DoviuX 11-28-2010 13:24

Re: First[id] still remains
 
so how do I call it ? or change parameter ?

fysiks 11-28-2010 13:25

Re: First[id] still remains
 
I'll beat him to the punch:

Quote:

Originally Posted by DoviuX
Then how do I set First[id] to false?

You loop through all connected players and set their First[id] variable to false.

EDIT: So close lol.


All times are GMT -4. The time now is 11:27.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.