Home   Help Search Login Register  

Author Topic: adding Smoke Shells  (Read 463 times)

0 Members and 1 Guest are viewing this topic.

ukloadtoad

  • Guest
adding Smoke Shells
« on: 30 Aug 2004, 01:28:14 »
Help... I've checked the forums, but none of the stuff on there helped.  I'm trying to add Red smokeshells to a pilot.  I've put the 'addweapon "smokeshellred"' & 'addmagazine "smokeshellred"' in the INIT field, but when I try the mission the smoke shells show up with 0.  I've tried adding the mag first so it loads automatically, but that doesn't help either.  
Does anyone have any advice?

Offline ACF

  • Members
  • *
  • Llama?? Ain't that French for tanks?
Re:adding Smoke Shells
« Reply #1 on: 30 Aug 2004, 01:50:33 »
Apologies if you can already suck eggs but:

this AddWeapon "SmokeShellRed"

. . . would be the correct syntax.  The 'this' is the unit whose init field you're putting the command in.  If the unit was named something you could use:

something AddWeapon "SmokeShellRed"

. . . as an init command or from anywhere else.

What you need to do first is remove an existing mag to make room for the smoke grenade.  Don't know what a pilot's loadout is off the top of my head, but to swap a frag for smoke you'd use:

this RemoveMagazine "HandGrenade"; this AddWeapon "SmokeShellRed"

You don't need to add a weapon as grenades are fired from a Throw.

Don't just rely on the forums, have a dig around in the Editor's Depot for scripting tutorials - it's how we all start. And grab yourself a copy of the BIS/Official Command Reference to start see what other things you can do.

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:adding Smoke Shells
« Reply #2 on: 30 Aug 2004, 03:46:32 »
Correction:

Quote
this RemoveMagazine "HandGrenade"; this AddWeapon "SmokeShellRed"

Should be:

this RemoveMagazine "HandGrenade"; this AddMagazine "SmokeShellRed"

Grenades/smoke grenades/mines/satchel charges/etc are kinda unique when you give them to units. All units already have the "weapon" that use these items, so you just have to add them in like magazines.
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!