OFPEC Forum

Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: BensTooCool on 15 Apr 2007, 18:39:15

Title: How do I use setHideBehind
Post by: BensTooCool on 15 Apr 2007, 18:39:15
I'm want to make an AI unit move into a building to a specific hide position. I've looked at the command sethidebehind but I don't know how type it I tried this in the final waypoint acct field
Code: [Select]
unit sethidebehind[objectid, hidepostion]
Title: Re: How do I use setHideBehind
Post by: Mandoble on 15 Apr 2007, 19:52:50
You may start checking these:
setHideBehind (http://ofpec.com/COMREF/index.php?action=details&id=715)

findCover (http://ofpec.com/COMREF/index.php?action=details&id=557) or just use a known object. Not object id, but real object (you may use one of the nearest@@@ functions to get it).

getHideFrom (http://ofpec.com/COMREF/index.php?action=details&id=576) It seems this determines from what you are hidding, so that the unit does really hide with the hidding object between the unit and the enemy.

At this time I cannot add much more info about these  :whistle:
Title: Re: How do I use setHideBehind
Post by: BensTooCool on 15 Apr 2007, 21:22:50
I did have a look at those but its the syntax that I'm unsure on
Title: Re: How do I use setHideBehind
Post by: WhisperOFP on 18 Apr 2007, 13:37:10
I think getHideFrom returns the point where to hide behind an object to be hidden from a unit.
I've always seen [0, 0, 0] returned, so I dropped working on the command, but now I see setHideBehind (this command had skipped under my radar), perhaps in fact getHideFrom returns the position where unit should hide in the hiding object model space.
It doesn't really explains why I always got [0, 0, 0] as result, though