Home   Help Search Login Register  

Author Topic: ammo crate para drop problem... (tried the scripts in editors depot)  (Read 1547 times)

0 Members and 1 Guest are viewing this topic.

Offline filth

  • Members
  • *
  • Who's the bad man?
hello.

i'm trying to get an ammo crate transported by heli and paradropped at a desired location. i have tried adapting the two vehicle paradrop scripts in the editors department (changing vehicles to ammo crates), and here are the issues i came across:

in David Berka's helidrop script, the effect is perfect (seeing the crate suspended below the chopper before release). the release is easy and the drop is perfect, with the ammo crate landing perfectly on the ground. the problem is... that once the crate is down, i can't select any weapons or ammo from the crate itself. it gives me the action menu when i'm close to the crate, and my unit bends down as usual, but cannot actually 'pick up' the ammo. an ideal scenario is that this issue be resolved, as the effects of this script are superior.

however, i did try the other script, by Agent Smith. this is a nice script, (the effects aren't as sweet, as you don't see the crate being transported under the chopper - but that's ok) - but it seems a little more unreliable than the first. the problems i'm encountering are this: sometimes i release the ammo from the chopper and it simply disappears (leaving an empty parachute. other times, the chute and the ammo deploy perfectly, but the ammo is left 30 yards in the air. most of the time, if the ammo crate does reach the ground, it seems to hover a couple of feet above the floor. the good part of this script is that i CAN select the ammo, if the ammo crate reaches the ground successfully. i suppose i'm looking for  a combination of both scripts.

can anyone help please?
thanks, filth.
« Last Edit: 07 Jul 2007, 22:59:36 by filth_merchant 101 »

Offline Mr.Peanut

  • Former Staff
  • ****
  • urp!
filth baby,
have you solved this problem yet? is the problem occuring in MP testing or SP testing? I can not see why the Berka script would alter the behaviour of an ammo crate. O shit.. maybe I do. An ammo crate is a static object. Remove all setVelocity commands from the script and see if that helps. If you are using the script to drop a real vehicle, then you want to leave them in.

Might want to check out my own little demo here: http://www.ofpec.com/forum/index.php?topic=28392.0

edit: yep, I just did a little dig and it is setVelocity that breaks the crates. I'll have to add that to the readme for this resource. You should still check out my script  for the fun of the falling house.
« Last Edit: 03 Jul 2007, 21:16:19 by Mr.Peanut »
urp!

Offline filth

  • Members
  • *
  • Who's the bad man?
peanut, me ol mucker... thx for this reply, coz i hadn't solved the problem... before now. your solution works well (i removed both lines of setvelocity in the script) and now the ammo crate doesn't get destroyed and i can take ammo and weapons from it very nicely thank you very much.  :good:

the only slight niggle i have left is that when the crate hits the floor now, it sinks into the ground until the top of the crate is just visible. any ideas on how to cure this? it seemed to do this every time i tested it, from various altitudes and on variable terrain. also a real bonus would be able to pop a smoke canister out there at the same time as the crate release to mark the drop for ground troops.   :scratch:

just a final thing to add... i didn't think this warranted a new thread, as i reckon the syntax i need is relatively easy, but my scripting skills are nill... what's the condition line i need to set off a trigger everytime any member of group alpha are killed?  :whistle:  ???

cheers buster.

Offline Mr.Peanut

  • Former Staff
  • ****
  • urp!
Try twiddling the following line:
Code: [Select]
? (_chutePosZ > 3) : goto "DropUpdate"Increase the 3 to a value of 3.5 or 4.

OR TRY MY SCRIPT INSTEAD!  :yes:

To pop a smoke afterwards, you need to camCreate a smoke shell at the position of the ammo crate, at the very bottom of the script. Adding  the following lines to the very bottom of the script should do it.
Code: [Select]
~0.5
"SmokeShellGreen" camCreate getPos _car
Could also make it "SmokeShellRed" depending on your colour preference.  :cool2:

As for the other problem, the solution bedges supplied you with for civilians should do it with a few quick modifications.  In the init field for each unit in alpha put:
Code: [Select]
total_alpha = count units group this
Then have a single trigger with side none, repeatedly, and condition:
Code: [Select]
({alive _x} count units alpha) < total_alphaand on activation:
Code: [Select]
total_alpha = ({alive _x} count units alpha); your code snippet hereAs before you might want to make the timout min,max and mid all equal 1 or 2 seconds for this trigger to prevent it firing too quickly.

I think that will work  :shhh:
« Last Edit: 04 Jul 2007, 15:14:36 by Mr.Peanut »
urp!

Offline savedbygrace

  • Intel Depot
  • Administrator
  • *****
  • Be swift to hear...slow to speak...slow to wrath.
Sorry Filth, I'm gonna hijack your thread again.  :whistle: Concerning the Camcreate Snippet. I thought I read somewhere that this could not be used in Multiplayer Missions. Is this true?

Offline filth

  • Members
  • *
  • Who's the bad man?
savedbygrace - i don't know. i will post a question in the mp forum to this effect. thx for bringing it up.

nut bag, you have fixed the following:

ammodrop script issue. tick.
pop a smoke on ammo drop. tick.
trigger set to fire when any member of alpha dies. tick.
brilliant peanut. thank you once again.  :clap:
i only have two more issues with this mission (which is a difficult birth, i can tell you). but they're mp issues. (if anyone wants to help me out over on that forum - feel free - coz the issues are kinda related to the count group unit problems i posted here before.   :whistle:

cheers all.

Offline Mr.Peanut

  • Former Staff
  • ****
  • urp!
filthy,
Just post yer mp issues in the the MP board and i'll do me best...

As for camCreate, it is a local command so it must be run on all clients to work, but I was presuming the the airdrop script was also being run on all clients.  Would be good to tell how you are running the script filth. From a trigger I presume? And what would that trigger's condition be?
« Last Edit: 05 Jul 2007, 18:12:34 by Mr.Peanut »
urp!

Offline filth

  • Members
  • *
  • Who's the bad man?
cheers m8. all sorted now, i think.  :good: the mission's called 'hearts & minds'. just sent it to equinox for uploading to the lol server. see you there m8, and thx for all your help. (check the credits section of the briefing)  ;)