Home   Help Search Login Register  

Author Topic: Tanks Firing??  (Read 1239 times)

0 Members and 1 Guest are viewing this topic.

Offline NightJay0044

  • Former Staff
  • ****
  • Let's make OFPEC great again
    • My Steam Workshop
Tanks Firing??
« on: 20 Sep 2005, 23:51:34 »
Here my descrption. This is what I have inserted on the intro island.

-M1A1 Tank
-Mi-24 Hind
-Player (ME)

I've given the Mi-24 a name: H1

MY ISSUE:

I want the M1A1 tank to fire at the hind. Here are the commands that I've already tried using with help from TriggerHappy.

Code: [Select]
this dowatch h1;this dotarget h1;this fire ["gun120","gun120"]
I've put that in the Init Field: of the M1A1 tank. The Tank Targets the hind and follows it with it's turret, but it doesn't open fire.

HELP:
Is there anything I'm doing wrong, or something new needs to be added? Thank you all.

Who's hyped for Arma4, long live Arma!

Kyle Sarnik

  • Guest
Re:Tanks Firing??
« Reply #1 on: 20 Sep 2005, 23:56:57 »
Here my descrption. This is what I have inserted on the intro island.

-M1A1 Tank
-Mi-24 Hind
-Player (ME)

I've given the Mi-24 a name: H1

MY ISSUE:

I want the M1A1 tank to fire at the hind. Here are the commands that I've already tried using with help from TriggerHappy.

Code: [Select]
this dowatch h1;this dotarget h1;this fire ["gun120","gun120"]
I've put that in the Init Field: of the M1A1 tank. The Tank Targets the hind and follows it with it's turret, but it doesn't open fire.

HELP:
Is there anything I'm doing wrong, or something new needs to be added? Thank you all.



The fire command is what you are doing wrong. When using the fire command:
-A unit will ONLY fire if it is ABLE to (waiting for weapon to load, etc..)
-If the unit is ready to fire, it will INSTANTLY fire, not giving it time to target
-If the unit is not able to fire (now this one is odd) it sometimes will cause a unit (it depends on the type of weapon) to fire as soon as it is ready to fire

There is no way to know of the M1 is targeting the hind, and no way to tell if its aiming at it, so that means you can't know when to execute the fire command. My advice is to use an addon that has air targeting shells.

Offline NightJay0044

  • Former Staff
  • ****
  • Let's make OFPEC great again
    • My Steam Workshop
Re:Tanks Firing??
« Reply #2 on: 21 Sep 2005, 00:06:18 »
Hey Kyle Sarnik~

Quote
There is no way to know of the M1 is targeting the hind, and no way to tell if its aiming at it, so that means you can't know when to execute the fire command. My advice is to use an addon that has air targeting shells.

yes what about the Inv.Target or that addon that's out , I have that?
Who's hyped for Arma4, long live Arma!

Kyle Sarnik

  • Guest
Re:Tanks Firing??
« Reply #3 on: 21 Sep 2005, 00:12:18 »
Well, that could work if you used a script to setpos the target over the hind in a loop, however then you might end up with units firing guided anti-tank weapons at the helicopter, and actually locking on to it  :o  

Offline Pilot

  • Contributing Member
  • **
Re:Tanks Firing??
« Reply #4 on: 21 Sep 2005, 00:13:14 »
Wait, NightJay, you said in your first post that the M1 was moving it's turret to look at the Mi-24, right?  This means, to me at least, that the tank is watching the chopper.  The invisible addon should not be needed.  All you need to do is issue the fire command at the right time, which means waiting until the shell is loaded.

-Student Pilot

Offline Tyger

  • Former Staff
  • ****
  • I was at OFPEC when it still had dirt floors...
    • OFPEC
Re:Tanks Firing??
« Reply #5 on: 21 Sep 2005, 00:14:52 »
Or get an invisible target addon and use the Threat: Armor target by setPosing it to the chopper's position.

Edit: Wow. Clicked too late. :P
« Last Edit: 21 Sep 2005, 00:19:13 by Tyger »
"People sleep soundly at night only because rough men stand ready to do violence on their behalf." - George Orwell

MSG Mike Everret - We Will Never Forget - '75-'08

Offline NightJay0044

  • Former Staff
  • ****
  • Let's make OFPEC great again
    • My Steam Workshop
Re:Tanks Firing??
« Reply #6 on: 21 Sep 2005, 00:17:28 »
Student Pilot~

Code: [Select]
Wait, NightJay, you said in your first post that the M1 was moving it's turret to look at the Mi-24, right?  This means, to me at least, that the tank is watching the chopper.  The invisible addon should not be needed.  All you need to do is issue the fire command at the right time, which means waiting until the shell is loaded.

How do I properly execute those commands then?


Tyger ~

Quote
Or get an invisible target addon and use the Threat: Armor target by setPosing it to the chopper's position.

Yes Im sure the inv.addon would work but it there is an easier way I'm all for it.. ;D



Who's hyped for Arma4, long live Arma!

Offline Pilot

  • Contributing Member
  • **
Re:Tanks Firing??
« Reply #7 on: 21 Sep 2005, 00:20:01 »
He shouldn't need an invisible target, the tank already targets the chopper.  His problem is in this code:
Code: [Select]
this dowatch h1;this dotarget h1;this fire ["gun120","gun120"]He's giving the fire command right away, the tank doesn't have a shell ready at that time.  Wait ~30 seconds before giving the fire command.

-Student Pilot

EDIT:
Everyones...posting...too...fast...can't...keep...up :P

Maybe try putting the command in a trigger and setting the trigger to countdown from 30 seconds?
« Last Edit: 21 Sep 2005, 00:21:26 by Student Pilot »

Offline Tyger

  • Former Staff
  • ****
  • I was at OFPEC when it still had dirt floors...
    • OFPEC
Re:Tanks Firing??
« Reply #8 on: 21 Sep 2005, 00:20:08 »
Well, ignore my post. Someone already mentioned it, and apparently I click way too slow :P
"People sleep soundly at night only because rough men stand ready to do violence on their behalf." - George Orwell

MSG Mike Everret - We Will Never Forget - '75-'08

Kyle Sarnik

  • Guest
Re:Tanks Firing??
« Reply #9 on: 21 Sep 2005, 00:25:04 »
He shouldn't need an invisible target, the tank already targets the chopper.  His problem is in this code:
Code: [Select]
this dowatch h1;this dotarget h1;this fire ["gun120","gun120"]He's giving the fire command right away, the tank doesn't have a shell ready at that time.  Wait ~30 seconds before giving the fire command.

-Student Pilot

EDIT:
Everyones...posting...too...fast...can't...keep...up :P

Maybe try putting the command in a trigger and setting the trigger to countdown from 30 seconds?

But like I said, this is not a sound method. Because you can't detect (in a script) if the tank has a firing solution, you can't be sure that when you issue the fire command that the tank is aiming at its target. And dotarget is NOT allways reliable, it can often not work depending on the units awareness of the target and also a few other factors, and sometimes the unit won't properly update its firing solution in time, meaning it will target where the hind started, but sometimes won't track it properly.

Offline Pilot

  • Contributing Member
  • **
Re:Tanks Firing??
« Reply #10 on: 21 Sep 2005, 00:29:49 »
True, but he's using a dowatch and a dotarget with each other.  I would think with that redundancy the tank would always be looking at the chopper, or at least most of the time.

-Student Pilot

Kyle Sarnik

  • Guest
Re:Tanks Firing??
« Reply #11 on: 21 Sep 2005, 00:31:59 »
True, but he's using a dowatch and a dotarget with each other.  I would think with that redundancy the tank would always be looking at the chopper, or at least most of the time.

-Student Pilot

Dowatch won't ensure anything, dowatch tells a unit to moniter something, not target it. Dowatch on a tank only makes the commander's turret follow the object or, even worse, the driver will point the tank in that direction.

Offline NightJay0044

  • Former Staff
  • ****
  • Let's make OFPEC great again
    • My Steam Workshop
Re:Tanks Firing??
« Reply #12 on: 21 Sep 2005, 00:32:35 »
Thanks for all your replies. Anybody who wants to take a look at the details in-game OFP, download is below..
Who's hyped for Arma4, long live Arma!

Offline NightJay0044

  • Former Staff
  • ****
  • Let's make OFPEC great again
    • My Steam Workshop
Re:Tanks Firing??
« Reply #13 on: 21 Sep 2005, 00:50:00 »
Hoorah, it works with the inv.target addon. Now for my helicopter mission, it opens fire right away at the chopper. Cool thanks guys..
Who's hyped for Arma4, long live Arma!