Page 1 of 1
Player variable for referee?
Posted:
23 Nov 2013, 16:08
by Warren1001
if (p.referee)
{
etc
}
Whats the variable for ref?
Re: Player variable for referee?
Posted:
23 Nov 2013, 17:02
by joppiesaus
That vaiable is a boolean, which chooses if the player is a referee in zombie mode. You could do handy stuff with this, for example let him allow to fly during the wave.
Re: Player variable for referee?
Posted:
24 Nov 2013, 02:16
by Warren1001
Yes, yes. But how do I use it? Like, what's the code for it?
Re: Player variable for referee?
Posted:
24 Nov 2013, 19:18
by joppiesaus
I don't know how you mean it... but:
- Code: Select all
bool isPlayerReferee = p.referee;
if (isPlayerReferee) // Or isPlayerreferee == true
{
// CODE GOES HERE
}
// I don't know if you can modify it...
p.referee = true;
Re: Player variable for referee?
Posted:
25 Nov 2013, 06:15
by Warren1001
joppiesaus wrote:I don't know how you mean it... but:
- Code: Select all
bool isPlayerReferee = p.referee;
if (isPlayerReferee) // Or isPlayerreferee == true
{
// CODE GOES HERE
}
// I don't know if you can modify it...
p.referee = true;
Ty, that's exactly what I was looking for.
Re: Player variable for referee?
Posted:
25 Nov 2013, 06:35
by Warren1001
Ugh, nevermind.
I want the thing that does the same thing as p.referee would, but p.referee is not a valid thing to use. What do I use if I want to turn off someone being ref or not without using the command, because I'm rewritting the /referee command.
Re: Player variable for referee?
Posted:
25 Nov 2013, 06:57
by ismellike
For educational purposes, I would recommend you take a look at dotPeek (look it up).