Home   Help Search Login Register  

Author Topic: "nearestBush" :)  (Read 728 times)

0 Members and 1 Guest are viewing this topic.

pangzi

  • Guest
"nearestBush" :)
« on: 02 Aug 2003, 20:20:54 »
Is there a script that makes a soldier run to the nearest bush?
I know there is "nearestobject" and "nearestbuilding" command. But I cannot get it to work with plants or rocks.
thanks :)

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:"nearestBush" :)
« Reply #1 on: 02 Aug 2003, 21:12:04 »
God knows I've tried to do this. Unfortunately, I can't find a way to refer to bushes using the "nearestobject" command. I've tried using the "typeof" command on the object ID of bushes, but it returns nothing. I haven't tried it on rocks though.

I still haven't given up hope on this though.
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Skanderborgvej

  • Guest
Re:"nearestBush" :)
« Reply #2 on: 03 Aug 2003, 18:05:31 »
I don't think there is such a command (don't hit me if there would be one...  ;) ;D)

Maybe you could try:

name domove getpos objectID; this setbehaviour "stealth"

name: name of a guy
objectID: number that's displayed onto the object (if clicked "show id")

GRTZ  ;) Vlaamse Leeuw

pangzi

  • Guest
Re:"nearestBush" :)
« Reply #3 on: 13 Aug 2003, 21:58:34 »
I could kick myself! Simply use Keg's Editor Addon and the nearest object command! Like:

Code: [Select]
this doMove getpos nearestObject [this,"KEGres_Tree016"]
Well it doesn't work universally with all bushes and you first  have to place them by hand in the editor, but it works and involves less typing than that ID stuff. 8)
« Last Edit: 13 Aug 2003, 21:59:04 by FATNINJAKID »

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:"nearestBush" :)
« Reply #4 on: 14 Aug 2003, 06:59:12 »
I guess that will work fine if you are going to manually place all of the bushes in your mission area. Is this on desert island?
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!