Please use this forum to ask all your MoHAA Bots questions / discussions
Moderator: Moderators
small_sumo
Lieutenant General
Posts: 953 Joined: Mon Jul 01, 2002 4:17 pm
Contact:
Post
by small_sumo » Tue Dec 02, 2003 4:11 pm
This is the command i have in my script.
level.jvbot_loopdelay = 2.0
This what I saw in the log.
INFO[jv_mp_ai::setloopdelay]: Using new loop delay: 0.400 seconds (2 fps
Have I written the command wrongly?
Thanks JV.
jv_map
Site Admin
Posts: 6521 Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:
Post
by jv_map » Tue Dec 02, 2003 5:26 pm
Ops looks like a little bot bug
Basically there's two ways to fix this:
Place the level.jvbot_loopdelay = 2 line below the waitthread global/jv_bots/jv_mp_ai.scr::enable line.
Use setcvar jvbot_loopdelay 2 at any convenient time.
small_sumo
Lieutenant General
Posts: 953 Joined: Mon Jul 01, 2002 4:17 pm
Contact:
Post
by small_sumo » Wed Dec 03, 2003 12:52 am
Oh well thats ok, see now I can really see if it makes a difference to fps. Obviousley it never worked before I just didnt notice the error in the log.
Thanks.
Krane
Lieutenant General
Posts: 782 Joined: Sat May 31, 2003 4:18 pm
Location: California, USA
Contact:
Post
by Krane » Mon Dec 08, 2003 3:28 pm
I'm kind of confused, jv:
Can we use:
setcvar jvbot_loopdelay 2
INSTEAD of :
level.jvbot_loopdelay = 2
????????
And the setcvar line should below waitthread etc?????
jv_map
Site Admin
Posts: 6521 Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:
Post
by jv_map » Mon Dec 08, 2003 5:25 pm
The setcvar line can be placed anywhere you want. Setting level.jvbot_loopdelay
after enabling the bots should also work but it may cause unexpected problems
.
Krane
Lieutenant General
Posts: 782 Joined: Sat May 31, 2003 4:18 pm
Location: California, USA
Contact:
Post
by Krane » Tue Dec 09, 2003 9:29 pm
Thanks.
And ,btw, the right way is:
setcvar "jvbot_loopdelay" "2"
Right?
jv_map
Site Admin
Posts: 6521 Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:
Post
by jv_map » Wed Dec 10, 2003 8:06 am
Yup, the second one is better, but as the mohaa scripting language isn't very 'strict' both will work.
small_sumo
Lieutenant General
Posts: 953 Joined: Mon Jul 01, 2002 4:17 pm
Contact:
Post
by small_sumo » Mon Dec 15, 2003 3:01 pm
So is this correct?
waitthread global/jv_bots/jv_mp_ai.scr::enable 0 0 0 0 // enables bots
level.jvbot_loopdelay = 2.0
while !(level.roundstart)
jv_map
Site Admin
Posts: 6521 Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:
Post
by jv_map » Mon Dec 15, 2003 5:37 pm
small_sumo wrote: So is this correct?
waitthread global/jv_bots/jv_mp_ai.scr::enable 0 0 0 0 // enables bots
level.jvbot_loopdelay = 2.0
while !(level.roundstart)
I think it will work, just gotta try it I guess
. Preferrably add an additional wait though. Like:
Code: Select all
waitthread global/jv_bots/jv_mp_ai.scr::enable 0 0 0 0 // enables bots
thread setloopdelay
while !(level.roundstart)
waitframe // I suppose this should be here ;)
// (...)
end
setloopdelay:
wait 1
level.jvbot_loopdelay = 2.0
end
small_sumo
Lieutenant General
Posts: 953 Joined: Mon Jul 01, 2002 4:17 pm
Contact:
Post
by small_sumo » Wed Dec 17, 2003 4:27 am
Great thanks, I will add this to my revised map scripts.
Thanks man.