Home   Help Search Login Register  

Author Topic: secondary weapon  (Read 1535 times)

0 Members and 1 Guest are viewing this topic.

bootneckofficer

  • Guest
secondary weapon
« on: 20 Sep 2004, 19:34:34 »
anyone (guessing so :D) know how to get primary weapons as secondary weapons?  eg. sniper rifle as secondary and m16 as primary      to make things more realistic.

Offline dmakatra

  • Members
  • *
  • Better known as Armsty
Re:secondary weapon
« Reply #1 on: 20 Sep 2004, 20:59:22 »
More realistic? Yea right... You've played way too much Call of Duty man.

:beat: *Gets Shot* :beat:

bootneckofficer

  • Guest
Re:secondary weapon
« Reply #2 on: 20 Sep 2004, 21:12:42 »
British snipers carry an SA80 and standard soldiering kit for when they need it  they then stash this kit before stalking to their position/hide   their're not like US snipers who just rely on their spotters/observers for cover.

bootneckofficer

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:secondary weapon
« Reply #3 on: 20 Sep 2004, 23:20:44 »
There is a backpack addon out there, which takes up your secondary weapon slot, and basically acts as a portable ammo crate. But scripting-wise, there is no way to put a rifle in an AT slot.
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Offline Zombie

  • Members
  • *
  • Beware the night, the zombie walks among you
    • USI
Re:secondary weapon
« Reply #4 on: 22 Sep 2004, 15:46:11 »
it can be simulated with adding an action that removes the assault rifle, then adds the sniper rifle, and then when you want to go back, removes the sniper rifle then adds the assault back.  I've tried it and it works, but......."realism" suffers somewhat because I haven't figured out how to determine how much ammo each had before switching, so as it works for me now...you can fire all your m16 ammo, switch to m21, then switch back to m16 and have full ammo again!

djackl

  • Guest
Re:secondary weapon
« Reply #5 on: 22 Sep 2004, 17:27:01 »
well in AA you can wear weapons on your back as well as having one in your hand, you just can't use grenades while you have one on your back.

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:secondary weapon
« Reply #6 on: 22 Sep 2004, 23:09:16 »
well in AA you can wear weapons on your back as well as having one in your hand, you just can't use grenades while you have one on your back.
AA? Are you talking about America's Army? Because I could have sworn this was an OFP editing site... :P

But if you are trying to make the case for realism, then ok, I'll agree with you. I know I can hold a rifle in my hands and run around with one or two slung on my back as well. It would be much easier than carrying a MG and a AA launcher at the same time, too.
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

djackl

  • Guest
Re:secondary weapon
« Reply #7 on: 23 Sep 2004, 00:06:56 »
Quote
But if you are trying to make the case for realism, then ok, I'll agree with you.

What? I thought i was in an AA editing site  ;D nah I was just saying that im sure its possible to carry a gun on your back as well as holding one.

bootneckofficer

  • Guest
Re:secondary weapon
« Reply #8 on: 25 Sep 2004, 22:47:52 »
so i have to pick up a gun in-game, rather than starting with one?

bootneckofficer

Kammak

  • Guest
Re:secondary weapon
« Reply #9 on: 26 Sep 2004, 05:05:15 »
If you don't want to use the backpack addon, try out kmkSquadStuff2 in the pending section of the editor depot.  It includes a *really* simple gear bag system using the action menu.

With the script, you can use ANY ammo crate to simulate your team gear or individual pack.  While it looks kinda odd to have an ammo crate appear instead of a nice looking backpack, it does solve the issue of magic ammo and keeps your "secondary" slot free for an AT4 or radio.

That was my main reason for not using the backpack addon, as it forced you to go through like four or five clicks to get a rocket launcher...in reality you can carry an M16 at-the-ready, a low-vector pack on your back, and have a rocket top-slung for fast readying.  Radiomen also routinely wear a pack on their chest and the radio/frame on their back, while still carrying an M16 at the ready or slung.  A backpack should NOT take up OFP's secondary weapon slot.

Which is why I wrote my gearbag scripts the way I did.  If you want to throw 30 rifles into the "gear bag", go for it!  You bought the game, you are free to play it however you want.  I usually use it in missions for satchel charges, smoke grenades, and a few extra magazines.  But depending on the ammo crate you choose to use with it, you could load as much as you want into it.

The script also supports using one object for the appearance, and placing the ammo crate underground...if you are a stickler for how it looks (and don't like to see the crate).

Edit: The other reason I dislike the backpack addon is that it can't be used with the CoC Scuba gear.

I've got a few missions where the player's squad inserts by scuba.  Once they reach the shore, the player drops the gear bag (using my scirpts) and then orders everyone to remove the LAR7 and gear up for the mission (radios, rocket launchers, 2xSlot machine guns,etc...).  It adds a nice touch of realism to a mission, making the player switch modes from exotic insert gear to mission gear.  And it provides a tense time, as the gear swap has to be done quickly, lest the team be spotted by patrols or rovers.  Kinda fun.  :)

« Last Edit: 26 Sep 2004, 05:28:26 by Kammak »

Kammak

  • Guest
Re:secondary weapon
« Reply #10 on: 26 Sep 2004, 05:19:24 »
RE: Loading the gear bag.

If you want the player to have some say in what is loaded in the gear bag/backpack, instead of forcing them to use whatever the mission editor pre-loads, you can do the following.

Add an *extra* man to the player's squad, and set his Identity name to "Gear Bag".  The player can then load up this extra man with gear during the briefing, then when the mission starts, (init trigger at +1 second) just remove the extra guy from the player's group, iterate through his weapons and ammo and load those items into the gear bag.  It works nicely and gives the player some more freedom to play out the mission how he wants.


Example:

init trigger activation:
((units group player) select (count (units group player))-1) exec "LoadGear.sqs"

Code: [Select]
; LoadGear.sqs

_guy=_this
{kmkPack addWeaponCargo[_x,1]} foreach (weapons _guy)
{kmkPack addMagazineCargo[_x,1]} foreach (magazines _guy)
[_guy] join grpNull
_guy setpos[0,0,0]
deleteVehicle _guy
exit

A lot easier than making a dialog system to select the gear, in my opinion!


bootneckofficer

  • Guest
Re:secondary weapon
« Reply #11 on: 27 Sep 2004, 22:33:02 »
so where do i put the code bit? (as you now know im fairly new to editing but i forget things easily!!!!!!)

bootneckofficer
« Last Edit: 27 Sep 2004, 22:33:43 by bootneckofficer »

Kammak

  • Guest
Re:secondary weapon
« Reply #12 on: 28 Sep 2004, 06:40:48 »
Is the question directed at me?  If so, which code bit are you asking about?

bootneckofficer

  • Guest
Re:secondary weapon
« Reply #13 on: 28 Sep 2004, 19:16:18 »
to kammak!

this bit

; LoadGear.sqs

_guy=_this
{kmkPack addWeaponCargo[_x,1]} foreach (weapons _guy)
{kmkPack addMagazineCargo[_x,1]} foreach (magazines _guy)
[_guy] join grpNull
_guy setpos[0,0,0]
deleteVehicle _guy
exit

where do i put it?

thanks  bootneckofficer

Kammak

  • Guest
Re:secondary weapon
« Reply #14 on: 28 Sep 2004, 21:03:49 »
That bit is a script, which is a text file with an extension of ".sqs".  Put that file in the same folder as your mission, and then the trigger code (from above) will fire it at the start of the mission.