Home   Help Search Login Register  

Author Topic: secondary weapon  (Read 1538 times)

0 Members and 1 Guest are viewing this topic.

bootneckofficer

  • Guest
Re:secondary weapon
« Reply #15 on: 28 Sep 2004, 22:49:04 »
hi kammak
thanks for that!

so i have to have a bloke called gear bag which i delete using the init trigger but where does the ammo crate come in, i get that when u drop the "gearbag" it appears as if you have stashed gear but how do i make it appear?

bootneckofficer

Kammak

  • Guest
Re:secondary weapon
« Reply #16 on: 29 Sep 2004, 01:13:43 »
I'm attaching a zip file with a demo mission  including all the scripts and trigger code.

Its on Everon.  When you preview it in the editor, be sure to hold SHIFT when you click Preview, as that will take you to the Briefing screen.

In the Gear section, the last man will be shown as "Gear Bag".  Load him up with anything you want.

Once the mission starts, he will disappear, and you'll have all the "kmkSquadStuff2" actions in your action menu.  One of those is "Drop Pack".

When you select it, an ammo box will appear 2 meters in front of you.  It will all the gear loaded by the script "LoadGearBag.sqs", as well as whatever you selected for the "Gear Bag" unit in the briefing.

For documentation on the kmkSquadStuff2 scripts, see the "Pending Items" entry in the Editors Depot.

Hope this helps you!  Feel free to post any questions about it.  :)


Kammak

  • Guest
Re:secondary weapon
« Reply #17 on: 29 Sep 2004, 06:56:45 »
Attached is a much simpler version, that includes ONLY the gear bag scripts, and none of the rest of "kmkSquadStuff2".  That first one was probably more than you were looking for.   ;)

There will just be one new action in this one, "Drop Pack".  It is replaced by "Get Pack".

As with the first sample, you can change the pre-loaded contents of the gear bag by editing "LoadGearBag.sqs".  The "Gear Bag" unit still appears in the Briefing roster as well, for the player to select gear too.

bootneckofficer

  • Guest
Re:secondary weapon
« Reply #18 on: 29 Sep 2004, 23:33:46 »
hey kammak thats gr8  

  works a treat  thanks

bootneckofficer

Kammak

  • Guest
Re:secondary weapon
« Reply #19 on: 30 Sep 2004, 00:02:13 »
Good!  I just realized I left out a line on the second set....if you use that version (with just the Get Pack/Drop Pack actions) add the following to the trigger On Activation field, at the end:

kmkPack exec "LoadGearBag.sqs"

That will load the contents from the script into the ammo crate.  Without this change, the ammo crate only has the equipment from the "Gear Bag" unit from the briefing.

The first version is correct, just the second version that I forgot to add the line!   :-[