OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: aurek on 07 Apr 2003, 19:32:17

Title: problem with getting a grop to move without waypoints
Post by: aurek on 07 Apr 2003, 19:32:17
In a mission I am making I have the player and squad, a friendly squad and a friendly BMD.

because I have to setpos theese units around a bit for cutscenes I cant give them waypoints. so Ive used scripts to set they're combat modes and behaviours. For movement I placed an invisible H called bmdpoint1 (etc) and the command:
bmd domove getpos bmdpoint1

Now for the bmd this works fine but not for the friendly squad. Ive tried everything. Telling the leader to domove or commandmove or even every individual soldier domove or commandmove! Ive even tried changing the invisible H for a marker and using getmarkerpos. but nothing works, the squad refuses to move. Can anyone help?
Title: Re:problem with getting a grop to move without waypoints
Post by: macguba on 07 Apr 2003, 21:43:45
try

grp1 move getpos whatever
Title: Re:problem with getting a grop to move without waypoints
Post by: Igor Drukov on 07 Apr 2003, 21:47:08
Or try
"_x commandmove getpos whatever" foreach units friendlysquad
Title: Re:problem with getting a grop to move without waypoints
Post by: Sui on 08 Apr 2003, 01:01:35
Here's a quick rundown on the differences between move, domove and commandmove.

So from that list I'd say your definately after the Move command ;)
Title: Re:problem with getting a grop to move without waypoints
Post by: aurek on 08 Apr 2003, 12:53:06
Excellent I'll try that, thanks :)
Title: Re:problem with getting a grop to move without waypoints
Post by: aurek on 09 Apr 2003, 23:10:23
Ok unfortunatly that dosent work.

Ill explain the format of that part of the mission a little bit.

two mi17's approach your position, one parachutes 4 spetznatz
the other parachutes a bmd
Inside the bmd is a squad

The commander has this in his intfield:
red = group this ;  "_x moveincargo bmd" foreach units red

his name (in editor) is red1 with the squad folling that convention up to 6

So, black out and you, the bmd and red squad are setpos'd. Black in, some titletexts follow.

Black out, setpos bmd and red squad to a position east of you (better for attack)

Using snypirs radio tutorial I have setup so at this point a new option appears in the radio 3 and 4 slot. Red squad attack and bmd attack respectively.

When selecting either of theese a script is run: red.sqs or bmd.sqs

red.sqs contains:

vlad1 sidechat "Red squad, attack"
~4
Red1 globalchat "Roger, moving in now"

red move getpos base
red setbehaviour "combat"
red setcombatmode "red"

Exit  


as aid I have tried every combination of move order and none work (however domove works fine for the bmd)

What am I doing wrong?? :)
Title: Re:problem with getting a grop to move without waypoints
Post by: Sui on 10 Apr 2003, 02:26:04
Hmm... how far away is the group exactly?

I reckon it's because they're crawling to the base, rather than walking/running...

Try setting their behaviour to "AWARE" rather than "COMBAT".

Another thing you could try (if the above isn't the problem) is change red to red1 in your move order. It shouldn't make any difference as far as I can see, but sometimes OFP does strange things ;)
Title: Re:problem with getting a grop to move without waypoints
Post by: aurek on 10 Apr 2003, 10:39:25
They change they're behaviour fine, but then they all just jump on the ground and refuse to move.

Could it be because after setposing them I gave a:
red1 dowatch vlad1
command, could he still be trying to do it and therefore wont move?

Ill try giving the command to red1 and report what happends :)
Title: Re:problem with getting a grop to move without waypoints
Post by: DrStrangelove on 10 Apr 2003, 18:49:57
When playing as group leader and you're getting out of a choppe with the rest of your team they won't follow you, you need to issue the order 'all fall back into formation'. Maybe that's the problem ?
Title: Re:problem with getting a grop to move without waypoints
Post by: Sui on 11 Apr 2003, 01:28:32
They change they're behaviour fine, but then they all just jump on the ground and refuse to move.

That was my point... the AI can sometimes take ages to go anywhere on combat behaviour (as they crawl).

However I think Dr. Strangelove may have hit the nail on the head...

After you give them their move command, try:

"_x dofollow (leader _x)" foreach units group

And see if they move their arses then ;)