OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: R.I.P-omega- on 08 Oct 2005, 23:34:52

Title: NPC Soldiers walk threw buildings.
Post by: R.I.P-omega- on 08 Oct 2005, 23:34:52
Hi, I have a problem i want to get a soldier to walk therew a buliding corriedor and i tryed to use waypoints and it dosent seem to work... he just goes around the building instand threw the corriedor even if i put him inside the corriedor in the middle of it he turnes back and goes around it once agin....

how cold i make him go threw that corriedor?
Title: Re:NPC Soldiers walk threw buildings.
Post by: The-Architect on 08 Oct 2005, 23:35:54
Units in Flashpoint have trouble doing anything inside buildings. Which building is it?
Title: Re:NPC Soldiers walk threw buildings.
Post by: greg147 on 08 Oct 2005, 23:50:44
Have you tried waypointing the unit to a persific position in the building?
Kinda of hard to explain.

Click on the waypoint button, then click on the building itself. You should get an extra menu in the waypoint menu. Its on the right of the box, and has 'Pos1' in it if I remember rightly.
You can change this to make the unit go to different positions  ;)
Title: Re:NPC Soldiers walk threw buildings.
Post by: penguinman on 09 Oct 2005, 06:30:35
if its a straight coridor then its simple,

just get the unit to stand infront of the corridor and when he gets there have him activate a script,
[unit name]exec"gothru.sqs"

Code: [Select]
[u]gothru.sqs[/u]
_unit = _this select 0

_unit playmove"combatrunf"
~1
_unit playmove"combatrunf"
~1
_unit playmove"combatrunf"
~1
_unit playmove"combatrunf"

Repeat

Code: [Select]
_unit playmove"combatrunf"
~1
_unit playmove"combatrunf"
until he gets                                            
thru to the other side
then put exit

that will force him to go.
Title: Re:NPC Soldiers walk threw buildings.
Post by: R.I.P-omega- on 09 Oct 2005, 19:14:46
Well it dose work BUT beteewn evrey animation that he dose there is a sudden stop to the animation, its not flewood cold i make it more flowood?(mind my english)
Title: Re:NPC Soldiers walk threw buildings.
Post by: Morglor9 on 11 Oct 2005, 07:45:09
certainly. just decrease the wait value (~1) to something else. try, say, ~0.5.