Skip to content

Instantly share code, notes, and snippets.

@EvanEdwards
Created December 20, 2024 09:51
Show Gist options
  • Save EvanEdwards/5153063c94ff8e5937bc3445ca7b0a82 to your computer and use it in GitHub Desktop.
Save EvanEdwards/5153063c94ff8e5937bc3445ca7b0a82 to your computer and use it in GitHub Desktop.
Was Mr. Cheddar really fondue?

Was Mr. Cheddar really fondue?

To answer the run-dmg skit, where in episode 9 of "When the Rules Lawyer wants to build a nuke" the DM calculates the D&D 5e damage for a Little Boy nuclear weapon to settle a question for a player.

Link to the episode in question: https://www.youtube.com/shorts/3axQJ834AdQ

It usually spits out about 347 million and change HP in damage.

#include<stdio.h>
#include<stdlib.h>
#include<time.h>
#define DMRULING 99180000
void main() {
long long damage = 0;
int rolls=DMRULING;
srand(time(NULL));
while(rolls--)
damage+=rand()%6+1;
printf("\nThe nuke did %id6 damage, rolled to equal %llihp\n\n Mr. Cheddar is fondue.\n\n", DMRULING, damage);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment