Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
DOEL

A 1 in 5,000,000 occurrence

Recommended Posts

22 minutes ago, Edward850 said:

Death is absolute so two players firing at the same frame at each other with a shot that would guarantee death will mean the lower player number will get the kill

That's pretty interesting. With a framerate of 35 FPS this is definitely a thing that would happen sometimes. Do you know offhand if it's the same in MP-oriented ports like Zandronum? (Don't worry about looking it up if you don't want to, heh.)

 

@idbeholdME it's because by default ZDoom uses a different way to calculate the radius of things, so that you can punch large enemies like the Mancubus easier. The side effects are that big monsters, especially the SMM, can absorb a lot more BFG tracers from all angles, and also you can punch things from like 12 feet away with your giant gorilla arms.

Share this post


Link to post

@plums

I thought that it is easier because the RNG values are different in ZDoom but it's just because all the tracers hit?

 

So in Vanilla, some tracers may miss even if you facehug the Spider Mastermind? I meant literally walking up to him and meleeing him with the BFG.

 

I am aware of the blockmap bug and that Zdoom fixes it, but I feel like even if everything hits in both Zdoom and Vanilla, it is still more likely to die in one shot in Zdoom.

Edited by idbeholdME

Share this post


Link to post

I think I've done this recently. I was playing Ancient Aliens on Zandronum 3.0 and was fighting a revenant. I blasted it point-blank with the SSG and it went down in that one shot. That was the only time it ever happened to me as revenants had never gone down in one shot before or since. I'm not entirely sure if I did actually do this though because it is very possible that the revenant might have taken damage somehow without me noticing. Though I did see it go down in one SSG blast.

Share this post


Link to post
10 minutes ago, idbeholdME said:

I thought that it is easier because the RNG values are different in ZDoom but it's just because all the tracers hit?

TBH I'm not 100% sure, I would have thought that with that much averaging from all the tracer attacks the RNG wouldn't make much difference, but I could well be wrong.

 

You can turn on "Use Doom code for hitscan checks" in ZDoom which affects both the blockmap bug and radius calculation of things. From a very quick test, the SMM seems less likely to die in 1 hit with this compatibility option on.

Share this post


Link to post
27 minutes ago, plums said:

That's pretty interesting. With a framerate of 35 FPS this is definitely a thing that would happen sometimes. Do you know offhand if it's the same in MP-oriented ports like Zandronum? (Don't worry about looking it up if you don't want to, heh.)

Zandronum and Odamex still have this behaviour, yes. Zdaemon presumably does as well but good luck finding out. As far as I know it also doesn't come up a lot in competitive discussions.

Share this post


Link to post

https://doomwiki.org/wiki/Pseudorandom_number_generator

 

Looking at Doom's RNG has picked up my interest in designing the most random 16x16 table WITH ALL 0-255 VALUES PRESENT.

How I would design it in C#:

 

1. Call upon RNGCryptoServiceProvider for a seed.

 

2. From that seed, iteratively create N hashes.

(Preferably with a well-known, battle-tested hash, like SHA2) 

 

3. For each hash, derive an 8-bit table using with the Fischer-Yates shuffle algorithm, to ensure all 0-255 values are present.

(Fischer-Yates is basically drawing numbers out of a hat)

 

4. Design a battery of testing for randomness, like https://en.wikipedia.org/wiki/Diehard_tests... and run the 8-bit tables through them.

 

5. Assign ranked-based scores for each table, based on how they perform in the battery tests.

 

6. Pick the best performing table.

 

iono, anything I'm missing here?

Edited by Doom Marine

Share this post


Link to post
3 hours ago, plums said:

it's because by default ZDoom uses a different way to calculate the radius of things, so that you can punch large enemies like the Mancubus easier. The side effects are that big monsters, especially the SMM, can absorb a lot more BFG tracers from all angles, and also you can punch things from like 12 feet away with your giant gorilla arms.

I don't think it matters for long-range attacks. Punching/sawing is easier in ZDoom because it factors in the monster's radius, while vanilla does not. So in vanilla you need to have the monster's center within your melee range, while in ZDoom you only need to have the monster's exterior. This range issue, however, is basically irrelevant when using guns.

Share this post


Link to post

Obligatory link to my (oldie, but always valid) Shotgun and Super-Shotgun anal-ysis.

 

In essence, doing a 1-shot SSG kill vs a Revenant is impossible in Vanilla without manipulating the RNG. And no, not in the way TASers do it (picking the appropriate moment to fire), I mean actually hacking the RNG table to give all of your 20 pellets maximum damage (15 HP) all the time. In Vanilla there's no legal traversal of the RNG table that would yield such a result. In source ports with their own RNG logic...maybe.

 

Perhaps it's interesting to see what you can (and cannot) kill, guaranteed, with 2, 3, 4 or even 5 shots.

 

https://www.doomworld.com/forum/post/882318

 

E.g. did you know that it's possible to stumble upon a "tough SOB" Baron that won't go down even with 5 SSG shots to the face, no misses?

Edited by Maes

Share this post


Link to post
38 minutes ago, Gez said:

I don't think it matters for long-range attacks. Punching/sawing is easier in ZDoom because it factors in the monster's radius, while vanilla does not. So in vanilla you need to have the monster's center within your melee range, while in ZDoom you only need to have the monster's exterior. This range issue, however, is basically irrelevant when using guns.

That is what I was thinking too. ZDoom just made it so you have to hit the radius, not the center, which makes much more sense and prevents the inconsistent behavior with hitscan attacks suddenly missing. But even gun hitscans could miss if the attack did not pass through the block where the center of the monster is located (happens when an enemy sprite passes through multiple blocks). So the bigger the monster, the higher the probability of that happening.

 

The RNG behavior is 100% changed in (G)Zdoom. I think it was something along the lines of fixing the original faulty table of values and also making it so every action which uses the random values from the table has separate ones. Meaning that the random calls for things like monster movement or Doomguy's eyes moving do not progress the table for things like weapon damage or monster damage. You can check this by making a save in Zdoom and getting hit by a Revenant for, say, 24 damage. Then, every time you load the game, he will always hit you for 24 no matter what because Revenants have their own RNG table which does not progress by anything else than a Revenant dealing damage.

 

I am recalling all this from memory when I was looking into this few years ago. Something along the lines of the changed RNG values resulting in a more even random distribution which I think led to BFG doing slightly more damage on average when all the tracers hit compared to vanilla. I am not 100% sure about this but it at least feels that SMM dies more often from one full hit in ZDoom.

Share this post


Link to post

ZDoom supports arbitrarily many random indices, but it's not used by Doom monsters (it is used for sure in Heretic, maybe in Hexen, possibly Strife, I don't feel like checking at the moment). Revenants AFAIR use the same RNG as other monsters and guns. The UI stuff uses a separate RNG, but that's also the case in vanilla (P_Random vs. M_Random).

Share this post


Link to post

I am pretty sure that is not the case in ZDoom. I remember specifically testing this and no matter how many things I did or how long I waited in an attempt to progress the table changed the damage I received from the hit. The only thing that seemed to work was closing the game completely and starting it again.

 

Even things like Shotgun Guy's spread for the 3 pellets always occur the same. He will always shoot with the same accuracy after you load a game. So if he sniped you from 50 meters for 45 damage, he will do it every single time after you load the game.

Share this post


Link to post
On 6/24/2020 at 5:34 PM, DOEL said:

I was reading some interesting info on this website (http://www.doom2.net/single/weaponfaq.html) and it mentions that killing a revenant with 1 SSG blast is a 1 in 5,000,000 occurrence.

 

I was wondering if anyone has seen this before and if there are any demos or recordings where this happens. I didn't even know this was theoretically possible.

 

On 6/24/2020 at 5:40 PM, SaladBadger said:

There's some immediate problems with that page, like it implying the SSG fires 21 pellets, it only fires 20. To one-shot a revenant would require every single pellet to roll max damage, since the revenant has 300 hp and the SSG caps out at 300 damage. Rolling the same 1/3 chance 20 times is improbable, but not strictly impossible.

 

But wait! Vanilla's simple RNG means you physically cannot roll max damage on every pellet. I'm not sure what the physical max is at the moment, since the wiki has had some problems with the damage calcs before and I'm not sure they've been corrected yet. So ultimately, in most ports people are running and doing demos with, it cannot happen at all. It's maybe possible on ZDoom with its new RNG, but I would be surprised if the entire random stream has a sequence that would enable it.

 

Let's ignore the fact that RNG negates the ability to roll a max on the 20 x 5d3 damage. Let's suppose you could manage to get 300 damage (the theoretical limit) and you happened to unload all that damage on that poor, unsuspecting revenant. The probability for that works out to be closer to 1 in 5 billion instead of 1 in 5 million.

 

Actually, in a perfect RNG world, the odds of killing a revenant with 1 SSG blast are almost exactly 1 in 3.48679 billion.

Share this post


Link to post
55 minutes ago, Pegleg said:

Actually, in a perfect RNG world, the odds of killing a revenant with 1 SSG blast are almost exactly 1 in 3.48679 billion.

 

Yes, and in Boom non-demo mode I believe this is the actual probability of this event.

 

To put that in perspective, that's roughly the odds of flipping heads on a coin 32 times in a row.

 

Or a little worse odds than getting the exact number right on a roulette wheel 6 times in a row.

 

Now with all the games played and shots taken in Boom, it may have happened. But in all likelihood the player was aiming elsewhere...

Share this post


Link to post
On 6/24/2020 at 11:21 PM, GarrettChan said:

I did this before, and I used up another 2 for angle and stuff. Then I think Ling said probably the blood splat will eat another one, so right now I'm still not sure.

 

IIRC this is a complete list if you want to check.

 

On 6/25/2020 at 4:14 AM, Maes said:

Obligatory link to my (oldie, but always valid) Shotgun and Super-Shotgun anal-ysis.

 

uhhh

 

"I let the RNG run freely in the mean". So when you say always valid, you mean valid for any huge modern map with enough actors to scramble the index continually? No doubt many players would agree this is the entire universe :> and absolutely it should be the next column added to the wiki's tables, since the calculation is equally streamlined to the "move through the table appropriately" case.

 

On 6/24/2020 at 6:39 PM, GarrettChan said:

I think most of the time you can't even do 128 splash damage since the explosion center will be a little bit in front of the Pinky? Just like if you got hit by a Cyber, if you subtract the multiples of 20, usually it's not 128, or at least the last digit won't be correct or something like that.

 

At one point a project began to at least upgrade my appalling mess. Hopefully it also includes corrections like this. But competent programmers have many interests, so who knows when data might appear.

 

IMO the next leap forward is a stochastic survey of archived vanilla maps by era, so neither Maes nor anyone else has to keep flogging simplifying assumptions (because the sample of all vanilla sessions anywhere ever is so large that "rare" cases in fact arise regularly and smear the conclusion, as seen in the links upthread). At each possible player location, project the time distribution of P_Random() calls by monsters, blinking lights, etc. Use that to infer a central tendency and moments for how far the index advances between player attacks. Then average those over each map weighted by the number of revenants available. To go above and beyond, profile LMPs as well, so the typical number of missed pellets by range need not be assumed either.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×