Someone knows how to...
...hook say and make a command called /rr !rr or .rr (NUM) and the server will make a restart depending of the NUM ?
I have tried with strbreak and changing the str to num,but doesn't works. |
Re: Someone knows how to...
PHP Code:
|
Re: Someone knows how to...
I will test it later,thanks:)
|
Re: Someone knows how to...
What in the world is this???
Code:
equali("rr", cmd[cmd[0] == '!' || cmd[0] == '/' || cmd[0] == '.'])I figured it out. This bool/int conversion assumption is annoying sometimes. It will also return true if you say "rr". You should probably change it to: Code:
equali("rr", cmd[!!(cmd[0] == '!' || cmd[0] == '/' || cmd[0] == '.')]) |
Re: Someone knows how to...
Why double negation? It doesn't change anything here and in the end it's still auto conversion to int.
Did you mean: Code:
equali("rr", cmd[_:(cmd[0] == '!' || cmd[0] == '/' || cmd[0] == '.')]) |
Re: Someone knows how to...
Quote:
But, now that I think of it, it should be something like: Code:
equali("rr", cmd[(cmd[0] == '!' || cmd[0] == '/' || cmd[0] == '.') ? 1 : 0]) |
Re: Someone knows how to...
Quote:
|
Re: Someone knows how to...
Quote:
|
Re: Someone knows how to...
PHP Code:
btw : i will made a const to type !rr /rr .rr or /r !r .r or !restart /restart .restart |
Re: Someone knows how to...
Quote:
|
| All times are GMT -4. The time now is 05:23. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.