OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting Resources Beta Testing & Submission => Topic started by: Blip on 02 Mar 2005, 07:59:43

Title: HALO from a C130
Post by: Blip on 02 Mar 2005, 07:59:43
HALO FROM A C130
by BLIP
==========================================

Addons Required:
Hawk's C130 V1.3
http://ofp.gamezone.cz/index.php?showthis=6954

=============What this is...===================
Up to five units including the player can now HALO out the back of a C130.  Player has the ability to move around the inside of the C130 as if in flight.  Includes altimeter scripts and player must pull their own chute

(http://www.geocities.com/justin82t/halo2.jpg)

Blip  :joystick:

SetObjPosObj.sqf function by Raptorsaurus!   ;D
Title: Re:HALO from a C130
Post by: greg147 on 02 Mar 2005, 18:51:35
Not bad  :D

One thing I noticed. Once you're in the plane, theres no way to get out without plumbeting 3000m to your bloody death  ;)
Title: Re:HALO from a C130
Post by: Blip on 02 Mar 2005, 19:45:26
Quote
One thing I noticed. Once you're in the plane, theres no way to get out without plumbeting 3000m to your bloody death

I didn't include a parachute part cause I want to make it all one big script.  So its more or less still developing.  

But if you run something like this out of an action you should be good: unitname addaction ["Halo","parachute.sqs"]
Quote
_man = _this select 0
_man switchmove "Para"


#loop
? (getPos _man select 2) < 100: goto "open"

? _pos < 100 : goto "open"
~0.5
goto "loop"

#open
_man switchmove ""
_man setbehaviour "aware"
_para = "parachuteG" camCreate[(getPos _man select 0), (getPos _man select 1), (getPos _man select 2) + 1]
_man moveindriver _para
_man removeaction 0
exit

That should save you.

Blip
Title: Re:HALO from a C130
Post by: Blip on 02 Mar 2005, 20:33:29
I updated the attachment to include the parachute.   ;)

Be sure to not click on the action if your still in the plane.  It wigs out and just puts you on the ground.  But if you fall out the back and then click the action you will land nice and safe.

Lots still to work on here folks,

Blip :joystick:
Title: Re:HALO from a C130
Post by: Raptorsaurus on 02 Mar 2005, 21:33:45
Blip,

I'm gald to see you found good use of my SetObjPosObj function.  Cheers ;D
Title: Re:HALO from a C130
Post by: Blip on 02 Mar 2005, 22:31:25
Quote
Blip,

I'm gald to see you found good use of my SetObjPosObj function.  Cheers

I used it in the Multirope Rappel as well! :cheers:
It's a great function.

Blip :joystick:
Title: Re:HALO from a C130
Post by: Blip on 06 Mar 2005, 00:07:12
I am almost finish with this scripting.  Here are some links to pictures that show multiple units HALO jumping.

BLIP :joystick:

http://www.geocities.com/justin82t/halo1.jpg (http://www.geocities.com/justin82t/halo1.jpg)
http://www.geocities.com/justin82t/halo2.jpg (http://www.geocities.com/justin82t/halo2.jpg)
http://www.geocities.com/justin82t/halo3.jpg (http://www.geocities.com/justin82t/halo3.jpg)
Title: Re:HALO from a C130
Post by: Silent Sniper on 04 Apr 2005, 18:14:17
Nice work Blip,
i did this a while ago but held the plane up with pallets  :D it worked well, but i couldnt sort out the parachute thing cos im no good at scripting.
glad someone better than me has thought of the same idea, thats what i'd like to see in OFP2, a better physics engine so you can do this while its going along  :)
Title: Re:HALO from a C130
Post by: Blip on 05 Apr 2005, 17:47:05
@Silent Sniper

I've used the pallets as well, although I had them in place to form a more stable walkway for the player to move around in on the plane.  

I am working on trying to incorporate having more troops being able to be passed through the script.  Basically, I want to be able to take forty guys in the back of the C130, who are sitting down in seats, and have them one by one get positioned standing in the C130 and then run out the back followed by the next guy in line.  

Still don't know about the setvelocity out the back of the plane, but will continue to look into it.  Would be cool to get shot out the back.  

Blip :joystick:

Quote
thats what i'd like to see in OFP2, a better physics engine so you can do this while its going along
;D I second this!
Title: Re:HALO from a C130
Post by: 456820 on 09 Apr 2005, 11:01:49
if your riding in the back and press eject sometimes you stay in the back and the you can run out the end
but sometimes you end up on tp of the plane.
but anyway vey nice script just whne im in the air i still have the option to halo
Title: Re:HALO from a C130
Post by: Blip on 25 Jun 2005, 23:02:34
Alright, I think I got all the kinks worked out.  Somebody give this a try and let me know if you have any problems before I submit it to the depot.

New scripts include up to five units possible.  Also uses HAWK's newer C130.  Player must pull his own rip cord and has his own altimeter.

Check first post for links.

Thank you for testing!

Blip :joystick:
Title: Re:HALO from a C130
Post by: 456820 on 26 Jun 2005, 08:36:49
ohhh now this sounds good ill give it a test right now
Title: Re:HALO from a C130
Post by: 456820 on 26 Jun 2005, 08:46:18
okay then the c130 seems to be the same asthe other i think, anyway when you get put in the plane you gradually sink through the floor then just fall out without touching anything ? also it seems so slow once youve opeined your chute you kind of hover for a few seconds then fall really really slowly plus theres a ahint saying to open it around 100-200 i think i opened it about 30 and survived
but still not bad
Title: Re:HALO from a C130
Post by: Jim666 on 26 Jun 2005, 16:48:13
Very nice set of scripts, im going to make a mission using these.

The only downside is having the plane not moving really.

Good work!
Title: Re:HALO from a C130
Post by: Blip on 26 Jun 2005, 18:05:05
Thanks for testing the scripts!

@456820
I have also on occasion gotten the sinking through the bottom of the plane.  The only conclusions I have come to is that the computer has a hard time running the script.  In other words its not fast enough to handle keeping the plane in the setpos loop.  As it is, I have to run this on my brother's computer to get it to work because on mine I fall through the floor like you described.

As for the parachute opening, the hint can be taken out if you dig throught the scripts a little.  I put it there as a recommendation, your right you can survive an opening at a much lower height.

@Jimboob
I agree the plane not moving is a downside however you could have it fly for awhile and then go into the call the scripts as opposed to calling them in the init.sqs, just a thought.

NOTE: The plane tends to very jumpy over water.  Not sure why, but I recommend using the scripts only over land.  Try it and you will see what I mean.  Some spots on the map are just better than others.

Thanks Again,

Blip :joystick:
Title: Re:HALO from a C130
Post by: CAS_Daniel on 27 Jun 2005, 10:26:09
Woah, really cool! Strange feeling actually walking inside a vehicle on Flashpoint while its moving  :P Just tried it, and it works pretty much perfect. Only problem i managed to find is that you can run sometimes fall out when you try and get in the cockpit, but you can always still HALO.  ;)
Pretty much perfect, excellant effect, look forward to using it in a mission.  :D
Title: Re:HALO from a C130
Post by: Blip on 27 Jun 2005, 15:18:01
Thanks for the reply CAS_Daniel  ;D

It definitely has its limitations with the cockpit and all.  You have to be delicate with these scripts, if you try and screw things up then chances are the scripts will screw up.  :P

I wanted to mention that I could change the scripts so that the player is controlled running out the door.  In other words it would be up to you the player to jump out of the plane, then in your action menu there would be something like "Jump Position", which would get you into the freefall position and then finally you could pull the rip cord.

Anybody like this idea or should we leave that its automatically done?

Blip :joystick:
Title: Re:HALO from a C130
Post by: supershooter on 27 Jun 2005, 18:00:45
Sounds good, going to try it now.

CAS_Daniel those cockpit problems have nothing to do with this script. I have been doing all sorts with the C-130, its merely a fault in the addon.


-supershooter
Title: Re:HALO from a C130
Post by: greg147 on 27 Jun 2005, 21:54:22
Just thought of something that might stop the falling through the plane in some places.

Would it be possible to have pallets just under the floor of the plane, so if you do go through it, you only fall through acouple of inches.
If the planes not moving, with some trial and error it should be doable, but if it will work is another question  ;)
Title: Re:HALO from a C130
Post by: Blip on 27 Jun 2005, 22:06:31
Quote
Just thought of something that might stop the falling through the plane in some places.

Would it be possible to have pallets just under the floor of the plane, so if you do go through it, you only fall through acouple of inches.
If the planes not moving, with some trial and error it should be doable, but if it will work is another question  

@greg147

This actually works rather well.  My initial design for these scripts did just that.  The only hard part is making it so that the pallets and the plane don't collide.  I will put up an example later today.  

Your right though, this definitely eliminates falling through the plane.  It also reduces any glitches as a result of the plane setpositioning.  

Only downsides are the wood showing on the floor and the cargo door is on a slight slant which you can't do with the pallets.  Finally, any Cutscenes often can see the pallets since they stick out from the plane.  

Like I said I will put up an example in wee bit shouldn't take long I already have the scripts.

Blip :joystick:
Title: Re:HALO from a C130
Post by: bugkill on 09 Jul 2005, 01:46:37
blip,

    the best halo script yet! i've used it on my vbs1 and it looks awesome. what i do is give the "0,0,1" command and just run right off the ramp because whenever i let the script do it, i got stuck on the ramp ???. the free-fall is good and i can keep a good accountability of my other jumpers. i hope you will expand your work to be used for static-line parachute ops with more paratroopers, but this is an excellent script. one question, is it possible for the AI to do it own it's own? i like doing missions where i have multiple missions playing out and i usually have a recon team jumping into enemy terrority.
Title: Re:HALO from a C130
Post by: penguinman on 09 Jul 2005, 02:28:01
nice script,

one sugjestion,

when the units start falling you should setvelocity them in the opisite direction the plane is faceing, then if they look up they wont see that the plane is right above them even though it should be hundreds of meters  away.
Title: Re:HALO from a C130
Post by: Mikero on 09 Jul 2005, 02:44:02
Gee. I don't know much about scripting Blip, but those jpg's are impessive. Hope you, or someone, tries them out as overview images.
Title: Re:HALO from a C130
Post by: Blip on 09 Jul 2005, 03:34:32
Thanks for the comments, I'm glad you all like it!

@bugkill
I have never tried allowing the AI to do it alone (will look in to this). I have however been able to get the scripts to work without need of the radio, I will post an example mission soon.

It's great to hear that it works on vbs1.  Its definitely an awesome way to start a mission.

@penguinman
I didn't include this in the example mission but if you give the plane a waypoint to move to, then put a global varibal that when set true makes the plane stop the setpos loop then you could have the plane fly off.  I will try to add this in the next version.

@Mikero
Good to hear that somebody thought they were cool.  I actually took those at only a 1000m off the ground by just using camera.sqs

Blip :joystick:

By the way I am working on the static line thing, it may be awhile though.  First attempts were not so good.
Title: Re:HALO from a C130
Post by: Triggerhappy on 12 Jul 2005, 06:42:52
hey blip, as with the rappel scripts, i believe i can help you out here as well.

after staring at your scripts for a while (working it all out in my head) I realized that It can
1)be modified to work for unlimited numbers of jumpers
2) be consolidated into less scripts

it'll take a while cause they're fairly complicated (that stupid special positioning for the leader  ;D among others) so gimme some time but trust me its gonna kick ass once in get it working

I'm also considering dling the c130 addon (i did those rappel scripts without the addon) :P ::) :o hehe
Title: Re:HALO from a C130
Post by: Blip on 12 Jul 2005, 16:00:09
Hey Trigger,

Glad to have you on board again.  Sorry I am not one to put comments in my scripts so they do take a bit to decipher.  

Like I mentioned early I have had trouble with the unlimited jumpers but if you can do it then that would be awesome  ;D.

Let me know if you need help with anything.

Blip :joystick:

Title: Re:HALO from a C130
Post by: Triggerhappy on 12 Jul 2005, 16:24:58
k, I'll pm you
Title: Re:HALO from a C130
Post by: Triggerhappy on 12 Jul 2005, 19:55:54
iv'e only got one script left to fix (and the calls for it), but i need to talk to you about it, check your pm
Title: Re:HALO from a C130
Post by: Triggerhappy on 13 Jul 2005, 04:41:37
ok, figured out the answer to the q i was gonna ask.

would you know, perchance, how many people fit in the cargo section of the plane?

i'll probably go figure that out now as well

one more:
do you care about the player being off to the side like that?
other wise i could make a second line...
Title: Re:HALO from a C130
Post by: Blip on 13 Jul 2005, 05:17:28
I positioned the player off to the side so that they could have some room to run around without having to bump into the AI.  It doesn't have to be that way though.  Experiment, see what you like best.  Chances are what you like will be cool with everyone.

Blip :joystick: