OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Bobthealmighty on 23 Apr 2004, 19:50:57

Title: how to change the height of an object
Post by: Bobthealmighty on 23 Apr 2004, 19:50:57
is there a way to change the starting height of a man?
Title: Re:how to change the height of an object
Post by: Loup-Garou on 23 Apr 2004, 20:38:16
Put in the man's init field : this setPos [getPos this select 0,getPos this select 1,X]

X is the height ; it can be a positive or a negative number (6, -4...). Two numbers after "," maximum (0.85...). Note : for : ",", you type "."

DONE !  ;)
Title: Re:how to change the height of an object
Post by: Planck on 23 Apr 2004, 20:46:23
What do you mean?

If you mean can you change his height from say, 5' 6"  to 6' 1", then the answer is no.

If you mean you want him to start up in the air somewhere, then, yes.

Taking the player as an example:

player setpos [getpos player select 0, getpos player select 1, +100]

This will place the player in the same location as he is at present, but 100 metres up in the air.

Of course the fall would kill him.

Just change the +100 to whatever height you want.

Get the Official Command Reference from the Editors Depot.
It is a handy reference for the commands that are available.



Planck