AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   New Plugin Submissions (https://forums.alliedmods.net/forumdisplay.php?f=26)
-   -   Control Bots (https://forums.alliedmods.net/showthread.php?t=336548)

EFFx 02-27-2022 16:24

Control Bots
 
1 Attachment(s)
Control Bots


Release: 02/27/2022
Last Update: 03/21/2022

- Description
- With this plugin you can "control" bots the same way CSGO Competitive rounds have when you Press E and you can play with them.

- Cvars
bcontrol_limit = How many bots can control per round
bcontrol_settings = Which way control is avaliable (0 = no control whatsoever | 1 = control teammates only | 2 = only players with specified flags can control | 3 = can control every bot)
bcontrol_flags = Flag to be able to control bots (in case bcontrol_settings is 2).

- Credits
SPiNX - found his code somewhere, can not find the official link, just made some changes.

- Forwards
client_controlled_pre - Used to block the default infos that the plugin gets from the bot, such as health, armor, weapons (in case of using custom mods that gives different things to the player).
client_controlled_post - Called when player takes control of the bot.

- Change log
Spoiler

q52888940 02-28-2022 08:59

Re: Control Bots
 
Quote:

Originally Posted by EFFx (Post 2772643)
Control Bots


Release: 02/27/2022
Last Update: 02/27/2022

- Description
- With this plugin you can "control" bots the same way CSGO Competitive rounds have when you Press E and you can play with them.

- Cvars
bcontrol_limit = How many bots can control per round
bcontrol_settings = Which way control is avaliable (0 = no control whatsoever | 1 = control teammates only | 2 = only players with specified flags can control | 3 = can control every bot)
bcontrol_flags = Flag to be able to control bots (in case bcontrol_settings is 2).

- Credits
SPiNX - found his code somewhere, can not find the official link, just made some changes.

- Forwards
client_controlled_pre - Used to block the default infos that the plugin gets from the bot, such as health, armor, weapons (in case of using custom mods that gives different things to the player).
client_controlled_post - Called when player takes control of the bot.

- Change log
Spoiler

So, what is the command to control the BOT?

Shadows Adi 02-28-2022 11:24

Re: Control Bots
 
Quote:

Originally Posted by q52888940 (Post 2772719)
So, what is the command to control the BOT?

Quote:

Originally Posted by EFFx (Post 2772643)
when you Press E and you can play with them.


q52888940 02-28-2022 12:18

Re: Control Bots
 
I tried it but it didn't work, AMXX1.9
Bot Control 1.0 SPiNX/EFFEX litt botControl.amxx running
tell me instructions

OciXCrom 02-28-2022 14:07

Re: Control Bots
 
Step 1: die.
Step 2: spectate bot.
Step 3: press E.

EFFx 02-28-2022 16:20

Re: Control Bots
 
Not sure why, try downloading the plugin again and keep me updated if it still happens to you.

q52888940 02-28-2022 18:32

Re: Control Bots
 
Quote:

Originally Posted by OciXCrom (Post 2772743)
Step 1: die.
Step 2: spectate bot.
Step 3: press E.

First of all thanks for your reply, but I have to rant about you, I already said it, I tried it, but it didn't work, you know what I mean?

q52888940 02-28-2022 18:33

Re: Control Bots
 
Quote:

Originally Posted by EFFx (Post 2772756)
Not sure why, try downloading the plugin again and keep me updated if it still happens to you.

Anyway my test didn't work

EFFx 02-28-2022 18:37

Re: Control Bots
 
Well then there's nothing for me to do about your issue, I use it normally.

q52888940 02-28-2022 22:02

Re: Control Bots
 
my game is Czero

DJEarthQuake 03-01-2022 05:57

Re: Control Bots
 
You mean this?
Respawn from bot (or AFK human)

Remember whenever one says just like CS:GO and it isn't they still might try to suit.
Code:
/* * *   SSSSSSSSSSSSSSS PPPPPPPPPPPPPPPPP     iiii  NNNNNNNN        NNNNNNNNXXXXXXX       XXXXXXX * SS:::::::::::::::SP::::::::::::::::P   i::::i N:::::::N       N::::::NX:::::X       X:::::X *S:::::SSSSSS::::::SP::::::PPPPPP:::::P   iiii  N::::::::N      N::::::NX:::::X       X:::::X *S:::::S     SSSSSSSPP:::::P     P:::::P        N:::::::::N     N::::::NX::::::X     X::::::X *S:::::S              P::::P     P:::::Piiiiiii N::::::::::N    N::::::NXXX:::::X   X:::::XXX *S:::::S              P::::P     P:::::Pi:::::i N:::::::::::N   N::::::N   X:::::X X:::::X * S::::SSSS           P::::PPPPPP:::::P  i::::i N:::::::N::::N  N::::::N    X:::::X:::::X *  SS::::::SSSSS      P:::::::::::::PP   i::::i N::::::N N::::N N::::::N     X:::::::::X *    SSS::::::::SS    P::::PPPPPPPPP     i::::i N::::::N  N::::N:::::::N     X:::::::::X *       SSSSSS::::S   P::::P             i::::i N::::::N   N:::::::::::N    X:::::X:::::X *            S:::::S  P::::P             i::::i N::::::N    N::::::::::N   X:::::X X:::::X *            S:::::S  P::::P             i::::i N::::::N     N:::::::::NXXX:::::X   X:::::XXX *SSSSSSS     S:::::SPP::::::PP          i::::::iN::::::N      N::::::::NX::::::X     X::::::X *S::::::SSSSSS:::::SP::::::::P          i::::::iN::::::N       N:::::::NX:::::X       X:::::X *S:::::::::::::::SS P::::::::P          i::::::iN::::::N        N::::::NX:::::X       X:::::X * SSSSSSSSSSSSSSS   PPPPPPPPPP          iiiiiiiiNNNNNNNN         NNNNNNNXXXXXXX       XXXXXXX * *──────────────────────────────▄▄ *──────────────────────▄▄▄▄▄▄▄▄▌▐▄ *─────────────────────█▄▄▄▄▄▄▄▄▌▐▄█ *────────────────────█▄▄▄▄▄▄▄█▌▌▐█▄█ *──────▄█▀▄─────────█▄▄▄▄▄▄▄▌░▀░░▀░▌ *────▄██▀▀▀▀▄──────▐▄▄▄▄▄▄▄▐ ▌█▐░▌█▐▌ *──▄███▀▀▀▀▀▀▀▄────▐▄▄▄▄▄▄▄▌░░░▄▄▌░▐ *▄████▀▀▀▀▀▀▀▀▀▀▄──▐▄▄▄▄▄▄▄▌░░▄▄▄▄░▐ *████▀▀▀▀▀▀▀▀▀▀▀▀▀▄▐▄▄▄▄▄▄▌░▄░░▀▀░░▌ *▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▒▐▄▄▄▄▄▄▌░▐▀▄▄▄▄▀ *▒▒▒▒▄▄▀▀▀▀▀▀▀▀▄▄▄▄▀▀█▄▄▄▄▄▌░░░░░▌ *▒▄▀▀░░░░░░░░░░░░░░░░░░░░░░░░░░░░▌ *▒▌░░░░░▀▄░░░░░░░░░░░░░░░▀▄▄▄▄▄▄░▀▄▄▄▄▄ *▒▌░░░░░░░▀▄░░░░░░░░░░░░░░░░░░░░▀▀▀▀▄░▀▀▀▄ *▒▌░░░░░░░▄▀▀▄░░░░░░░░░░░░░░░▀▄░▄░▄░▄▌░▄░▄▌ *▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀ * * * * * * __..__  .  .\  / *(__ [__)*|\ | >< *.__)|   || \|/  \ * *    Repawn from bots. *    Copyleft (C) Nov 2020 .sρiηX҉. * *    This program is free software: you can redistribute it and/or modify *    it under the terms of the GNU Affero General Public License as *    published by the Free Software Foundation, either version 3 of the *    License, or (at your option) any later version. * *    This program is distributed in the hope that it will be useful, *    but WITHOUT ANY WARRANTY; without even the implied warranty of *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the *    GNU Affero General Public License for more details. * *    You should have received a copy of the GNU Affero General Public License *    along with this program.  If not, see <https://www.gnu.org/licenses/>. *    Credits: AMXX DEV TEAM for everything including adminhelp.sma. *    AMX Mod X, based on AMX Mod by Aleksander Naszko ("OLO"). * *    V1.0 to 1.1 -better unsticking code when bots are crouched against wall. *                -take the place of AFK humans for round. * */

I do not see any resemblance in code at all, but thanks for the credit anyway!
https://forums.alliedmods.net/image-...726f6c2e6a7067

EFFx 03-01-2022 15:54

Re: Control Bots
 
I got the code without that copyright lines. That is why it is not in the code but I remember the name that was inside it. Did not know also that it was posted already in the new plugins submissions, if you got any problem with that we can discuss about it.

Quote:

Originally Posted by DJEarthQuake (Post 2772793)
I do not see any resemblance in code at all, but thanks for the credit anyway!
https://forums.alliedmods.net/image-...726f6c2e6a7067

Seems like I edited so many things it doesn't even look like yours anymore.

DJEarthQuake 03-02-2022 09:46

Re: Control Bots
 
This is all open source. I just wanted to confirm if that was the plugin you meant. Be sure to say how it is different!

georgik57 03-02-2022 13:49

Re: Control Bots
 
gonna test this out when i have time. thanks.

Siska1 03-19-2022 13:12

Re: Control Bots
 
I have "running" , but when press "E" nothing happens !!!

EFFx 03-19-2022 17:46

Re: Control Bots
 
Define "running".

DJEarthQuake 03-20-2022 21:24

Re: Control Bots
 
Other than walk?

EFFx 03-20-2022 22:21

Re: Control Bots
 
There was a quote mark on the running word, indicating that it wasn't literally the word.

DJEarthQuake 03-21-2022 08:30

Re: Control Bots
 
What that means is customer is using your plugin but when they press E nothing happens.

EFFx 03-21-2022 18:14

Re: Control Bots
 
Quote:

Originally Posted by Siska1 (Post 2774718)
I have "running" , but when press "E" nothing happens !!!

Try downloading the plugin again.

SoulWeaver16 03-23-2022 06:52

Re: Control Bots
 
I use Czero and I have many plugins and I can use it normally.

Siska1 03-27-2022 16:50

Re: Control Bots
 
https://i.imgur.com/TjWS4ls.jpg
In fact, I forgot to ask you the most important thing.
Which bots can control this plugin ?
Because I use yapb and when press E nothing happen...

EFFx 03-27-2022 16:59

Re: Control Bots
 
I tested this plugin with podbots. To control, first of all you must be dead. After dying, you must change to first person view as well and then press the E button. By default you can only control bots from the same team as yours, can be changed using the cvar that is shown in the main post.

Siska1 03-27-2022 17:39

Re: Control Bots
 
Quote:

Originally Posted by EFFx (Post 2775349)
I tested this plugin with podbots. To control, first of all you must be dead. After dying, you must change to first person view as well and then press the E button. By default you can only control bots from the same team as yours, can be changed using the cvar that is shown in the main post.

Maybe you will be able to test with yapb bots ?

EFFx 03-27-2022 18:09

Re: Control Bots
 
Well, the plugin uses is_user_bot native to detect bots, if the player has "BOT" as authid, it'll be controlable. Does it make any difference between yapb and podbots? I'm not familiar with this.

Siska1 03-27-2022 18:33

Re: Control Bots
 
I found the problem. It turns out I have another plugin that uses "E".
Sorry to bother you. Now I will think about how I can possibly use both...
Can the button be changed?

EFFx 03-27-2022 18:41

Re: Control Bots
 
You did not ^-^.
For button change, you have to do it manually on line 229:

PHP Code:

if((iButton IN_USE) && (pev(iPlayerpev_iuser1) == OBS_IN_EYE)) 

hlsdk_const.inc:

PHP Code:

#define IN_ATTACK                       (1<<0)
#define IN_JUMP                         (1<<1)
#define IN_DUCK                         (1<<2)
#define IN_FORWARD                      (1<<3)
#define IN_BACK                         (1<<4)
#define IN_USE                          (1<<5)
#define IN_CANCEL                       (1<<6)
#define IN_LEFT                         (1<<7)
#define IN_RIGHT                        (1<<8)
#define IN_MOVELEFT                     (1<<9)
#define IN_MOVERIGHT                    (1<<10)
#define IN_ATTACK2                      (1<<11)
#define IN_RUN                          (1<<12)
#define IN_RELOAD                       (1<<13)
#define IN_ALT1                         (1<<14)
#define IN_SCORE                        (1<<15)     // Used by client.dll for when scoreboard is held down 


Siska1 03-27-2022 19:01

Re: Control Bots
 
Amazing plugin, thank you very much!

EFFx 03-27-2022 19:17

Re: Control Bots
 
Quote:

Originally Posted by Siska1 (Post 2775368)
Amazing plugin, thank you very much!

Happy to read that, I appreciate your words.

DruGzOG 03-28-2022 09:17

Re: Control Bots
 
Great plugin, definitely a fun addon for a mod I've been working with, which will make things easier :D

MayroN 03-28-2022 10:14

Re: Control Bots
 
I also want to note that if you control the Bot, the round is over, and the bomb exploded or killed you after you installed it ... it seems that the following happened - that all the bots were deleted, or the game continued, but you seemed to be alive for Terrorists, and in Taba it reflects that you are an observer ...

Perhaps this was earlier, maybe you have already fixed it, if there was such

EFFx 03-28-2022 18:07

Re: Control Bots
 
Quote:

Originally Posted by DruGzOG (Post 2775409)
Great plugin, definitely a fun addon for a mod I've been working with, which will make things easier :D

Thank you for your words. Happy to help ^^.

Quote:

Originally Posted by MayroN (Post 2775412)
I also want to note that if you control the Bot, the round is over, and the bomb exploded or killed you after you installed it ... it seems that the following happened - that all the bots were deleted, or the game continued, but you seemed to be alive for Terrorists, and in Taba it reflects that you are an observer ...

Perhaps this was earlier, maybe you have already fixed it, if there was such

Keep me updated if that still happens to you and give more detailed infos of how it happens.

damian_roger 04-07-2022 09:00

Re: Control Bots
 
unable to download contact author?

EFFx 05-04-2022 23:03

Re: Control Bots
 
The plugin is right in the main post, buy glasses dawg

Siska1 05-05-2022 05:21

Re: Control Bots
 
I have a problem with the weapons that I add through the plugin to add weapons to the maps when the weapons are not there. When I enter the place of the bot after the next play, he lets me go with a glock, and there is no glock on the map at all. For example, I play an awp map and add a elite pistol and a grenade. But sometimes after a game in the place of a bot it starts me with a glock, and as I said glock is neither on the map nor in the plugin for adding weapons. It's a little complicated, and I use Google, but I hope you understand me.

I discovered one more thing: when I passed the spectator, my name changed to Unnamed and stayed that way until I reconnected.

Again another problem: the bomb timer disappears

This plugin can only work properly if your server is empty and you have no other plugins...

BeNq! 05-12-2022 10:29

Re: Control Bots
 
There is a problem because sometimes it goes to take over a bot from the opposite team ...

EFFx 05-12-2022 12:37

Re: Control Bots
 
Check if the cvar is set to the opposite team as well. There's three configurations that controls whether you can control bots from your team or the enemy team... both teams too.

BeNq! 05-12-2022 16:37

Re: Control Bots
 
This has nothing to do with the CVar as it is rare (e.g. when autobalance switch a player).

EFFx 06-01-2022 19:49

Re: Control Bots
 
Well, if you are spectating a bot, it should take the bot you are spectating as first view. Getting a random enemy bot when you are spectating your teammate doesn't make sense.

BeNq! 06-02-2022 10:00

Re: Control Bots
 
Ok, then I have a piece of advice for you: get on the server, transfer to the opposing team with AMXMODX and see that you can take over the opposing team's bots. Why are you ignoring submissions? Do you think someone is dumb and lying? The simplest solution would be to check get_user_team every time, not save it, e.g. at the start of the round.


All times are GMT -4. The time now is 06:51.

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