You absolutely cannot 1 shot a lerk with carapace.
Lerk with carapace has 125hp and 75 ap. That's an effective health of 275 versus normal damage (shotgun and lmg). A w0 shotgun shot does 17x10=170 damage. A w3 shotgun does 22.1x10=221 damage.
The lerk would have 54 hp remaining even if you hit all 10 pellets, which I think is highly unlikely if not outright impossible in a real game.
You know in real life you can change the spread of your shotgun. I have a full choke on my 12guage for the most tight spread possible. Would be neat (Although I don't know how it would be useful?) if you could change the choke in game. But of course, I would expect a combat shotgun to have a full choke. (small chokes are used in bird hunts and other faster moving targets.)
In terms of fixed spread, I recall in NS1 when the spread was fixed people made crosshairs that were the exact spread (I had them at one point to learn the spread) and you could simply kill any skulk. It was a bit ridiculous I suppose.
<!--quoteo(post=1958439:date=Aug 6 2012, 08:41 PM:name=Death_by_bullets)--><div class='quotetop'>QUOTE (Death_by_bullets @ Aug 6 2012, 08:41 PM) <a href="index.php?act=findpost&pid=1958439"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->You know in real life you can change the spread of your shotgun. I have a full choke on my 12guage for the most tight spread possible. Would be neat (Although I don't know how it would be useful?) if you could change the choke in game. But of course, I would expect a combat shotgun to have a full choke. (small chokes are used in bird hunts and other faster moving targets.)<!--QuoteEnd--></div><!--QuoteEEnd-->
Personally that might add in too much weirdness. Plausible idea is regular blase on primary, focused shot in secondary, or using secondary to switch the choke settings, but I feel that's adding in a little too much.
eh? and GORGEous have the right of it. No one should expect one-shot Lerks with shotties. However, 2-shotting Lerks is plausible assuming they're close and you can get the spread on them. Similarly, unarmored Skulks should die to competent shotgunners, especially once W1 or W2 roll around, but with the lag jumps at close range I have a hard time even accomplishing that (and I'm pretty sure they almost all have Carapace, the jerks).
<!--quoteo(post=1958204:date=Aug 6 2012, 12:07 PM:name=fanatic)--><div class='quotetop'>QUOTE (fanatic @ Aug 6 2012, 12:07 PM) <a href="index.php?act=findpost&pid=1958204"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->but I know that hitting skulks, lerks and fades with the machine gun is significantly more difficult than it was in NS1.<!--QuoteEnd--></div><!--QuoteEEnd-->
It very much is, which is ironic because the skulks in NS1 were like half the size of the NS2 incarnations. I want to say it's the wonky movement system, and the poor transition animations (wall jumping makes the model wig out), and the lag compensation (ever seen those low fps/high ping teleporting aliens?) but honestly it's difficult to put a finger on exactly why they seem so hard to track/hit when compared to the littler NS1 buggers. Maybe just the atmosphere of the game, even (grey skulks+ grey walls).
<!--quoteo(post=1958433:date=Aug 7 2012, 02:18 PM:name=GORGEous)--><div class='quotetop'>QUOTE (GORGEous @ Aug 7 2012, 02:18 PM) <a href="index.php?act=findpost&pid=1958433"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->You absolutely cannot 1 shot a lerk with carapace.
Lerk with carapace has 125hp and 75 ap. That's an effective health of 275 versus normal damage (shotgun and lmg). A w0 shotgun shot does 17x10=170 damage. A w3 shotgun does 22.1x10=221 damage.
The lerk would have 54 hp remaining even if you hit all 10 pellets, which I think is highly unlikely if not outright impossible in a real game.<!--QuoteEnd--></div><!--QuoteEEnd-->
Then I must have been bloody unlucky then I guess and some stray bullet must have hit me too, as I have died what from my client side showed up as nothing more than a shotgun...oh well.
SG is fine, I still stand by that point. I can hit thing with it when I am marine and get 1 shotted plenty as either lerk of skulk.
This may be overly ambitious but... Is there an elegant way to do the calculation for a continous distribution instead of individual pellets?
You would be simulating the effect of an infinite number of pellets with some spread(gaussian?), effectively averaging out all randomness. The actual calculation would be an integration of a pellet density function over the exposed, projected hitbox area of the target.
You could probably implement this numerically on a GPU using similar methods as shadowmapping. You would render(z-only) bullet-blocking geometry(including hit-boxes) within the max range of the shotgun from the perspective of where the "pellets" originate(a narrow frustum), in a low resolution like 128x128. For each eligible target in the frustum, render a 128x128 float image of its hitboxes, using depth culling against the "shadowmap" you just rendered, with a pixelshader that sets the intensity of each rendered pixel as a gaussian function of its distance from the center. Then downsample(same as generating mipmaps on the GPU without any kind of post-processing, like a sharpening filter). The "colour" of that 1 pixel, after normalization, represents the fraction of the "pellets" that hit the player.
Too many draw calls? The cone is pretty narrow, so there shouldn't be a crazy amount of objects rendered, and you only render the scene ones; when the z-pass is done you're only rendering and downsampling one set of hitboxes at a time.
There are some straight forward optimizations. If you calculate the max Z value of your "shadowbuffer", you don't have to test any object whose bounding box is farther away than that Z-value because not even a single pixel would be rendered anyway, even if they are in the frustum.
Caveats: The server needs to render graphics, which means it needs a graphics card and a correctly functioning graphics driver. Some kind of integrated POS might be problematic. Linux servers might be a problem, as now you need to use open GL.
The NS shotgun had a tight central distribution of (5?) pellets and a number of pellets(7?) in a wide spread; this made the shotgun not completely terrible at longer distances.
If you're going to have a distribution with only ten pellets. I'd like to see one pellet dead center, with 3 or so pellets in a fairly tight symmetric distribution around it and the rest of the pellets farther out in a more random arrangement. Like so:
Another key problem is that there is poor visual feedback. Blood splats in half-life were very obvious, you saw instantly where every pellet or bullet hit; so it didn't feel so bulletspongy, even if those bloodsplats were predicted client-side and may not represent actual hits.
<!--quoteo(post=1958509:date=Aug 7 2012, 02:57 AM:name=Soylent_green)--><div class='quotetop'>QUOTE (Soylent_green @ Aug 7 2012, 02:57 AM) <a href="index.php?act=findpost&pid=1958509"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->The NS shotgun had a tight central distribution of (5?) pellets and a number of pellets(7?) in a wide spread; this made the shotgun not completely terrible at longer distances.
If you're going to have a distribution with only ten pellets. I'd like to see one pellet dead center, with 3 or so pellets in a fairly tight symmetric distribution around it and the rest of the pellets farther out in a more random arrangement. Like so:
Another key problem is that there is poor visual feedback. Blood splats in half-life were very obvious, you saw instantly where every pellet or bullet hit; so it didn't feel so bulletspongy, even if those bloodsplats were predicted client-side and may not represent actual hits.<!--QuoteEnd--></div><!--QuoteEEnd-->
I came up with some decent looking spreads using some matlab code I wrote up.
Criteria I used was: 9 random points within unity circle, 10th point added to make the average at 0,0. 50% of points must be within inner 50% of circle, only 2 or 3 points allowed in each quadrant of circle. I can post some examples when I get home tonight if there is any interest.
fanaticThis post has been edited.Join Date: 2003-07-23Member: 18377Members, Constellation, Squad Five Blue
<!--quoteo(post=1958509:date=Aug 7 2012, 11:57 AM:name=Soylent_green)--><div class='quotetop'>QUOTE (Soylent_green @ Aug 7 2012, 11:57 AM) <a href="index.php?act=findpost&pid=1958509"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Another key problem is that there is poor visual feedback. Blood splats in half-life were very obvious, you saw instantly where every pellet or bullet hit; so it didn't feel so bulletspongy, even if those bloodsplats were predicted client-side and may not represent actual hits.<!--QuoteEnd--></div><!--QuoteEEnd--> The NS1 bloodsplats were serverside actually, that's what made them so great for player hit feedback.
<!--quoteo(post=1958536:date=Aug 7 2012, 02:47 PM:name=Ryne)--><div class='quotetop'>QUOTE (Ryne @ Aug 7 2012, 02:47 PM) <a href="index.php?act=findpost&pid=1958536"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->I came up with some decent looking spreads using some matlab code I wrote up.
Criteria I used was: 9 random points within unity circle, 10th point added to make the average at 0,0. 50% of points must be within inner 50% of circle, only 2 or 3 points allowed in each quadrant of circle. I can post some examples when I get home tonight if there is any interest.
I believe eh has done something similar.<!--QuoteEnd--></div><!--QuoteEEnd--> Lots of interest, and post the code also! :)
<!--quoteo(post=1958536:date=Aug 7 2012, 07:47 AM:name=Ryne)--><div class='quotetop'>QUOTE (Ryne @ Aug 7 2012, 07:47 AM) <a href="index.php?act=findpost&pid=1958536"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->I came up with some decent looking spreads using some matlab code I wrote up.
Criteria I used was: 9 random points within unity circle, 10th point added to make the average at 0,0. 50% of points must be within inner 50% of circle, only 2 or 3 points allowed in each quadrant of circle. I can post some examples when I get home tonight if there is any interest.<!--QuoteEnd--></div><!--QuoteEEnd-->
In a uniform distribution points tend to cluster too much. This is bad, because you only have 10 pellets to play with. You can counter-act this with rejection sampling; if a point ends up too close to any other point you reject it and try again.
Adding the 10th point to bring the mean to 0,0 will mean that the 10th point is not uniformly distributed(but it will end up near the center). You could just subtract the mean from each point instead.
With a few pellets in a central cluster you can have a shotgun that isn't overpowered at range, yet remains somewhat usable at range. With a uniform distribution I don't think there is any middle ground between a shotgun that is essentially a melee weapon at wider spreads or overpowered at range.
Realistic shotgun pellet distributions are gaussian(but have many pellets and much tighter spread than NS!).
I like my(mostly deterministic) lower right best. Gaussian and uniform doesn't work well with so few points(distribution of point looks very different each try and they often cluster points toghether)
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->n = 10; % number of points to pick.
% Uniform distribution on disc, ofset to center on 0,0. selectsub(1) u0 = rand(1,n); u1 = 2*pi*rand(1,n); x = sqrt(u0).*sin(2*pi*u1); y = sqrt(u0).*cos(2*pi*u1); x = x - mean(x); y = y - mean(y); plot(x,y,'.') plot(sin(2*pi*[0:1024]/1024), cos(2*pi*[0:1024]/1024), 'r-'); title('uniform on disk, mean 0,0')
% Uniform distribution with rejection sampling for nearby points. eps = 2/n; % Rejection criteria needs to be smaller for large n. selectsub(2) for i = 1:n reject = 1; while reject == 1 reject = 0;
% pick point on disc. u0 = rand(1,1); u1 = 2*pi*rand(1,1); x(i) = sqrt(u0).*sin(2*pi*u1); y(i) = sqrt(u0).*cos(2*pi*u1);
%rejection for j = 1:i-1 if ( ((x(i)-x(j))).^2 + ((y(i)-y(j))).^2 < eps ) reject = 1; end; end; end end; title('uniform on disk, close points rejected')
% Gaussian ofset to center on 0,0 selectsub(3) x = random( 'normal', 0, 0.5, 1, n); y = random( 'normal', 0, 0.5, 1, n); x = x - mean(x); y = y - mean(y);
<!--quoteo(post=1958506:date=Aug 7 2012, 06:38 AM:name=Soylent_green)--><div class='quotetop'>QUOTE (Soylent_green @ Aug 7 2012, 06:38 AM) <a href="index.php?act=findpost&pid=1958506"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->continuous/Gaussian distribution instead of individual pellets?<!--QuoteEnd--></div><!--QuoteEEnd-->
This is the best solution but unfortunately would require a major overhaul of the way the shotgun works in code which is guaranteed not to make it for launch. someone <i>might</i> be able to derive a solution from the way grenade explosions or the flamethrower works, but i haven't looked at how hits and damage dropoff are calculated for them.
<!--quoteo(post=1958675:date=Aug 7 2012, 02:17 PM:name=ironhorse)--><div class='quotetop'>QUOTE (ironhorse @ Aug 7 2012, 02:17 PM) <a href="index.php?act=findpost&pid=1958675"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Yuuki struck gold, well done to both you and rant<!--QuoteEnd--></div><!--QuoteEEnd-->
eh? deserves most of the credit, I just made a derp post and a crappy youtube video
<!--quoteo(post=1958689:date=Aug 7 2012, 02:00 PM:name=spellman23)--><div class='quotetop'>QUOTE (spellman23 @ Aug 7 2012, 02:00 PM) <a href="index.php?act=findpost&pid=1958689"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Pic isn't loading for me for some reason in IE. Haven't tried other stuff yet.<!--QuoteEnd--></div><!--QuoteEEnd-->
Here is a link to his pic, seems "postimage" was preventing his hotlink
I reuploaded it to imgur (let me know if this isnt cool) <b>(again this Soylent_Greens picture, not mine)</b> <img src="http://i.imgur.com/PCi8E.png" border="0" class="linked-image" />
The ns2 shotgun fires slower and is a lot more random when coming to getting kills with it than ns1. The pellets need to be evenly spaced from eachother in a semi random array. otherwise you will get direct shots where most of the pellets are hitting some random corner and you only hit 3 pellets. That is so stupid in a game that requires high consistency... cause having good consistency no longer matters when you have shots ranomely missing that were spot on.
Here is an example I came up with....again my code is written to make lots of examples and "pick and choose" decent ones visually
PINK = current shotgun RED = an example of my distribution The scale on it is just matching UWE's "max radius" for their distribution....I scaled mine from a unity circle to that.
So far my biggest "wish" would be to increase the amount of pellets while maintaining the same overall damage....this might or might not be a performance hit though.
Factors I could change in my code that would affect distribution: 1) Quadrant restriction (>=2, <=4) 2) 50% of pellets within 50% of inner area....could up or down pellet count , and up or down area requirement 3) add a "closeness" check like Soylent has
The code was a quick hackjob, I am not a comp sci major nor do I write code cleanly.... It is written for "Scilab", a free open source alternative tro MATLAB....should run on MATLAB with minimal changes (comment indicator different, and some of the boolean stuff) <a href="http://pastebin.com/0bLFCubU" target="_blank">http://pastebin.com/0bLFCubU</a>
<!--quoteo(post=1958700:date=Aug 7 2012, 02:55 PM:name=.ADHd)--><div class='quotetop'>QUOTE (.ADHd @ Aug 7 2012, 02:55 PM) <a href="index.php?act=findpost&pid=1958700"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->The ns2 shotgun fires slower and is a lot more random when coming to getting kills with it than ns1. The pellets need to be evenly spaced from eachother in a semi random array. otherwise you will get direct shots where most of the pellets are hitting some random corner and you only hit 3 pellets. That is so stupid in a game that requires high consistency... cause having good consistency no longer matters when you have shots ranomely missing that were spot on.<!--QuoteEnd--></div><!--QuoteEEnd-->
Right on the slower shots. However, I seem to recall you were guaranteed 5 would be in a narrow cone and the other 5 in a larger cone providing a surefire 50% of the damage if you locked the smaller cone on an enemy. So one shotgun blast to shave some HP and a 2nd cleanly getting the smaller cone was a surefire way to kill Skulks.
Or have Weapons 1/2, they have no Carapace, and shotgun-to-the-face all 10 pellets at melee range. Good times.
PS, Thanks Ryne for reposting Soylent's pic. That works wonderfully for me.
ScardyBobScardyBobJoin Date: 2009-11-25Member: 69528Forum Admins, Forum Moderators, NS2 Playtester, Squad Five Blue, Reinforced - Shadow, WC 2013 - Shadow
Oh, I really like the 3 + 7 distribution from Soylent's algorithm. Though, I've always thought that 10 pellets were always a bit low for the shotgun. I wouldn't mind seeing the same '3 + 7' distribution but for something like 20 or 25 pellets (so you don't get as much empty space).
<!--quoteo(post=1958786:date=Aug 7 2012, 05:20 PM:name=ScardyBob)--><div class='quotetop'>QUOTE (ScardyBob @ Aug 7 2012, 05:20 PM) <a href="index.php?act=findpost&pid=1958786"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Oh, I really like the 3 + 7 distribution from Soylent's algorithm. Though, I've always thought that 10 pellets were always a bit low for the shotgun. I wouldn't mind seeing the same '3 + 7' distribution but for something like 20 or 25 pellets (so you don't get as much empty space).<!--QuoteEnd--></div><!--QuoteEEnd-->
I liked it at first, but even with rotation it would be a VERY predictable spread.
You have to keep in mind that they have a random rotation added to these spreads
Yeah the 3+7 is not good IMO. You basically have damage in the center and then a ring of damage at the outside. So the damage is going to almost always be either 3 pellets or 10 (always get 3 if you aim right, but unless you're point blank all of the others will miss), rarely anything in between. Ryne's I like. There's pellets at many different distances, so your damage will gradually increase as your aim improves or distance decreases.
i'm a little uncomfortable with raising the pellet count because that would nerf shotties vs oni by a large amount. if we had 20 pellets instead of 10, the shotty would be worse point blank vs an onos than the LMG.
<!--quoteo(post=1958800:date=Aug 7 2012, 05:35 PM:name=Wheeee)--><div class='quotetop'>QUOTE (Wheeee @ Aug 7 2012, 05:35 PM) <a href="index.php?act=findpost&pid=1958800"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->i'm a little uncomfortable with raising the pellet count because that would nerf shotties vs oni by a large amount. if we had 20 pellets instead of 10, the shotty would be worse point blank vs an onos than the LMG.<!--QuoteEnd--></div><!--QuoteEEnd-->
Explain? If there are 20 pellets and you aim well, and they are distributed well, you should get just as many hits percentage wise
<!--quoteo(post=1958803:date=Aug 7 2012, 09:47 PM:name=Ryne)--><div class='quotetop'>QUOTE (Ryne @ Aug 7 2012, 09:47 PM) <a href="index.php?act=findpost&pid=1958803"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->Explain? If there are 20 pellets and you aim well, and they are distributed well, you should get just as many hits percentage wise<!--QuoteEnd--></div><!--QuoteEEnd-->
20 pellets with the same damage total means that each pellet does less damage. onos has hide armor of 5 which takes 5 damage off the top for each hit.
<!--quoteo(post=1958805:date=Aug 7 2012, 06:50 PM:name=Wheeee)--><div class='quotetop'>QUOTE (Wheeee @ Aug 7 2012, 06:50 PM) <a href="index.php?act=findpost&pid=1958805"><{POST_SNAPBACK}></a></div><div class='quotemain'><!--quotec-->20 pellets with the same damage total means that each pellet does less damage. onos has hide armor of 5 which takes 5 damage off the top for each hit.
10 pellets hitting @ 18 per shot = 130 damage 20 pellets hitting @ 9 per shot = 80 damage<!--QuoteEnd--></div><!--QuoteEEnd-->
Ah, didnt know the intricacies of hide armor. I still think more pellets should be added, obviously youll have to work something out with the hide armor to "continue the balance"...
Comments
Lerk with carapace has 125hp and 75 ap. That's an effective health of 275 versus normal damage (shotgun and lmg). A w0 shotgun shot does 17x10=170 damage. A w3 shotgun does 22.1x10=221 damage.
The lerk would have 54 hp remaining even if you hit all 10 pellets, which I think is highly unlikely if not outright impossible in a real game.
I also have to agree with Fana. Most of the weapon issues I have are with the rifle (and to a lesser extend GL and FT) than the sg.
In terms of fixed spread, I recall in NS1 when the spread was fixed people made crosshairs that were the exact spread (I had them at one point to learn the spread) and you could simply kill any skulk. It was a bit ridiculous I suppose.
Personally that might add in too much weirdness. Plausible idea is regular blase on primary, focused shot in secondary, or using secondary to switch the choke settings, but I feel that's adding in a little too much.
eh? and GORGEous have the right of it. No one should expect one-shot Lerks with shotties. However, 2-shotting Lerks is plausible assuming they're close and you can get the spread on them. Similarly, unarmored Skulks should die to competent shotgunners, especially once W1 or W2 roll around, but with the lag jumps at close range I have a hard time even accomplishing that (and I'm pretty sure they almost all have Carapace, the jerks).
It very much is, which is ironic because the skulks in NS1 were like half the size of the NS2 incarnations. I want to say it's the wonky movement system, and the poor transition animations (wall jumping makes the model wig out), and the lag compensation (ever seen those low fps/high ping teleporting aliens?) but honestly it's difficult to put a finger on exactly why they seem so hard to track/hit when compared to the littler NS1 buggers. Maybe just the atmosphere of the game, even (grey skulks+ grey walls).
Lerk with carapace has 125hp and 75 ap. That's an effective health of 275 versus normal damage (shotgun and lmg). A w0 shotgun shot does 17x10=170 damage. A w3 shotgun does 22.1x10=221 damage.
The lerk would have 54 hp remaining even if you hit all 10 pellets, which I think is highly unlikely if not outright impossible in a real game.<!--QuoteEnd--></div><!--QuoteEEnd-->
Then I must have been bloody unlucky then I guess and some stray bullet must have hit me too, as I have died what from my client side showed up as nothing more than a shotgun...oh well.
SG is fine, I still stand by that point. I can hit thing with it when I am marine and get 1 shotted plenty as either lerk of skulk.
You would be simulating the effect of an infinite number of pellets with some spread(gaussian?), effectively averaging out all randomness. The actual calculation would be an integration of a pellet density function over the exposed, projected hitbox area of the target.
You could probably implement this numerically on a GPU using similar methods as shadowmapping. You would render(z-only) bullet-blocking geometry(including hit-boxes) within the max range of the shotgun from the perspective of where the "pellets" originate(a narrow frustum), in a low resolution like 128x128. For each eligible target in the frustum, render a 128x128 float image of its hitboxes, using depth culling against the "shadowmap" you just rendered, with a pixelshader that sets the intensity of each rendered pixel as a gaussian function of its distance from the center. Then downsample(same as generating mipmaps on the GPU without any kind of post-processing, like a sharpening filter). The "colour" of that 1 pixel, after normalization, represents the fraction of the "pellets" that hit the player.
Too many draw calls? The cone is pretty narrow, so there shouldn't be a crazy amount of objects rendered, and you only render the scene ones; when the z-pass is done you're only rendering and downsampling one set of hitboxes at a time.
There are some straight forward optimizations. If you calculate the max Z value of your "shadowbuffer", you don't have to test any object whose bounding box is farther away than that Z-value because not even a single pixel would be rendered anyway, even if they are in the frustum.
Caveats: The server needs to render graphics, which means it needs a graphics card and a correctly functioning graphics driver. Some kind of integrated POS might be problematic. Linux servers might be a problem, as now you need to use open GL.
If you're going to have a distribution with only ten pellets. I'd like to see one pellet dead center, with 3 or so pellets in a fairly tight symmetric distribution around it and the rest of the pellets farther out in a more random arrangement. Like so:
<img src="http://s15.postimage.org/82c6b13p5/spread.png" border="0" class="linked-image" />
Another key problem is that there is poor visual feedback. Blood splats in half-life were very obvious, you saw instantly where every pellet or bullet hit; so it didn't feel so bulletspongy, even if those bloodsplats were predicted client-side and may not represent actual hits.
If you're going to have a distribution with only ten pellets. I'd like to see one pellet dead center, with 3 or so pellets in a fairly tight symmetric distribution around it and the rest of the pellets farther out in a more random arrangement. Like so:
<img src="http://s15.postimage.org/82c6b13p5/spread.png" border="0" class="linked-image" />
Another key problem is that there is poor visual feedback. Blood splats in half-life were very obvious, you saw instantly where every pellet or bullet hit; so it didn't feel so bulletspongy, even if those bloodsplats were predicted client-side and may not represent actual hits.<!--QuoteEnd--></div><!--QuoteEEnd-->
I came up with some decent looking spreads using some matlab code I wrote up.
Criteria I used was: 9 random points within unity circle, 10th point added to make the average at 0,0. 50% of points must be within inner 50% of circle, only 2 or 3 points allowed in each quadrant of circle. I can post some examples when I get home tonight if there is any interest.
I believe eh has done something similar.
The NS1 bloodsplats were serverside actually, that's what made them so great for player hit feedback.
Criteria I used was: 9 random points within unity circle, 10th point added to make the average at 0,0. 50% of points must be within inner 50% of circle, only 2 or 3 points allowed in each quadrant of circle. I can post some examples when I get home tonight if there is any interest.
I believe eh has done something similar.<!--QuoteEnd--></div><!--QuoteEEnd-->
Lots of interest, and post the code also! :)
Criteria I used was: 9 random points within unity circle, 10th point added to make the average at 0,0. 50% of points must be within inner 50% of circle, only 2 or 3 points allowed in each quadrant of circle. I can post some examples when I get home tonight if there is any interest.<!--QuoteEnd--></div><!--QuoteEEnd-->
In a uniform distribution points tend to cluster too much. This is bad, because you only have 10 pellets to play with. You can counter-act this with rejection sampling; if a point ends up too close to any other point you reject it and try again.
Adding the 10th point to bring the mean to 0,0 will mean that the 10th point is not uniformly distributed(but it will end up near the center). You could just subtract the mean from each point instead.
With a few pellets in a central cluster you can have a shotgun that isn't overpowered at range, yet remains somewhat usable at range. With a uniform distribution I don't think there is any middle ground between a shotgun that is essentially a melee weapon at wider spreads or overpowered at range.
Realistic shotgun pellet distributions are gaussian(but have many pellets and much tighter spread than NS!).
<img src="http://s11.postimage.org/eo81s9ps1/spread.png" border="0" class="linked-image" />
I like my(mostly deterministic) lower right best. Gaussian and uniform doesn't work well with so few points(distribution of point looks very different each try and they often cluster points toghether)
<!--c1--><div class='codetop'>CODE</div><div class='codemain'><!--ec1-->n = 10; % number of points to pick.
% Select subplot.
axis equal;
selectsub = @(n) eval(['subplot(2,2,n); hold on; axis ([-1,1,-1,1])']);
% Uniform distribution on disc, ofset to center on 0,0.
selectsub(1)
u0 = rand(1,n);
u1 = 2*pi*rand(1,n);
x = sqrt(u0).*sin(2*pi*u1);
y = sqrt(u0).*cos(2*pi*u1);
x = x - mean(x);
y = y - mean(y);
plot(x,y,'.')
plot(sin(2*pi*[0:1024]/1024), cos(2*pi*[0:1024]/1024), 'r-');
title('uniform on disk, mean 0,0')
% Uniform distribution with rejection sampling for nearby points.
eps = 2/n; % Rejection criteria needs to be smaller for large n.
selectsub(2)
for i = 1:n
reject = 1;
while reject == 1
reject = 0;
% pick point on disc.
u0 = rand(1,1);
u1 = 2*pi*rand(1,1);
x(i) = sqrt(u0).*sin(2*pi*u1);
y(i) = sqrt(u0).*cos(2*pi*u1);
%rejection
for j = 1:i-1
if ( ((x(i)-x(j))).^2 + ((y(i)-y(j))).^2 < eps )
reject = 1;
end;
end;
end
end;
title('uniform on disk, close points rejected')
plot(x,y,'.')
plot(sin(2*pi*[0:1024]/1024), cos(2*pi*[0:1024]/1024), 'r-');
% Gaussian ofset to center on 0,0
selectsub(3)
x = random( 'normal', 0, 0.5, 1, n);
y = random( 'normal', 0, 0.5, 1, n);
x = x - mean(x);
y = y - mean(y);
plot(x,y,'.')
plot(sin(2*pi*[0:1024]/1024), cos(2*pi*[0:1024]/1024), 'r-');
title('gaussian');
% Soylent special 1(manually picked cluster of 3 + n-3 remainder in wide distribution centered on 0,0).
selectsub(4)
plot( 0.1*sin( 2*pi*0), 0.1*cos(2*pi*0), '.');
plot( 0.1*sin( 2*pi*0.3333), 0.1*cos(2*pi*0.3333), '.');
plot( 0.1*sin( 2*pi*0.6666), 0.1*cos(2*pi*0.6666), '.');
u0 = 0.2+0.7*rand(1,n-3);
u1 = 2*pi*[1:(n-3)]/(n-2);
x = sqrt(u0).*sin( u1);
y = sqrt(u0).*cos( u1);
x = x - mean(x);
y = y - mean(y);
plot( x, y, '.');
plot(sin(2*pi*[0:1024]/1024), cos(2*pi*[0:1024]/1024), 'r-');
title('tight cluster of 3 + 7 wide semirandom');<!--c2--></div><!--ec2-->
Surprisingly the 10th point usually was not near the center. I'll post mine in a few hours.
This is the best solution but unfortunately would require a major overhaul of the way the shotgun works in code which is guaranteed not to make it for launch. someone <i>might</i> be able to derive a solution from the way grenade explosions or the flamethrower works, but i haven't looked at how hits and damage dropoff are calculated for them.
eh? deserves most of the credit, I just made a derp post and a crappy youtube video
Pic isn't loading for me for some reason in IE. Haven't tried other stuff yet.
Here is a link to his pic, seems "postimage" was preventing his hotlink
<a href="http://postimage.org/image/ja460mbb3/" target="_blank">http://postimage.org/image/ja460mbb3/</a>
I reuploaded it to imgur (let me know if this isnt cool) <b>(again this Soylent_Greens picture, not mine)</b>
<img src="http://i.imgur.com/PCi8E.png" border="0" class="linked-image" />
PINK = current shotgun
RED = an example of my distribution
The scale on it is just matching UWE's "max radius" for their distribution....I scaled mine from a unity circle to that.
<img src="http://i.imgur.com/YbA7Z.png" border="0" class="linked-image" />
So far my biggest "wish" would be to increase the amount of pellets while maintaining the same overall damage....this might or might not be a performance hit though.
Factors I could change in my code that would affect distribution:
1) Quadrant restriction (>=2, <=4)
2) 50% of pellets within 50% of inner area....could up or down pellet count , and up or down area requirement
3) add a "closeness" check like Soylent has
The code was a quick hackjob, I am not a comp sci major nor do I write code cleanly.... It is written for "Scilab", a free open source alternative tro MATLAB....should run on MATLAB with minimal changes (comment indicator different, and some of the boolean stuff)
<a href="http://pastebin.com/0bLFCubU" target="_blank">http://pastebin.com/0bLFCubU</a>
Right on the slower shots. However, I seem to recall you were guaranteed 5 would be in a narrow cone and the other 5 in a larger cone providing a surefire 50% of the damage if you locked the smaller cone on an enemy. So one shotgun blast to shave some HP and a 2nd cleanly getting the smaller cone was a surefire way to kill Skulks.
Or have Weapons 1/2, they have no Carapace, and shotgun-to-the-face all 10 pellets at melee range. Good times.
PS, Thanks Ryne for reposting Soylent's pic. That works wonderfully for me.
I liked it at first, but even with rotation it would be a VERY predictable spread.
You have to keep in mind that they have a random rotation added to these spreads
Explain? If there are 20 pellets and you aim well, and they are distributed well, you should get just as many hits percentage wise
20 pellets with the same damage total means that each pellet does less damage. onos has hide armor of 5 which takes 5 damage off the top for each hit.
10 pellets hitting @ 18 (-5) per shot = 130 damage
20 pellets hitting @ 9 (-5) per shot = 80 damage
10 pellets hitting @ 18 per shot = 130 damage
20 pellets hitting @ 9 per shot = 80 damage<!--QuoteEnd--></div><!--QuoteEEnd-->
Ah, didnt know the intricacies of hide armor. I still think more pellets should be added, obviously youll have to work something out with the hide armor to "continue the balance"...