Kick a random bot.
Hello everyone. I am trying to kick a bot The first one it finds is fine. It does work how ever. It kicks the bot and If a player try's to connect to the server it wants to kick them no matter how many times they try to connect. Any help would be appreciated.
Here is the code I am using Code:
public kickrandombot(id) |
Re: Kick a random bot.
I'm not exactly sure about what you are saying but everything looks fine to me. Though, your for loop doesn't really do anything. It's just acting as an if statement:
PHP Code:
|
Re: Kick a random bot.
PHP Code:
|
Re: Kick a random bot.
Quote:
|
Re: Kick a random bot.
Thanks guys for the comments.
I have tried almost everything I could think of. It always done the same thing. It "works" but when a player tried to connect. Right after kicking the first bot. It would kick the "first" connecting player. Some players could get in. Some couldn't. I was going by the wiki here. http://www.amxmodx.org/doc/index.htm...et_players.htm As fysiks pointed out. It should of worked and "did". I even added a side by side loop to make sure it wasn't a actual player being kicked. Added is_user_connecting and is_user_connected. From the loop. Like it was counting the player connecting for a bot. Extremely weird. Finally I had enough, So I made this in foxbot's source. PHP Code:
PHP Code:
PHP Code:
Althor |
Re: Kick a random bot.
get_user_userid(players[random_num(1,playerCount)]))
use fysiks method get_user_userid(players[random(playerCount)])) |
Re: Kick a random bot.
Attach the full plugin because what you are describing cannot be happening based on the code that you have shown.
|
| All times are GMT -4. The time now is 13:31. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.