dragunov90 0 Posted July 11, 2007 I have a problem with making choopers and planes fire at enymy infantry. After having placed seek and destroy waypoint at an area where they will spot enemy infantry they still won't fire. They just hovering around that waypoint without firing a single missile. This is very annoying that airplanes and helicopters can't provide ground support. Please can anyone help me with this issue? Share this post Link to post Share on other sites
johnnyboy 3797 Posted July 11, 2007 Using "reveal" and "dotarget" and "dofire" might help. But a guaranteed way is to a use an invisible target addon. Â You simply put an invisible armored target near the infantry, reveal the target to the aircraft, and they will attack it. Mapfact has a great addon with invisible targets and much other useful stuff: http://www.mapfact.net/include....f22aada Share this post Link to post Share on other sites
dragunov90 0 Posted July 11, 2007 Thank you my friend! Share this post Link to post Share on other sites
dragunov90 0 Posted July 11, 2007 by the way, the airplanes still don't engage the invisible targets and normal targets and how and where should i put the reveal command I tested like this, one who i named: a1 reveal a2 (second unit) but no target is to be seen what's wrong?? please help Share this post Link to post Share on other sites
xendance 3 Posted July 11, 2007 Such a shame that you have to script them to attack... The native AI code should handle that :| Share this post Link to post Share on other sites
johnnyboy 3797 Posted July 12, 2007 Drag, I confess I hadn't tried this with planes. Â So now I just tested this for an hour, and with planes, I could only get a SU planed to drop a bomb on first pass, and it was always short of target. I could get the KAMOV to consistently fire on a US Armored Target. Â I could not get the MI 17 with Rockets to fire on the US Armored Target. Â Here's the setup that worked for the KAMOV: 1. Create a East Kamov helicopter named Heli, about 500 or more meters away from target, set it to "flying". Â I also set the skill to max. 2. Created a West Armored target named t1. 3. Created a bus for a visual reference next to the target 4. Created player unit 50 meters from bus so don't get shot, and can observe test. 5. Created 3 waypoints for heli. First waypoint, type MOVE: Â On path to target, but short of target about 30 meters. Â Put this in init line: Â <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">this reveal t1; this dotarget t1; this dofire t1 2nd waypoint, type MOVE: Â On same path, put it beyond target 100 meters. 3rd waypoint, type CYCLE. The first waypoint reveals target, and encourages heli to target and fire on the invisible target. Â 2nd waypoint keeps heli moving in same direction, and passing over target. Â 3rd waypoint cycles, so heli repeats first waypoint (moves, reveals, targets, fires). With this approach the KAMOV would often not fire on first pass over target, but then did fire on every subsequent pass. Â It usually fired with guns on first few passes, and then would use the rockets which destroys the target. Why this does not work for MI-17 and SU planes, I do not know. Â Hope this helps you. I have mostly used the invisible targets to get infantry to do exactly what I want them to do for cutscenes, and they behave very well (i.e., get AT soldier to fire rocket at a bunker for instance). Note that bullets pass through invisible targets, so AI continues to fire on the targets until target moved via scripting (setpos or deleteVehicle), or destroyed by "area damage" (i.e. explosions). Â So in the KAMOV example above, the target lives through the gun fire, but then is destroyed once rockets fired on it. Â Once the target is destroyed, the KAMOV stops firing on it. Hope this helps. Share this post Link to post Share on other sites
dragunov90 0 Posted July 12, 2007 I appreciate your work, thank you By the way i'am longing for an Ecp mod that will boost the ai like it did with ofp. I remebered that Ofp become a whole new game with that mod with dynamic ai and such cool stuff. Howeever is there a way to make several invisible armored targets to appear on a map by a mapclick. Because if it would be possible then I could use the choppers like real ground support tu supress fire. That would be very nice. This is what I'am trying to do, some ground support either with planes or choppers. And keep in mind that I don't wanna use "one mapclick airstrike"; or "Mr Murrays airstrike", both of them work very badly and can't be used everywhere on the map. And a final request, but it's necessary is it possible to hide this invisble armored targets so that only aircraft can see it. Thank you Share this post Link to post Share on other sites
johnnyboy 3797 Posted July 12, 2007 Quote[/b] ]is it possible to hide this invisble armored targets so that only aircraft can see it. I don't know how, and I tred for awhile. You would likely have to micromanage placing of the targets so they are where you want them only when the aircraft are near. Reveal them only to the aircraft, and they will likely "see" them sooner than any ground units. Quote[/b] ]is there a way to make several invisible armored targets to appear on a map by a mapclick I've never used onMapClick, but I am sure it returns a position. Therefore this is very possible. Your script would take the mapclick position, and then calculate nearby positions where you want to put invisible targets (calcualte by adding/subtracting an amount of meters from the X and Y coordinates of the map click position). You then use the CreateVehicle command to create invisible targets on the fly at the calculated positions. Or, you can have a set of invisible targets (with names) that you created via the map editor, and in your init.sqs setpos all these invisible targets to [0,0,0], so they are nowhere near the mission area. Then, when you run your onMapClick script, you setpos these targets to the desired calculated positions. When through with them, setpos them back to [0,0,0] or deleteVehicle them. I have found that when you CreateVehicle a target, it takes some time for the ai to see the target, even when "revealed". Seems like objects that are CreateVehicled are not fully enabled in game for a while. But when I use the the 2nd approach above, with targets pre-defined in editor and moved out of the way until I need them, so when I setpos them to where I want them, the AI can see them immediately. Good luck. If you get a nice Air Support mission going using the invisible targets, you should post an example for other folks to benefit from... Share this post Link to post Share on other sites
dragunov90 0 Posted July 12, 2007 well with your help I might fix this (keep in mind that I'am a beginner in scripting) But I'am very handy with the mission editor. If you would have that mapclick with the second option script that creates invisible targets I would be very pleased. Then I would see how you made it ( I understand most of it but not all) And get going with mission editing right away Share this post Link to post Share on other sites