Home   Help Search Login Register  

Author Topic: Multi Person Rappel  (Read 10700 times)

0 Members and 1 Guest are viewing this topic.

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Multi Person Rappel
« Reply #15 on: 05 Nov 2004, 11:52:17 »
I think it was because you had the script going to something that wasn't there ("loop") whereas it should have been "loop2"

Code: [Select]
#start
ground = false
_man = (_man - 1)
_man1 = _men select (_nMen - _man)
[_man1,_helo] exec "Rappel\Rope1.sqs"
?_man == 1:goto "loop2"
~0.3
_man = (_man - 1)
_man2 = _men select (_nMen - _man)
[_man2,_helo] exec "Rappel\Rope2.sqs"
?_man == 1:goto "loop2"
~0.3
_man = (_man - 1)
_man3 = _men select (_nMen - _man)
[_man3,_helo] exec "Rappel\Rope3.sqs"
?_man == 1:goto "loop2"
~0.5
_man = (_man - 1)
_man4 = _men select (_nMen - _man)
[_man4,_helo] exec "Rappel\Rope4.sqs"
?_man == 1:goto "loop2"
~0.001
goto "loop1"

#loop1
?ground:goto "start"
~0.001
goto "loop1"

#loop2
?ground:goto "end"
~0.001
goto "loop2"

Offline Blip

  • Members
  • *
  • ...Old OFP FART...
Re:Multi Person Rappel
« Reply #16 on: 05 Nov 2004, 17:31:43 »
Hey Triggerhappy-

Ya that was it.  Good eye  :wow:.  I attached the updated file.  I also made it so the units are less likely to get caught on the helicopter when they start to rappel, I made them rappel a little bit faster, and I reduced the delay between each set that goes down the rope.

So now you can rappel anywhere from "1 to as many guys as you can fit in the helicopter."

Can you think of anything else we need to add to it?

Blip  :joystick:
« Last Edit: 05 Nov 2004, 17:32:06 by Blip »
...NIGHT WALKER....

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Multi Person Rappel
« Reply #17 on: 06 Nov 2004, 17:03:20 »
I have another idea
Here it is : (only if the player is pilot)

When the script detects there are men in cargo, the action "start rappel" shows up, of not the action's removed.

I allready have the code for that :

Code: [Select]
_veh = _this select 0

_cargo = crew _veh
? (count crew _veh)<=2 && !isnull driver _veh && !isnull driver _veh : exit
_array = []
"if (_x != driver _veh && _x != gunner _veh) then {_array = _array + [_x]}" foreach _cargo
_cargo = _array
_cargo is an array with all the units in cargo.

?count _cargo != 0 : action shows up
use that, not quite sure if it will work or how it should be used (a seperate script? at the beginning of the rappel script?)
perhaps you could clue me in Blanco?

Offline Blanco

  • Former Staff
  • ****
Re:Multi Person Rappel
« Reply #18 on: 06 Nov 2004, 18:30:13 »
I think you will need a user version and a AI version when you want to use it. It's harder then I thought, first I need to understand the whole rappelscript.
Simply run with the vehicle's name : [heli] exec "script.sqs"
The script checks there's somebody in cargo. If there are some and the player is pilot, the action appears.


but...
I'm working on a version where you dont need to name every single unit on the map. Just make some groups and give them a groupname and run it like this :

[ heli,[grp1,grp2,...] ] exec "rappel.sqs"

 
« Last Edit: 06 Nov 2004, 20:56:33 by Blanco »
Search or search or search before you ask.

Offline Blanco

  • Former Staff
  • ****
Re:Multi Person Rappel
« Reply #19 on: 06 Nov 2004, 20:51:07 »
Allright, it works

Run the script with groupnames instead of unitnames.
Like this :

Code: [Select]
[heli,[grp1,grp2,grp3...]] exec "rappel\rappel.sqs"
In fact, you can run it with single units and groups together because is a single unit is also a group. It's just a group with 1 unit  :)

Name the unit (eg : unit1)
Initiiallise the groupnames (eg : grp1,grp2,grp3)

And run it like this :

Code: [Select]
[heli, [ grp1,grp2,group unit1,grp3,...]] exec "rappel\rappel.sqs"
rappel.sqs is the only script I changed (there are some comments in the beginning) I also renamed the demomission into Multirope_rappelgroup.cain  to avoid confusion.

 
 

« Last Edit: 07 Nov 2004, 07:14:45 by Blanco »
Search or search or search before you ask.

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Multi Person Rappel
« Reply #20 on: 07 Nov 2004, 04:14:46 »
new setup, all that is required with this script is the name of the chopper :D
and it was a lot easier than we made it out to be ;)

I used this line:
_men = (crew _helo) - [commander _helo, gunner _helo, driver _helo]
(I don't think there are any commanders in any helicopters, but I added it just in case) :P

and I don't think you can really change anthing else in this script
perhaps add a hint thing like if there is no one to rappel and then you exit the script.... as in
?_nMen == 0:Hint "No one to Rappel!!!";goto "end"

I also just realized that me n Blanco kinda hijacked your script, hehe, sorry bout that  ;D
« Last Edit: 20 Nov 2004, 19:07:36 by Triggerhappy »

Offline Blip

  • Members
  • *
  • ...Old OFP FART...
Re:Multi Person Rappel
« Reply #21 on: 08 Nov 2004, 23:17:16 »
Hey-

You guys are doing awesome work on this, keep it up.  I think i have done all that I can so I will just be watching from here.

When its all set, we'll just all submitt it together.

Good work,

Blip  :joystick:
...NIGHT WALKER....

Offline Blip

  • Members
  • *
  • ...Old OFP FART...
Re:Multi Person Rappel
« Reply #22 on: 20 Nov 2004, 18:06:43 »
Hey Triggerhappy and Blanco,

I am going to submit the last version of this with all our names on it in the next day or so unless you guys have an objection.

Later,

Blip  :joystick:
...NIGHT WALKER....

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Multi Person Rappel
« Reply #23 on: 20 Nov 2004, 18:46:50 »
just so you know that last version just changed the script, not the mission, so you'll need to fix the mission to go along with the script :P

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Multi Person Rappel
« Reply #24 on: 20 Nov 2004, 19:07:24 »
I took the liberty of doing that for you, and i added the hint thing if there is nobody to rappel.
I would like to know what the script "startrappel.sqs" is used for. i can't find it called anywhere, but i'm guessing that is what is used when you make it an action for the player to choose when to start. Right?
i think that should be deleted so people don't get confused, but thats up to you  ;)
anyway heres the final version unless you change anything

Offline Blip

  • Members
  • *
  • ...Old OFP FART...
Re:Multi Person Rappel
« Reply #25 on: 21 Nov 2004, 03:36:31 »
All right this one is done, or at least its pending.  That startrappel.sqs thing was for the pilot action version.  I deleted it so we should be good to go.

Thanks again Triggerhappy and Blanco.

Blip  :joystick:
...NIGHT WALKER....

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Multi Person Rappel
« Reply #26 on: 21 Nov 2004, 04:34:13 »
no problem  ;)

Offline Blip

  • Members
  • *
  • ...Old OFP FART...
Re:Multi Person Rappel
« Reply #27 on: 06 Dec 2004, 22:27:09 »
Hey All-

Well the script has been submitted.  However, it doesn't work in MP.  I personally have no clue how to adjust the scripts to work.  Any ideas?

Later,

Blip  :joystick:
...NIGHT WALKER....

Offline Triggerhappy

  • Contributing Member
  • **
  • Llama, it's what's for dinner.
Re:Multi Person Rappel
« Reply #28 on: 07 Dec 2004, 03:21:36 »
i see a problem that will make it not work with more than one chopper:
the ropes are global variables, so it just keeps being reassigned a new rope, and only one chopper will throw ropes down..sorry if that is confusing

Offline Flaber

  • Members
  • *
    • Escuadron 13th TigerSharks
Re:Multi Person Rappel
« Reply #29 on: 07 Dec 2004, 10:18:39 »
I have been testing the rappel script in a dedicated server. This are my observations:

1 - When they go out of the helicopter, the rappelers need some seconds (2 - 3) to start the rappel animation, usually reach the ground before the "switchmove" has been completed (50% of the tries, the rappeler died or get severy injured).

2 - I've make a try making the rappelers wait outside the helicopter (yes flying) and not allowing them to start rappeling until the "switchmove" was completed, them they start rappeling fine, but as I say, the stay next to the helicopter flying and you can see them changing from stand or combat position to the rappel anim you have set.

3 - The player, I've try to make the rappel and the switchmove doesn't work at all, so I start rappel in combat position. And the screen is shaking a lot, I usually get a lot of dammage when I reach te ground. (I think that the rappel should be local to the player who is making the rappel, and not executed in the server - only in this case).

I hope to see this great rappel script work as fine in mp missions, like it does in sp missions.

You have made a great job anyway.

Flaber

(sorry for my english - I'm spanish)