Difference between revisions of "Questions"
answering question about moving object
imported>Treleth |
imported>ShadowDancer (answering question about moving object) |
||
Line 1,089: | Line 1,089: | ||
to raise the object higher, there is no effect in-game (I din't forget to use float zposition) | to raise the object higher, there is no effect in-game (I din't forget to use float zposition) | ||
[[User:Treleth|Treleth]] 23:40, 6 July 2006 (EDT) | [[User:Treleth|Treleth]] 23:40, 6 July 2006 (EDT) | ||
:[[User:ShadowDancer|ShadowDancer]] 03:33, 7 July 2006 (EDT): Moving objects to a new position is done with the [[SetPos]] command. What you did with the line of code above was to define a new position on the Z axis. Now you need to set the position. In this case, your code will go from the above to | |||
<pre> | |||
set zposition to GetPos Z + 10 | |||
SetPos Z, zposition | |||
</pre> | |||
The second line will move your object up 10 units on the Z axis to the new location defined by the zposition reference. |