Page 1 of 1
[help] Adding bots
Posted: 2010-05-04 23:55
by badmojo420
I was wondering if there are any good tutorials or information about adding coop support to PR maps.
I tried creating a gpm_coop folder in gamemodes, but I'm not sure about the StrategicAreas.ai file and how to create one for my map. I tried using the file from Al basrah and my map still doesn't show up in the list when I try to create a local coop game.
I'm not looking for a perfectly running coop mode. I just want to get some bots in there and see what happens.
Re: [help] Adding bots
Posted: 2010-05-05 00:28
by Sniper77shot
I think I know what you mean but you probably will have difficulty doing it. You have to navmesh(AI template that controls the locations they can and can not go). This can be a really expensive processes, you can do it for free as well by using blender to create a navmesh. I would recommend you don't navmesh but it is worth a try really looks good if you apply for a position for a mod. Outlawz is a navmesher and is pretty good at it, you might be able to but it takes time try and try again if at first you don't succeed.
http://www.bfeditor.org/forums/index.ph ... opic=13991
Re: [help] Adding bots
Posted: 2010-05-05 00:48
by OkitaMakoto
badmojo420 wrote:I was wondering if there are any good tutorials or information about adding coop support to PR maps.
I tried creating a gpm_coop folder in gamemodes, but I'm not sure about the StrategicAreas.ai file and how to create one for my map. I tried using the file from Al basrah and my map still doesn't show up in the list when I try to create a local coop game.
I'm not looking for a perfectly running coop mode. I just want to get some bots in there and see what happens.
if youre JUST looking to get bots added in/being able to see it in the list, then youll have to also edit the file named after the particular map in the "info" folder in your maps directory.
inside the mapnamed text file will be something like:
Code: Select all
<map>
<name> Battle for Qinling </name>
<briefing locid="MAPDESCRIPTION_battle_for_qinling">map description for modders maps not localized (english only)</briefing>
<music> common/Sound\Menu/music/the_battle_for_qinling.ogg </music>
<modes>
<mode type="gpm_cq">
<maptype players="16" type="headon" locid="GAMEMODE_DESCRIPTION_aasinfantry">Unlocalized test for this mode on this map</maptype>
<maptype players="32" type="headon" locid="GAMEMODE_DESCRIPTION_aasalternative">Unlocalized test for this mode on this map</maptype>
<maptype players="64" type="headon" locid="GAMEMODE_DESCRIPTION_aasfullassets">Unlocalized test for this mode on this map</maptype>
</mode>
<mode type="gpm_vehicles">
<maptype players="64" type="headon" locid="GAMEMODE_DESCRIPTION_vehiclewarfare">Unlocalized test for this mode on this map</maptype>
</mode>
<mode type="gpm_skirmish">
<maptype players="16" type="skirmish" locid="GAMEMODE_DESCRIPTION_skirmish">Unlocalized test for this mode on this map</maptype>
</mode>
<mode type="gpm_cnc">
<maptype players="16" type="cnc" locid="GAMEMODE_DESCRIPTION_cnc">Unlocalized test for this mode on this map</maptype>
<maptype players="64" type="cnc" locid="GAMEMODE_DESCRIPTION_cnc">Unlocalized test for this mode on this map</maptype>
</mode>
[b]<mode type="gpm_coop">
<maptype ai="1" players="16" type="headon" locid="GAMEMODE_DESCRIPTION_coopinfantry">Unlocalized test for this mode on this map</maptype>
</mode>[/b]
</modes>
</map>
the bold, but map specific is what youll want to add, so not for quinling but for your maps name...
this of course, will only really just getting it SHOWING UP in the list... normally you need to run through and set where the bots will go, where CP areas are for them, etc.
Without actually setting up specific AI to your map in question, I doubt it will even load up :\
Re: [help] Adding bots
Posted: 2010-05-05 00:59
by badmojo420
Yeah, thanks for that Okita, I had forgotten all about editing that file.
I guess I need to create a navmesh first. And from reading...
Highlight: [Single-Player] 'Navmeshing' explained by [R-CON]Outlawz van Project Reality | Facebook (which is a good writeup that [R-Con]Outlawz did about creating navmeshes)
it seems like a very long and painful process, which will need to be repeated if I change stuff on the map. So, I guess I'll wait until I'm completely done the map before adding in the coop stuff.
Re: [help] Adding bots
Posted: 2010-05-05 01:20
by RoAdRa$H
You guys should extend it to 64
Re: [help] Adding bots
Posted: 2010-05-05 01:57
by badmojo420
RoAdRa$H wrote:You guys should extend it to 64
It is 64 players. It's just the "16 player setup" you can do 64 players on any of them, 16, 32, 64.
Re: [help] Adding bots
Posted: 2010-05-05 04:06
by OkitaMakoto
badmojo420 wrote:Yeah, thanks for that Okita, I had forgotten all about editing that file.
I guess I need to create a navmesh first. And from reading...
Highlight: [Single-Player] 'Navmeshing' explained by [R-CON]Outlawz van Project Reality | Facebook (which is a good writeup that [R-Con]Outlawz did about creating navmeshes)
it seems like a very long and painful process, which will need to be repeated if I change stuff on the map. So, I guess I'll wait until I'm completely done the map before adding in the coop stuff.
No prob
But yeah, without navmeshing, I wonder if the map will even load...
Still, worth a shot by inputting the navmesh/AI info from another similar sized map

Probably wont work though
Re: [help] Adding bots
Posted: 2010-05-05 04:14
by Outlawz7
If you load the map without a navmesh it'll either crash or bots won't move anywhere.
Funny, I thought that highlight was a disaster since it was TL;DR for most
You might want to start here, it's a lot better explained, I used this tut too
http://bf2.e-plaza.de/index.htm
Then for the editing part you can use my tut for 3ds Max 9 at bfeditor.org, unless you want to use Maya
Basic Navmesh Editing In 3ds Max 9 - Official BF Editor Forums
Guess I should probably post that tut here

didn't do it since it looked like no one was ever interested in AI support.
Re: [help] Adding bots
Posted: 2010-05-05 18:20
by Sniper77shot
I have a question, would the size 16 navmesh for a map be the same as a 64, or are they different navmeshes?
Re: [help] Adding bots
Posted: 2010-05-05 18:49
by OkitaMakoto
Sniper77shot wrote:I have a question, would the size 16 navmesh for a map be the same as a 64, or are they different navmeshes?
My guess would be different since they probably have different flags and combat area layouts, just a guess though.
Re: [help] Adding bots
Posted: 2010-05-05 18:56
by Hans Martin Slayer
There's only 1 mesh.
So the 16p is the same mesh as the 64 version.
Only the GPO/ AI setup (combat area, CPs and all that..) is different.
So, I guess I'll wait until I'm completely done the map before adding in the coop stuff.
Wise decision. If you get bored though, you can always whip up a really small mesh without too much hazzle to get some impressions. Did that on Lashkar when i made the map and got sick of running through the empty map looking for stuff without getting shot at by the evil bot horde.
And yeah, Outlawz - post that tut you posted over at bfeditor. It's really good!