how to add bots to stock maps ??

Please use this forum to ask all your MoHAA Bots questions / discussions

Moderator: Moderators

Post Reply
garguss
Private
Posts: 6
Joined: Fri Jun 04, 2004 8:30 am

how to add bots to stock maps ??

Post by garguss »

Sory, but my English is not very well because I'm live in poland but I'm still teach it's :D. I've got one question:

I've seen maps like V2 or The hunt with bots so is it real to make DM/TDM stock maps ( like Stalingrad, Village )works with bots ?? If yes please help me how do this :). I have MoH radiant and other stuff but i don't know how do this
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Here this should make it pretty easy :)

/forum/viewtopic.php?t=7957

but, you need a little bit of patience :(
Image
garguss
Private
Posts: 6
Joined: Fri Jun 04, 2004 8:30 am

Post by garguss »

I've got next question:

Can I create pathnodes for jvbot in script file ?? without edit map file ??
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Yes, just make sure you spawn before level waittill prespawn, and remove the .pth file everytime you make a change.
Image
garguss
Private
Posts: 6
Joined: Fri Jun 04, 2004 8:30 am

Post by garguss »

Thanks jv_map and please write example line what adds patchnode.
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

In the news forum see the bots2 beta post. Download it and take a look at the obj/obj_team1.scr :)
Image
garguss
Private
Posts: 6
Joined: Fri Jun 04, 2004 8:30 am

Post by garguss »

Thanks

That will work witch jvbot ver. 1.1 ??

What it is spawnflags 4 ??

level.botnodes[305] = spawn info_pathnode origin ( 3819.527 814.177 -306.103 ) spawnflags 4

what is that nodetype = diverse ??

level.botnodes[305].nodetype = diverse
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Yes it will work with any bot version but for older bots you need to add a couple of more nodes (see bot manual).

Spawnflags 4 I wouldn't know that off the top of my head :? maybe it means this is a cover node?

The .nodetype is only for the bots2 scripts, you don't need it for other bots (and 'diverse' isn't used for bots2 either).
Image
blue60007
General
Posts: 1247
Joined: Sun Mar 07, 2004 11:44 pm

Post by blue60007 »

Yes spawnflags 4 is 'cover'
Image
garguss
Private
Posts: 6
Joined: Fri Jun 04, 2004 8:30 am

Post by garguss »

thanks and sorry but i can't find that bot manual so where it is ??
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

It's in the sticky on the top of this page ;)

http://www.planetmedal.com/freebrief/mo ... ok-manual/
Image
garguss
Private
Posts: 6
Joined: Fri Jun 04, 2004 8:30 am

Post by garguss »

Heh :D

Now I add a pathnodes, pth file was change but bots still don't move, why ??

This is my script file:

// DESTROYED VILLAGE
// ARCHITECTURE: NED
// SCRIPTING: NED

main:

waitthread makepathnodes

// set scoreboard messages
setcvar "g_obj_alliedtext1" "Destroyed Village"
setcvar "g_obj_alliedtext2" ""
setcvar "g_obj_alliedtext3" ""
setcvar "g_obj_axistext1" ""
setcvar "g_obj_axistext2" ""
setcvar "g_obj_axistext3" ""

setcvar "g_scoreboardpic" "mohdm2"

// call additional stuff for playing this map round based is needed
if(level.roundbased)
thread roundbasedthread

level waittill prespawn

//*** Precache Dm Stuff
exec global/DMprecache.scr

exec global/door_locked.scr::lock
level.script = maps/dm/mohdm2.scr
exec global/ambient.scr mohdm2

level waittill spawn

waitthread global/jv_bots/jv_mp_ai.scr::enable

end

//--------------------------------------------------------------------------------

makepathnodes:

level.botnodes[1] = spawn info_pathnode origin ( -704.000 632.000 0.000 ) spawnflags 4
/* -- waitframe -- */
level.botnodes[2] = spawn info_pathnode origin ( -704.000 662.000 0.000 ) spawnflags 4
level.botnodes[3] = spawn info_pathnode origin ( -704.000 692.000 0.000 ) spawnflags 4
level.botnodes[4] = spawn info_pathnode origin ( -704.000 732.000 0.000 ) spawnflags 4
level.botnodes[5] = spawn info_pathnode origin ( -680.000 784.000 0.000 ) spawnflags 4
level.botnodes[6] = spawn info_pathnode origin ( -696.000 816.000 0.000 ) spawnflags 4
level.botnodes[7] = spawn info_pathnode origin ( -696.000 856.000 0.000 ) spawnflags 4
level.botnodes[8] = spawn info_pathnode origin ( -727.000 868.000 0.000 ) spawnflags 4
level.botnodes[9] = spawn info_pathnode origin ( -752.000 888.000 0.000 ) spawnflags 4
level.botnodes[10] = spawn info_pathnode origin ( -782.000 900.000 0.000 ) spawnflags 4
level.botnodes[11] = spawn info_pathnode origin ( -811.000 900.000 0.000 ) spawnflags 4
level.botnodes[12] = spawn info_pathnode origin ( -834.000 920.000 0.000 ) spawnflags 4
level.botnodes[13] = spawn info_pathnode origin ( -855.000 920.000 0.000 ) spawnflags 4
level.botnodes[14] = spawn info_pathnode origin ( -880.000 920.000 0.000 ) spawnflags 4
level.botnodes[15] = spawn info_pathnode origin ( -897.000 900.000 0.000 ) spawnflags 4
level.botnodes[16] = spawn info_pathnode origin ( -920.000 885.000 0.000 ) spawnflags 4
level.botnodes[17] = spawn info_pathnode origin ( -920.000 864.000 0.000 ) spawnflags 4

thread new_player_spawn 1 -718.000 632.000 0.000 90
thread new_player_spawn 0 -856.000 648.000 0.000 270
thread bot_so_spawn 1 -718.000 632.000 0.000
thread bot_so_spawn 1 -730.000 635.000 0.000
thread bot_so_spawn 0 -650.000 -1000.000 600.000
thread bot_so_spawn 0 -2264.000 1280.000 0.000
thread bot_so_spawn 0 -856.000 648.000 0.000

end

//-----------------------------------------------------------------------------

roundbasedthread:

// Can specify different scoreboard messages for round based games here.

level waitTill prespawn

level waittill spawn

// set the parameters for this round based match
level.dmrespawning = 0 // 1 or 0
level.dmroundlimit = 5 // round time limit in minutes
level.clockside = kills // set to axis, allies, kills, or draw

level waittill roundstart

end

//------------------------------------------------------------------------------

bot_model_spawn local.bmodel local.bal local.bso:
local.bspm = spawn local.bmodel
local.bspm.origin = ( 3008.00 local.bso -503.00 )
if (local.bal == 1)
local.bspm.targetname = "alliesspawnpreset"
else
local.bspm.targetname = "axisspawnpreset"
end

//--------------------------------------------------------------------------------

bot_so_spawn local.botso1 local.botso2 local.botso3 local.botso4:
local.botspawner = spawn script_origin
local.botspawner.origin = ( local.botso2 local.botso3 local.botso4 )
if (local.botso1 == 1)
local.botspawner.targetname = "alliesspawn"
else
local.botspawner.targetname = "axisspawn"
end


What's wrong ??
Post Reply