Jump to content
Sign in to follow this  
charon productions

DPICM Artillery Addon

Recommended Posts

Charon, you are amazing. Will be awesome in the TG community with some of our 50+ combined arms missions.

Share this post


Link to post
Share on other sites

Again, awesome work. Love to see a throwback type mission with no NVG and just mass amounts of illum fire missions. :D

Share this post


Link to post
Share on other sites

Not sure what you mean by "The brightness is difficult to alter.Things get easily just too bright and blurry in Arma2."

I'm using this for 155mm illumination, based on M485A2 data, and I don't find it to go too bright, and I'm not experiencing any blur effects at all:

//Big artillery, doesn't exist in default classes
class ARTY_Flare_Big: FlareBase
{
	soundFly[] = {"\ArtyFlares\sounds\105mm_Illum.ogg", 1.18, 1};
	timeToLive= 120;
	lightColor[] =
	{
		5.44,
		4.08,
		1.36,
		0
	};
};

The color is based on what I see in this video:

Wgz2bBj14qI

I don't know if this is a 'white' shell (which doesn't burn all that white), a colored shell (yellow, amber), or a problem with the videos white balance. But 'perfect' colors doesn't exist in nature, and thus should be avoided also for flares. The shell I'm using have a candle power rating of 1.000.000 (compared to 90.000 for a white M203 parachute or 8.000 for a green M203 parachute. It's listed with a decent rate of 5m/s which is not too far from Arma2s default (by measuring velocity) 7m/s (7m/s = 23f/s, meaning that for mortar illumination with decent rate of 10-18f/s it's far too fast for these).

Vanilla flare simulation is also completely unaffected by wind. Wind effect should be based on parachute size. I'm using something like this for very simple wind simulation and controlled rate of descent, see the complete script with all effects on below.

According to 155mm M485A2 specs, this makes it compatible with 600m HOB and 120s burn time, and illuminates all the way to 1000m (although very weak). Brightness falloff probably not same as in real life, as inverse square rule is considered inefficient for games (probably linear or becomes linear at some point). You need to define _pos, and try with i.e. setWind [10,0,true];

_shell = "ARTY_Flare_Big" createVehicle _pos;
_to_delete = [];
_sm = "#particlesource" createVehicleLocal getPos (_shell);
_sm setParticleRandom [0.5, [0, 0, 0], [0, 0, 0], 0, 0.3, [0, 0, 0, 0], 0, 0, 360];
_sm setParticleParams [["\ca\Data\ParticleEffects\Universal\Universal", 16, 12, 8,0],
"", "Billboard", 1, 30, [0, 0, 0],
[0,0,0], 1, 1, 0.80, 0.5, [1.3,4],
[[0.9,0.9,0.9,0.6], [1,1,1,0.3], [1,1,1,0]],[1],0.1,0.1,"","",_shell];	
_sm setDropInterval 0.02;
_sp = "#particlesource" createVehicleLocal getPos (_shell);
_sp setParticleRandom [0.03, [0, 0, 0], [0, 0, 0], 0, 0.2, [0, 0, 0, 0], 0, 0, 360];
_sp setParticleParams [["\ca\Data\ParticleEffects\Universal\Universal", 16, 13, 2,0],
"", "Billboard", 1, 0.1, [0, 0, 0],
[0,0,0], 1, 1, 0.80, 0.5, [1.5,0],
[[1,1,1,-4], [1,1,1,-4], [1,1,1,-2],[1,1,1,0]],[1000],0.1,0.1,"","",_shell,360];	
_sp setDropInterval 0.001;
_li = "#lightpoint" createVehicleLocal getPos (_shell);
_li setLightBrightness 3.4;
_li setLightAmbient[0.8, 0.6, 0.2];
_li setLightColor[1, 0.5, 0.2];
_li lightAttachObject [_shell, [0,0,0]];
_to_delete = _to_delete + [_sm, _sp, _li];
[_to_delete] spawn {
sleep 120; //Match whatever timetolive the actual flare has
{deleteVehicle _x} forEach (_this select 0);
};
while {!isNull _shell} do {
_shell setPosATL [
	(getPosATL _shell select 0) + (wind select 0)/20,
	(getPosATL _shell select 1) + (wind select 1)/20,
	(getPosATL _shell select 2) + 0.225
];
sleep 0.075;
};

The #lightpoint helps with the weird flicker to black issue, and provides additional illumination.

Not sure if it's something you want to use or not, just giving ideas and input.

I tried asking in offtopic about flare colors, but I didn't get any response.

Share this post


Link to post
Share on other sites

Ok i have considered the wind vector and the smoke development of the flares now.

<object width="425" height="344"><param name="movie" value="http://www.youtube.com/watch?v=oLg1ddbY_io&hl=en_US&fs=1&"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/watch?v=oLg1ddbY_io&hl=en_US&fs=1&" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed></object>

Thanks for the input. Attention to details is valuable (if it is possible to implement that level of detail hehe)

Share this post


Link to post
Share on other sites

Just a small "detail" I noticed, although I'm sure its just because using old placement script. 4 155mm illumination shells at the same spot? :p For coordinated, I'd say one would be enough (they're very bright). For illumination, I think I'd use proper illumination patterns for multi gun fires.

As for #lightpoint usage, although it helps with the flicker to black issue, my main purpose for ever using it was to counter the way to dim vanilla flare brightnesses. When brightness is brought up, I'm not sure the #lightpoint is so much needed anymore.

Regarding color, you have to experiment and see what looks good and natural. I'm starting to get the sense that this is a bit too much on the yellow side. Unless it's a compression issue.

I've since updated the effect a little, to obtain values from the config directly.

_illumeffect = {
private ["_to_delete","_shell","_brightness","_delay","_color"];
_shell = _this select 0;
_color = getArray (configFile >> "CfgAmmo" >> (typeOf _shell) >> "lightColor");
_brightness = ((_color select 0) + (_color select 1) + (_color select 2))/6;
/*
hint format ["_shell = %1\n\n_brightness = %2\n\nsoundFly = %3\n\nlightColor = %4\n\ntimeToLive = %5",
	typeOf _shell,
	_brightness,
	getArray (configFile >> "CfgAmmo" >> (typeOf _shell) >> "soundFly"),
	getArray (configFile >> "CfgAmmo" >> (typeOf _shell) >> "lightColor"),
	getNumber (configFile >> "CfgAmmo" >> (typeOf _shell) >> "timeToLive")
];
*/
_to_delete = [];
_sm = "#particlesource" createVehicleLocal getPos (_shell);
_sm setParticleRandom [0.5, [0, 0, 0], [0, 0, 0], 0, 0.3, [0, 0, 0, 0], 0, 0, 360];
_sm setParticleParams [["\ca\Data\ParticleEffects\Universal\Universal", 16, 12, 8,0],
	"", "Billboard", 1, 30, [0, 0, 0],
	[0,0,0], 1, 1, 0.80, 0.5, [1.3,4],
	[[0.9,0.9,0.9,0.6], [1,1,1,0.3], [1,1,1,0]],[1],0.1,0.1,"","",_shell];	
_sm setDropInterval 0.02;
_sp = "#particlesource" createVehicleLocal getPos (_shell);
_sp setParticleRandom [0.03, [0, 0, 0], [0, 0, 0], 0, 0.2, [0, 0, 0, 0], 0, 0, 360];
_sp setParticleParams [["\ca\Data\ParticleEffects\Universal\Universal", 16, 13, 2,0],
	"", "Billboard", 1, 0.1, [0, 0, 0],
	[0,0,0], 1, 1, 0.80, 0.5, [1.5,0],
	[[1,1,1,-4], [1,1,1,-4], [1,1,1,-2],[1,1,1,0]],[1000],0.1,0.1,"","",_shell,360];	
_sp setDropInterval 0.001;
_li = "#lightpoint" createVehicleLocal getPos (_shell);
_li setLightBrightness _brightness;
_li setLightAmbient[(_color select 0)/2, (_color select 1)/2, (_color select 2)/2];
_li setLightColor[(_color select 0)/4, (_color select 1)/4, (_color select 2)/4];
_li lightAttachObject [_shell, [0,0,0]];
_to_delete = _to_delete + [_sm, _sp, _li];
_delay = getNumber (configFile >> "CfgAmmo" >> (typeOf _shell) >> "timeToLive");
[_delay, _to_delete] spawn {
	sleep (_this select 0);
	{deleteVehicle _x} forEach (_this select 1);
};
};

Edit: Btw, if you need a good soundFly for illumination, check out the sound ECS uses for Arma1. Sounds "pretty good" although I have no idea how they really sounds like in real life.

Here is the "addon" (really, I have not much idea what I'm doing here), containing illumination shells for 60, 81, 105, and 155mm bore, 81 and 105 replacing existing classes, but without updating HOB (done for Magazines which I don't touch). Colors will decrease in "yellowness" with decreasing candle power, but never reach "white". SoundFly may be a bit on the high side though...

//Some data, TTL = Time To Live, ROD = Rate Of Descent, HOB = Height of Burst:
//Wpn     Round                Candle Power  TTL    ROD     HOB
//40mm M203    White Cluster       90000 CP    7 s                       x number in cluster?, 7 seconds.
//40mm M203    White Parachute     90000 CP   40 s
//40mm M203    Green Parachute      8000 CP   40 s
//40mm M203    Red Parachute       20000 CP   40 s
//60mm Mortar  M83A3 round        250000 CP   32 s  10 fps  350 m?       USED
//60mm Mortar  M767 round         300000 CP   55 s   ? fps  425 m
//81mm Mortar  M301A2 round       500000 CP   60 s  18 fps  600 m        USED
//81mm Mortar  M853A1 round       525000 CP   50 s   ? fps  475 m
//81mm Mortar  M853 round (alt)   600000 CP   60 s   ? fps    ? m
//105mm Arty   M314A3 round                   70 s   ? fps  600 m        USED
//107mm Mortar M335A2 round       850000 CP   90 s 
//155mm Arty   M485A2 round      1000000 CP  120 s   5 mps  800 m?       USED   (M198 Howitzer)
//Default rate of descent, by measuring velocity, is 7m/s, or 23 feet per second.
//Rate of descent should thus be controlled via the wind simulator.

class CfgPatches
{
class ArtyFlares
{
	units[] = {};
	weapons[] = {};
	requiredVersion = 1.040000;
	requiredAddons[] =
	{
		"CAWeapons","CA_Modules_ARTY"
	};
};
};

class CfgAmmo 
{
class FlareBase;

//Big artillery, doesn't exist in default classes. Could be used with future 155mm artillery.
class ARTY_Flare_Big: FlareBase
{
	model="\ca\Weapons\granat";
	soundFly[] = {"\ArtyFlares\sounds\105mm_Illum.ogg", 0.38, 1};
	timeToLive= 120;
	lightColor[] =
	{
		5.44,
		4.08,
		1.36,
		0
	};
};
//Small artillery, approx 100mm, will be used with vanilla arty flares.
class ARTY_Flare_Medium: FlareBase
{
	model="\ca\Weapons\granat";
	soundFly[] = {"\ArtyFlares\sounds\105mm_Illum.ogg", 0.34, 1};
	timeToLive= 70;
	lightColor[] =
	{
		4.33,
		3.31,
		1.27,
		0
	};
};
//Mortar, approx 80mm, will be used with vanilla mortar flares.
class ARTY_Flare_Small: FlareBase
{
	model="\ca\Weapons\granat";
	soundFly[] = {"\ArtyFlares\sounds\105mm_Illum.ogg", 0.30, 1};
	timeToLive= 60;
	lightColor[] =
	{
		3.22,
		2.54,
		1.18,
		0
	};
};
//Mortar, approx 60mm, doesn't exist in default classes
class ARTY_Flare_Tiny: FlareBase
{
	model="\ca\Weapons\granat";
	soundFly[] = {"\ArtyFlares\sounds\105mm_Illum.ogg", 0.26, 1};
	timeToLive= 32;
	lightColor[] =
	{
		2.11,
		1.77,
		1.09,
		0
	};
};
};

Edited by CarlGustaffa

Share this post


Link to post
Share on other sites

Yeah 4 is probably too much. Was just a test. It`s up to the mission maker to choose how many he wishes to fire up there hehe.

By the way, the biki states that the maximum value for RGB colors is 1:

Color

So i am not sure if shooting above 1 really makes things brighter.

What is missing is access to the actual brightness value in the config and this is what the candle power actually correlates too.

Just setting the color will still have the light spread for the same distance even if its a very dark color, but that`s probably the only choice.

And Arma2´s light engine (except for sunlight) isn´t much better than

in OFP. So a huge area is lit by these flares with an ambient light type, regardless if you stand in a house or behind a hill, which is lame.

I will adjust the burn times for 105mm, 81-ish mm and 60 mm

accordingly.

The HOB for the 60 mm rounds is pretty much determined by the maximum

flight altitude of the round, which isn`t that high but around 350 meters.

I have implemented many new rounds and made the ERGM now compatible with vilas M109 addon, so that it can engage targets 35 km away.

Is there any ingame benefit of IR illum rounds?

The NVS (simulation) of the game displays everything too well, that i don`t think that an IR illum round could be that majorly beneficial.

Share this post


Link to post
Share on other sites

Is there any ingame benefit of IR illum rounds?

The NVS (simulation) of the game displays everything too well, that i don`t think that an IR illum round could be that majorly beneficial.

Not being able to see stuff lit up with out NVG. But eitherway its pointless. :p

Share this post


Link to post
Share on other sites

I think the wiki is wrong. I just tested [1,1,1,0] and [50,50,50,0] as light values, without using #lightsource trick, and the change was extreme - as expected.

With the extreme brightness, what happens is that at 1500m or so, you have a "magic cutoff point" where the brightness suddenly stops affecting anything at all. Move one meter, and go from very high illumination to zero illumination from the flare. Means there is a hardcoded limit.

With NVGs, we see everything too good with no resolution restrictions, although bad ambient lighting (i.e. no moon) can make them pretty bad. IR illumination has little use at this point, due to NVGs being far too powerful. I'd still want it however, as ACE2 is discussing if we should make NVGs unavailable while in most sights, but now regular illumination is better for infantry. With OA coming, we might get proper lasers, and that makes IR Illumination very valuable (combined with no NVG sights). However, flyboys and vehicle operators can still benefit from IR illumination for vehicle based NVGs. It can also be used in assymetric TvT. One side uses IR for better light conditions, while the other side uses visible illumination to blind their enemies NVGs :)

If all this is implemented by i.e. ACE, at least there will be proper projectiles available to use for scripted artillery. If I can combine a decent way of ordering artillery with good projectiles, it would be a dream come true for me. Manning guns is of course fun, but may not suit the smaller squads well.

Share this post


Link to post
Share on other sites

Yea Carl. I at least definitely see the work done with player artillery as a compliment to what Charon is doing for the AI. :) When ACE gets into field artillery, beyond the mortars we are looking at in the immediate future I will be sure that we are on the same page. :D

Share this post


Link to post
Share on other sites

Charon,

Are you intending to do any more work on this, it seemed to have so much potential ?

Share this post


Link to post
Share on other sites
Charon,

Are you intending to do any more work on this, it seemed to have so much potential ?

I need TESTERS !

Can´t debug such a complex thing otherwise effectively.

So anyone seriously interested please PM me.

Share this post


Link to post
Share on other sites

Wow, that's incredible! That's an amazing effect! This is the kind of arty we need to see ingame when we ask for it, haha! None of that one shot in one shot over crap. The illumination of the light shells are great too!

It adds a kind of ominous glow to the enemy before their death.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×