Home   Help Search Login Register  

Author Topic: Random postion of whole group  (Read 1174 times)

0 Members and 1 Guest are viewing this topic.

Offline greg147

  • Contributing Member
  • **
    • Royal Air Assault Battalion
Random postion of whole group
« on: 01 Nov 2005, 18:51:36 »
Hi all,

I've been using the grouping a unit with different markers to get a random position for that unit, but I was wondering if there was a way to randomize the position of more than one unit so they will always be at the same place.
I'm trying to make a camp in the woods random, so I need a way to have tents, a fire and several units to be randomized together at a markers position.

Is there a way to do this?

Oh, and how do you make markers invisible? They're kind of a give away to the units posible positions on the map.

Thanks.
Royal Air Assault Battalion - [L/Cpl] Greg
RAAB

Offline Baddo

  • Former Staff
  • ****
  • Reservist Jaeger
Re:Random postion of whole group
« Reply #1 on: 01 Nov 2005, 19:05:07 »

1. I understand you want to put a group to a random position and create also a camp around them? Maybe you could do it so that first you put the group into the random position - a little delay - then set all the stuff needed for the camp relative to the group's leader. Does that sound like it could work? Of course you should check all possible locations how all the stuff is actually layed on the landscape.

2.To make markers invisible set their type to "empty".
« Last Edit: 01 Nov 2005, 19:09:22 by Baddo »

Offline greg147

  • Contributing Member
  • **
    • Royal Air Assault Battalion
Re:Random postion of whole group
« Reply #2 on: 01 Nov 2005, 19:53:39 »
Thanks, never thought of that. I'll try it  ;)
Royal Air Assault Battalion - [L/Cpl] Greg
RAAB

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Random postion of whole group
« Reply #3 on: 02 Nov 2005, 00:23:59 »
If the group leader is linked to the invisible markers and the group are set to "In formation", they will appear around him whereever he appears.    

Baddo's suggestion for the camp will work fine.    An alternative, which may be useful if the camp has to be different at each location because of the nature of the ground, is to create the camp at every location.   A few seconds into the mission, figure out where the group is and delete all the other camps.

Plenty of reviewed ArmA missions for you to play

Offline greg147

  • Contributing Member
  • **
    • Royal Air Assault Battalion
Re:Random postion of whole group
« Reply #4 on: 02 Nov 2005, 19:19:20 »
I'm trying out Baddos suggestion first, but I've run into a problem.

I've got as the begining of a script:

Code: [Select]
tent1 setpos[getpos sf1 select 0, getpos sf1 select 1, 0]
Where tent1 is the tent and sf1 is the groups leader.
How do I get the tent to appear, say for example, 3m to that guys left, instead of exactly where he is standing?
Royal Air Assault Battalion - [L/Cpl] Greg
RAAB

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:Random postion of whole group
« Reply #5 on: 02 Nov 2005, 19:24:46 »
Hmmmm......something like:

tent1 setpos [(getpos sf1 select 0) +3, getpos sf1 select 1, 0]

Maybe   ::)


Planck
I know a little about a lot, and a lot about a little.

Offline greg147

  • Contributing Member
  • **
    • Royal Air Assault Battalion
Re:Random postion of whole group
« Reply #6 on: 02 Nov 2005, 20:35:05 »
Thanks, that worked   8)
Royal Air Assault Battalion - [L/Cpl] Greg
RAAB