Home   Help Search Login Register  

Author Topic: Cross-map doMove issues  (Read 714 times)

0 Members and 1 Guest are viewing this topic.

Offline KTottE

  • Former Staff
  • ****
Cross-map doMove issues
« on: 15 Jul 2003, 12:26:50 »
Well it's like this, I have five choppers on station on that little island south-east of Malden. Whenever a west unit is detected (have this part covered) a script is executed that has all the names of the choppers in an array, and uses random to select one of the choppers. So far so good (using hint format[..] to display what's going on) and I couldn't be happier.
I get the position of my west units (only have one west group on the map, so it's fairly easy to know who was detected :)) and both set a marker on their position, and try to order the selected chopper to move there.

I have a valid position through getPos _unit.
I have a valid chopper name.
But
_chopper doMove _pos

Doesn't work.
It works when I test it with a unit that is close to the choppers, that they can "see".
But it doesn't work across the map, which is the way I want it to.
Anyone have any clue what to do?
"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming 'WOW What a Ride!'"

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Cross-map doMove issues
« Reply #1 on: 15 Jul 2003, 12:51:07 »
Have you tried move rather than doMove?

(weak I know, but all I can think of)
Plenty of reviewed ArmA missions for you to play

Offline KTottE

  • Former Staff
  • ****
Re:Cross-map doMove issues
« Reply #2 on: 15 Jul 2003, 12:55:03 »
move
commandMove
same thing
"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming 'WOW What a Ride!'"

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Cross-map doMove issues
« Reply #3 on: 15 Jul 2003, 13:12:39 »
I always bring in Sherlock Holmes at this point.   "When you have eliminated the impossible then whatever is left, however improbable, must be the truth."

So it's not a command problem, since we know that you can make a chopper take off and move across the map.    (Although it might be worth proving that....)

So therefore there is something wrong either _chopper or _pos.

When you say "doesn't work" I presume you mean that nothing happens at all and there is no error message.

What happens if you remove the troublesome line from your script and replace it with

namedChopper1 doMove getPos gamelogic1

Assuming that works try

_chopper doMove getPos gamelogic1
namedChopper1 doMove _pos

and hopefully that will at least tell you where the problem is, exactly.

Sorry I can't be more helpful.
Plenty of reviewed ArmA missions for you to play

Offline KTottE

  • Former Staff
  • ****
Re:Cross-map doMove issues
« Reply #4 on: 15 Jul 2003, 13:19:47 »
Oh my God OFP is cranky sometimes.

Now I have

HELO01 doMove getPos gamelogic1

If the gamelogic1 is placed away on the other side of the map, it doesn't work.
If the gamelogic1 is placed close to the choppers, it works.

Gonna try throwing in a knowsabout in there, to see if there's any difference.
And will see about reveal, isn't there a command like that?
"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming 'WOW What a Ride!'"

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Cross-map doMove issues
« Reply #5 on: 15 Jul 2003, 13:29:08 »
lol I had a feeling, with a OFP guru of your calibre, that it was going to boil down to an OFP crankyness.    I have a vague recollection of this happening to me, trying to move choppers round the map .... they can only understand commands if it's not too far away.   I don't think it's a reveal/knowsabout issue - its a move/domove issue.

The workaround is of course some intermediate gamelogics, either fixed (if the choppers always go to the same general area) or placed by the script.
Plenty of reviewed ArmA missions for you to play

Offline KTottE

  • Former Staff
  • ****
Re:Cross-map doMove issues
« Reply #6 on: 15 Jul 2003, 13:38:47 »
Okay, tested it now. Seems like the upper limit for the chopper (distance between current pos and target) is approximately 1700 meters. It will take it ~20-30 seconds to find out where the target it and take off. I did manage to get it to work at ~2300 meters, but only once, and four consecutive tests at 1682 meters showed that it took of 30 seconds after it was given the order and it flew there no problem.

I've devised a work-around now :)
gamelogic1 will be static, and is always placed on the mainland so that the chopper gets from the little island to the mainland, just north of Le Port. From there I will place a gamelogic called "target", and measure the distance between that and gamelogic1. And every 1000 meters I will place another gamelogic and order the chopper to fly to the next one then the next one then the next one.
Can I use @ to make the script wait for the chopper to arrive at a point before continuing?

like:
Code: [Select]
@HELO01 doMove getPos gamelogic1
@HELO01 doMove getPos gamelogic2
@HELO01 doMove getPos target

"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming 'WOW What a Ride!'"

deaddog

  • Guest
Re:Cross-map doMove issues
« Reply #7 on: 15 Jul 2003, 14:22:45 »
Hey guys,

I've been through this before.  I found the distance limit is around 7000m for chopper movement.  The more scripts you have running, the longer it takes for the game to figure out how to get there (I assume that's what it's doing), so it takes longer for the chopper to start moving.

Something really strange must be going on if you can't get a chopper to fly 2300 meters. The easiest way to figure it out is to have a clean map with no scripts running.  Shouldn't take the AI long to calculate its path.

 :)
« Last Edit: 15 Jul 2003, 14:24:41 by deaddog »

Offline KTottE

  • Former Staff
  • ****
Re:Cross-map doMove issues
« Reply #8 on: 15 Jul 2003, 14:51:17 »
I'll just skip this for now. I need all this stuff on my map for my mission, and I don't have the math-skills to write a script to place logic-waypoints.
I'll do it the easy way and just have two patrolling choppers.
"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming 'WOW What a Ride!'"

Offline macguba

  • Former Staff
  • ****
    • macguba's operation flashpoint page
Re:Cross-map doMove issues
« Reply #9 on: 15 Jul 2003, 15:03:23 »
I suppose you could use

@((helo1 distance logic1) < 100)

syntax not guaranteed but you get the idea.
Plenty of reviewed ArmA missions for you to play

peter

  • Guest
Re:Cross-map doMove issues
« Reply #10 on: 15 Jul 2003, 17:14:20 »
my AH1 flies in 3 min 12000 m to a target unit without any problems ...  :P

... i guess the dedection-part doesnÂ't work proper (passes a wrong var, or so ...)

"the mistake is always where you wouldnÂ't expect it ..."

Offline KTottE

  • Former Staff
  • ****
Re:Cross-map doMove issues
« Reply #11 on: 15 Jul 2003, 17:19:34 »
Well, I have been testing it with a radio trigger that executes the script (callHelo.sqs) which then calls the helo.

The problem could be what deaddog talks about, but there's no way of cutting down the number of units and/or scripts in the mission. I will make some tests later when I feel like it to see how it works.
"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming 'WOW What a Ride!'"

Unnamed

  • Guest
Re:Cross-map doMove issues
« Reply #12 on: 16 Jul 2003, 01:13:16 »
Hmmm....Just an idea I was toying with:

If you create your heli's in the editor then assign them to your array, could you not give them inactive waypoints (perhaps just a couple). Then change the position of the last waypoint when your guy has been spotted and activate it, using SetWPPos and LockWP?

It should be possible if you want to create your heli's on the fly to, aslong as you define the heli groups during initialisation.

Like I said, It was an idea I have not actually tried out yet. So I thought I would post it, so I dont waste my time if someone says it's dumb ::)