bot disable.scr

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
Tropheus
Corporal
Posts: 49
Joined: Sun Sep 14, 2003 11:19 pm
Location: france
Contact:

bot disable.scr

Post by Tropheus »

hie everybody.

i try to assign a destination to my allied (single player) with the "clicitem" and binoculars.

all is allright when when there are no enemys.

if i add enemys, the bot which have to run to the point assigned by the system wait for the dead of all enemy before going.
in fact if he begin to fight we have to wait for he finish.

so i try to disable its ai with $john exec global/disable_ai.scr in the spawn level of the main method.
but nothing more
how can i do to do it?

thanks for your wondefull answers.

Tropheus
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

I'm not sure what you mean :?
Image
Bjarne BZR
Site Admin
Posts: 3298
Joined: Wed Feb 05, 2003 2:04 pm
Location: Sweden
Contact:

Post by Bjarne BZR »

jv_map wrote:I'm not sure what you mean :?
He is using the binoculars to assign a target location of an AI character. But it fails (or rather, is delayed) due to combat behaviour having higher priority.

Did I get it ritght Tropheus?
Admin .MAP Forums
Image
Head above heels.
Tropheus
Corporal
Posts: 49
Joined: Sun Sep 14, 2003 11:19 pm
Location: france
Contact:

Post by Tropheus »

yes you get right Bjarne BZR.

my characters havec to wait for the end of the struggle (enemy=0) to move. even if i put the disable_ai.scr in the main method.

Do exist a solution for this?

thanks

tropheus
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

You shouldn't blindly type 'exec global/disable_ai.scr' in your main method. Instead, define which soldier needs his AI disabled:

$guy exec global/disable_ai.scr

Where 'guy' is the targetname of your guy ;)
Image
Tropheus
Corporal
Posts: 49
Joined: Sun Sep 14, 2003 11:19 pm
Location: france
Contact:

Post by Tropheus »

it's what i did (i think).

have a look to my script and tell me where i'm wrong.
main:

exec global/ai.scr
exec global/loadout.scr maps/test_deployer.scr

level waittill prespawn




level waittill spawn


waitthread global/items.scr::add_item "binoculars"
$player item weapons/colt45.tik
$player item weapons/thompsonsmg.tik
$player item weapons/springfield.tik
$player item weapons/M2frag_grenade_sp.tik
$player ammo rifle 200
$player ammo smg 1000
$player ammo grenade 4
$player ammo pistol 1000
$player useweaponclass smg
$player ammo heavy 6
$john.health=300
$player useweaponclass heavy
$john exec global/disable_ai.scr
level.script = test_deployer.scr
end
////////////////////////////////////
voiture:

$john runto $voiture_path
wait move
$john exec global/enable_ai.scr
end
thanks
tropheus
Tropheus
Corporal
Posts: 49
Joined: Sun Sep 14, 2003 11:19 pm
Location: france
Contact:

Post by Tropheus »

No idea????

i'm suprised...


tropheus
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

Ideas... yes!
Time... no :(

Anyway

wait move

should be

$john waittill movedone
Image
Post Reply