OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: NightJay0044 on 14 Nov 2005, 20:37:06

Title: GetPos Command
Post by: NightJay0044 on 14 Nov 2005, 20:37:06
Hi, my question is about the getpos command. I'm familar with it but then again I'm not.

In the command referenec it says this for an example.

Code: [Select]
getPos player
That gives me an error if I type it into an init field of soldier. Not sure.

How do you get the soldier you want to get the other position of another unit then if that didn't work?

Thanks,
NightJay0044
Title: Re:GetPos Command
Post by: Planck on 14 Nov 2005, 20:54:09
'getpos player' in a units init field doesn't really do anything.

It depends what exactly you want your unit to do with the player position.

[unitname] move getpos player

Would tell unitname to move to the players position.
Syntax not 100% guaranteed.   ;D


Planck
Title: Re:GetPos Command
Post by: 456820 on 14 Nov 2005, 21:15:58
soldier1 domove getpos othersoldier

that will work
getpos player will just load into the game were the player is wouldnt do anything unless you tell it to

my above should work correctly

note - try with 'move' and 'domove' commands im not sure what the difference is but i think 'move' is used for entire groups
Title: Re:GetPos Command
Post by: NightJay0044 on 14 Nov 2005, 23:12:29
456820 & Planck~

     Thanks for your help guys. "456820" yours did work but planck your didn't. That clears that one up.

NightJay0044
Title: Re:GetPos Command
Post by: Pilot on 14 Nov 2005, 23:19:22
Use domove for units and move for groups

-Pilot