wuschel 10 Posted April 9, 2010 Hello, I am trying to figure out how to bring in enemy artillery (CoC-UA) strikes against friendly troops (not essentially the players squad or the player himself). Does anyone have an idea, or maybe a script from old days that gives the smurfs on Your team hell? Or how one could realize this on the map? Of course, the enemy spotter should not be an uber-spotter who obliterates Your team to ashes and dust. I am already working with counter batteries on the map. The ideal scenario, however, would be sporadic shelling of friendly squads that probe the enemy defenses. I searched the forum (especially the old UA threads), but I could not find anything really interesting beside a trigger instruction for the players unit. Regards, wuschel Share this post Link to post Share on other sites
RKDmitriyev 0 Posted April 9, 2010 Yes, there is a way. Short answer: you need to call the function CoCfIFCallFire.sqf (built into the addon). It works, I have gotten this to work before. So execute code like this: [paladin1, leader playergroup] call CoCfIFCallFire CoC UA 1.0 had extensive documentation of all its functions. Unfortunately 1.1 didn't, but this function doesn't seem to have changed. Here's what the 1.0 documentation says: CoCfIFCallFire (CallFire.sqf)Description: Transmits a call for fire to the specified unit. Format: [Firing Unit, [aimpoint, ...], (rounds), (missiontype), (firemode), (distribution), (trajectory] Call CoCfIFCallFire Firing Unit: a unit in the asset group, or the asset group. Aimpoint: an array of aimpoints. Each aimpoint can be a unit, or an array of [x,y,z] locations. Rounds: maximum number of rounds in fire mission. Defaults are M101/M109: 3, M252: 6, MLRS: 12. MissionType: 0 = In Effect, 1 = In Adjust (Default 0) FireMode: 0 = Fire When Ready, 1 = At My Command (Default 0) Distribution (Howitzers only): 0 = BCS, 1 = Converged, 2 = Open, 3 = "Linear Ranged", 4 = Parallel (Default 0) Trajectory (Howitzers only): False = Use Low Angle, True = Use High Angle (Default = False) Examples: [MYHowitzer, [aimpoint]] call CoCfIFCallFire... There's also an 8th parameter not mentioned in the above. According to [CiA]Zwobot (personal communication): Furthermore these are the non-documented parameters for the CoCfIFCallFire function to set ammo type (you have to pass it as 8th parameter): 0 = HE 1 = WP 2 = ICM 3 = DPICM 4 = SMOKE 5 = ILLUM 6 = RAAMS 8 = CLGP 9 = TAC If you give me your email I can also send you the rest of 1.0 documentation if you like. It has a list of all the other functions used in the firing process, not sure how much has changed but my guess is not much. Credit and kudos go to Zwobot, I asked him essentially the same question and he provided me with the information above. Share this post Link to post Share on other sites
zwobot 22 Posted April 25, 2010 Kind of late answer wuschel but maybe you are still looking for a comprehensive solution for your question: I prefer using General Barron's AI infoshare script in combination with his AI artillery script. I have both scripts on my HDD and can send them to you if you cannot acquire them from elsewhere. You need to change the AI artillery script so that it calls the CoCFIFCallFire funciton like RKDmitriyev explained above. The AI infoshare and AI artillery scripts are well documented and I don't want to explain them here in detail here but feel free to ask any specific questions if you come across any problems with them. Share this post Link to post Share on other sites
RKDmitriyev 0 Posted April 30, 2010 I've just discovered that there are in fact even more undocumented parameters that can be added to the end. Looking through CallFire.sqf in the addon pbo, it looks as though there must be at least 13 possible parameters in all. So far I've discovered that the 9th parameter is fuze type. It appears that 0 = QUICK (detonates on impact) 1 = TIME (detonates at a fixed time after firing) 2 = VT (each shell detonates at a random time before or after impact) 3 = DELAY (detonates slightly after impact) Furthermore, it appears when the ammo type is specified, the function will default to DELAY as opposed to QUICK which is default for the FED menu and when the function is called with only the first two parameters. I discovered this in the process of trying to figure out how to make scripted calls for SADARM rounds, which are fun to watch and shred any tanks in the area. I still haven't figured out how to do that, but while tinkering around I noticed that the shells fired from automated missions had different explosions from missions called by the player. I thought this was some kind of weird bug. Then I tinkered some more, looked carefully at callfire.sqf, and found that there are quite a few more parameters, one of which selects the fuze type. Still not sure what the other params do, though. There are many related puzzles, such as why #7 is missing from Zwobot's list. (You wouldn't happen to know, would you, chum?) It would make sense that that would be SADARM, but whenever I try putting a 7 in, it gives an error involving fuze types (and yes, they can be fired normally through FED). I've tried putting in 4 and 5 into the fuze parameter, still no success. I also haven't succeeded in calling smoke through this function. :( Bummer that CoC is mostly dead, but then again, I'm enjoying this little archeological work. :P Share this post Link to post Share on other sites