Home   Help Search Login Register  

Author Topic: Jump Out  (Read 1817 times)

0 Members and 1 Guest are viewing this topic.

Offline unknownx9

  • Members
  • *
Jump Out
« on: 09 Mar 2010, 03:41:24 »
Hello,

I have searched for this but I always seem to get the wrong answer I am looking for. I noticed that a lot of vehicles in Arma 2 have a "Jump Out" action. Now I downloaded a vehicle addon that does not have this option. All I want to do is add that same exact action to this vehicle and make it work like it is suppose to offcourse. I have temperarly added an addaction command to this vehicle which ejects the passenger from this vehicle, and automatically gives him a parachute. But thats not what it does in the default arma vehicle it just ejects you and you have to have a parachute to be able to use it. Another problem with this eject is that it will not respawn when the vehicle respawns but I have found some posts which will help me with that. It also allows you to access the eject from the outside before even entering the vehicle, but it does nothing until you are in the vehicle. Without further typing all I need is that Jump Out action included in the Arma 2 Ace 2 vehicles. If anyone can help that would be great.

Thanks,
Unknownx9

Offline Loyalguard

  • Former Staff
  • ****
Re: Jump Out
« Reply #1 on: 09 Mar 2010, 07:31:20 »
Unknownx9,

I am rusty because I have only had ArmA2 for a few days and have not done any scripting for almost two years, but I was part of the original ACE development team for ArmA that worked on "Jump Out" and other related ACE features so hopefully if my memory serves me right (since I don't have the source code anymore) I can provide some insight.

"Jump Out" is not a vanilla feature (unless I am mistaken), rather it is a feature added by ACE.  So if you see it, it is because you have ACE running.  If you don't run ACE it should disappear I think.  As to why you do not see the "Jump Out" option for your downloaded addon vehicle (with ACE running).  We added "Jump Out" by removing "Eject" by default and adding a specialized type of "Get Out" action (renamed "Jump Out") to certain classes of vehicles to force the player out of the vehicle without automatically deploying a chute (unlike vanilla).  I suspect that your downloaded vehicle addon is not associated with/inherits from the class(es) of vehicles in ACE that have "Jump Out" enabled.  Again, I don't know how it works with ACE2 but I imagine it is still along these lines.

Your addAction solution is a good one, hopefully we can address your issues:

If you add an "Eject" action, the unit ejecting is going to act like all units eject in vanilla...automatically deploying with a chute.  As I stated above, you might try to add an "GetOut" action instead to get the unit out of the vehicle without a parachute...but, without a parachute you would have to create one and move move him into it in order to get him down safely.

Regarding the respawn issue, the most likely reason for this is that whatever code you used to add action to the vehicle originally is not running again on the respawned vehicle.  You will most likely need to find a way to do that again.

In regards to seeing the action outside the vehicle, You can see it from outside because by default it just adds the action, it does not know you need to be inside (and hence does nothing until you are inside) to use it.  So, in the condition parameter of the addAction command you need to add a condition that only enables units in the vehicle to be able to see the action.  Maybe like:

Code: [Select]
player in (crew _target)or
Code: [Select]
_this in (crew _target)
I wish I could give more (like the respawn code and the addAction condition) but I need to get back up to speed first.  Hopefully the above at least explains your issues and gets you pointed in the right direction.  Good Luck!

-Loyal

Original reply edited to streamline response.
« Last Edit: 09 Mar 2010, 08:42:25 by Loyalguard »

Offline ModestNovice

  • Members
  • *
Re: Jump Out
« Reply #2 on: 17 Mar 2010, 01:32:01 »
if the "Eject" action doesn't exist on Aces Vehicles, then they have removed them.
"The road became empty and the people disappeared. The clouds ran away; opened up the sky, and one by one I watched every constellation die."
- Sean "Slug" Daley