Home   Help Search Login Register  

Author Topic: Moving a object to a diff position  (Read 551 times)

0 Members and 3 Guests are viewing this topic.

Berghoff

  • Guest
Moving a object to a diff position
« on: 20 Feb 2004, 15:32:49 »
Hi all,
I need to know something.

Here is my question:
How do you move a object (Empty Tank in my case) to a position where a marker in on the map ?

So, the empty tank needs to teleport to a position (marker) when a objective is completed.

 :) Hope some1 can help.

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Moving a object to a diff position
« Reply #1 on: 20 Feb 2004, 15:47:27 »
tank1 setPos getMarkerPos "tankMarker1"

or

tank1 setPos getPos GL_1
Plenty of reviewed ArmA missions for you to play

Berghoff

  • Guest
Re:Moving a object to a diff position
« Reply #2 on: 20 Feb 2004, 16:24:59 »
tank1 setPos getMarkerPos "tankMarker1"

or

tank1 setPos getPos GL_1


Perfect thx, now to add a little fun, I need to know the following:

I have 5 markers where to tank can teleport towards, and a script needs to select 1 of those 5 location at random. How do I do that ? ;)

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Moving a object to a diff position
« Reply #3 on: 20 Feb 2004, 16:32:31 »
Something like this, this is just a sketch not a script

_rand = random 6

? _rand < 1: tank1 setpos getpos GL1
? _rand < 2: tank1 setpos getpos GL2

etc
Plenty of reviewed ArmA missions for you to play