Home   Help Search Login Register  

Author Topic: grenadelaunchers  (Read 591 times)

0 Members and 1 Guest are viewing this topic.

Hertog Jan

  • Guest
grenadelaunchers
« on: 14 Jun 2005, 12:51:19 »
Hello,

I wanted to know how to make the AI fire off their grenadelauncher just like some mission in Resistance (Don't know the name, but you have to secure a town with a tankplatoon, grenadelaunchers are set up in the forests)

I looked in the editors depot but I couldn't find anything, only how to plant satchels etc.

The command UNITNAME fire["fire","Grenadelauncher"] didn't work....

So the idea is to create some sort of small artillerybarrage from grenades

Offline Hauk

  • Members
  • *
  • I sail under the Jolly Roger!! Pirates are kings!!
Re:grenadelaunchers
« Reply #1 on: 14 Jun 2005, 13:36:57 »
Code: [Select]
UNITNAME fire["fire","Grenadelauncher"]
If thats the code you used, then its wrong. It should be this

Code: [Select]
UNITNAME fire ["fire","Grenadelauncher"]
Always a space after "fire" ;)

Hauk
« Last Edit: 14 Jun 2005, 13:37:53 by Hauk »

Offline Blanco

  • Former Staff
  • ****
Re:grenadelaunchers
« Reply #2 on: 14 Jun 2005, 13:39:16 »
Wrong.

West units :

Code: [Select]
myunit Fire ["M203Muzzle","GrenadeLauncher", "GrenadeLauncher"]
East units :

Code: [Select]
myunit fire ["GrenadesMuzzle","GrenadeLauncher","GrenadeLauncher"]
Make a whole group of grenadiers fire their nades :

1- initialise your group

Code: [Select]
grengroup = group this
2- fire command for the group

EAST
Code: [Select]
{_x fire ["GrenadesMuzzle","GrenadeLauncher","GrenadeLauncher"]} foreach units grengroup
WEST
Code: [Select]
{_x fire Fire ["M203Muzzle","GrenadeLauncher", "GrenadeLauncher"]}foreach units grengroup
« Last Edit: 14 Jun 2005, 14:00:08 by Blanco »
Search or search or search before you ask.

Offline 456820

  • Contributing Member
  • **
Re:grenadelaunchers
« Reply #3 on: 14 Jun 2005, 16:10:55 »
yep blancos right i used that code in a mission not long ago and worked great the only problem getting them the right distacne from the target wich is a pain in the arse

Hertog Jan

  • Guest
Re:grenadelaunchers
« Reply #4 on: 15 Jun 2005, 20:30:01 »
The unitcommand worked perfectly, but when I tried the group command I got the message unknown operator... and I copied the command from here...

Also I want to know if it's possible to make them fire at a specified target such as a car or something..

And should I replace m203muzzle with MM1muzzle if I want to use the MM1 GrenadeLauncher?

So it would look like this:
Myunit fire ["mm1Muzzle","MM1",MM1"]
« Last Edit: 15 Jun 2005, 20:49:34 by Hertog Jan »

Offline Planck

  • Honoured
  • Former Staff
  • ****
  • I'm never wrong ....I'm just not always right !
Re:grenadelaunchers
« Reply #5 on: 15 Jun 2005, 20:43:34 »
The MM-1 doesn't have a 'muzzle'

It just has the classname "MM1" and magazine name is "MM1Magazine"


Planck
I know a little about a lot, and a lot about a little.