.:: Bots United ::.

.:: Bots United ::. (http://forums.bots-united.com/index.php)
-   Common Questions (http://forums.bots-united.com/forumdisplay.php?f=51)
-   -   Turn off Bots shooting back after Teamattack (http://forums.bots-united.com/showthread.php?t=9978)

The Storm 30-06-2018 15:31

Re: Turn off Bots shooting back after Teamattack
 
@RoboCop You seem to be using the dynamic C runtime for Windows(MSVCR120.dll and MSVCV120.dll) which also means that you are using Microsoft Visual Studio 2013. So here you are two things:

1. Link with the static runtime for best compatibility, else the end users will have to install the VC++ redistributable packages. To link with the static runtime go to Project Properties => C/C++ => Code Generation and on the section Runtime Library choose "Multi-threaded Debug(/MTd)" for the debug configuration and "Multi-threaded(/MT)" for the Release configuration. Rebuild the project and publish a new zip.

2. MS Visual Studio 2013 is one of the most buggy VS ever released. I highly recommend to update to MS Visual Studio 2017. :)

3. The dynamic runtime is actually good when you have big project with lots of .exe and .dll files, because it will save you lots of trouble and file size but here for a single .dll the best suit is the static runtime.

RoboCop 30-06-2018 17:08

Re: Turn off Bots shooting back after Teamattack
 
1 Attachment(s)
Yes I wasn't sure on using newer compilers as not every Metamod Addon or even some Source Addons work with newer compilers as Cheeseh did mention that RCBot2 works best on VS 2012 or 2013. Even using GCC 4.8 or 4.9 appears to compile better for like FoxBot and some other bots that seem to hate newer compilers, maybe due to too many depreciation warnings or forward compatibility issues.

Also I'm not a big fan of MSVC but I have already got VS 2017 ready for other projects that aren't as ancient like some old MSVC 6.0 projects back near the end of the 1990s. But personally I seriously think MS are being too inconsiderate as well maybe made a wrong move for taking over Github and buying Nokia's Lumia range that sucks on Windows Phone. So good riddance to Windows Phone SDK! :single fuck:

As for this POD-Bot Windows compiling method I didn't adjust anything apart from using the VS 2013 compiler kit inside VS 2017 and using the newer Metamod headers and HLSDK 2.3 headers. The VS project for POD-Bot already appears to have the Runtime Library in Multi-Threaded mode - individually for Debug and Opt releases.

Anyway I've recompiled them with VS 2017 compiler kit and ensure they got Runtime Libs Multi-Threaded. Try this zip again.

The Storm 30-06-2018 17:14

Re: Turn off Bots shooting back after Teamattack
 
Well, I'm not really sure what's wrong but you are still using the dynamic C/C++ runtime. Anyway chances are better for newer windows to have that installed. If you want share here the whole project ready for compilation with VS 2017 and I will check what's wrong. :)

RoboCop 30-06-2018 17:31

Re: Turn off Bots shooting back after Teamattack
 
Whew quick reply! Sure I've just published the src code on GitHub now! Forgive me but I've not quite neatly fixed the _dbg suffix nor any quick fix Makefiles for compiling only as 32-Bit.

https://github.com/APGRoboCop/podbot_mm

The Storm 30-06-2018 19:04

Re: Turn off Bots shooting back after Teamattack
 
Thanks, I will look on to it later today. :)

The Storm 01-07-2018 03:02

Re: Turn off Bots shooting back after Teamattack
 
1 Attachment(s)
Uploaded static linked version. You forgot to choose "Multi-threaded(/MT)" for the release build... :)

joeysmile 01-07-2018 10:21

Re: Turn off Bots shooting back after Teamattack
 
the new bots work but they seem to crash randomly my server :/ I do not have the server in the last version, and the bot still shoot back, what do we achieved with this update?

RoboCop 01-07-2018 14:25

Re: Turn off Bots shooting back after Teamattack
 
Quote:

Originally Posted by The Storm (Post 67153)
Uploaded static linked version. You forgot to choose "Multi-threaded(/MT)" for the release build... :)

Oh sorry I must of looked at the /MD not /MT compile flag. As I said I'm not a big fan on VS.

The Storm 01-07-2018 19:01

Re: Turn off Bots shooting back after Teamattack
 
Hey guys,

I decided to take a look at the code and it seems that there is already a cvar about the bots shooting back. It's called pb_ffa which can have two values - 0 and 1. Try playing out with it using the official .dll of the bot and check what happens. :)

EDIT: Oh, it seems that this is variable for free for all game mode. Sorry. :(

The Storm 01-07-2018 19:32

Re: Turn off Bots shooting back after Teamattack
 
1 Attachment(s)
OK, I've took some time and added new cvar pb_ffrev with default value 0, i.e. teammate revenge is disabled by default. I'm uploading the new .dll on my post. Please bare in mind that I haven't tested this at all. If you confirm that it is working I will upload the code.


All times are GMT +2. The time now is 23:51.

Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.