
I saw a YT Short earlier about the tram on Der Eisendrache and how there’s a small chance of getting a Ray Gun from it. Having never done this side egg, I was wondering what the exact chance was.
Nobody seemed to know the exact chance for each of the rewards, so I checked out the logic behind the tram and went down a bit of a rabbit hole. If you’re interested too, here’s the full breakdown of what happens when you use a tram fuse.
TL;DR
Ray Gun = 1% chance
0% chance before round 5
The way people go on like this is the rarest thing to ever happen made me think the chance was going to be like 0.1% or something. 1% doesn’t seem all that rare.
First of all there are two different trams, the secret tram you can get Monkey Bombs from is referred to in the game script as player_tram, and the normal tram that you can get a Ray Gun from is called token_tram.
To activate the player_tram, the only requirement is that you activate the damage trigger inside the tram with a grenade. You don’t need to throw all your grenades into the tram as I’ve seen some people suggest (just one grenade will suffice), but this does have to be done before the tram_cooldown flag has been set for the first time, otherwise the game script effectively ignores the grenade trigger for the rest of the match. So do it right at the start of the match.
Every player who wants to use the player_tram must throw their own grenade into the tram, as it’s a per-player flag. The damage has to come from a player, and the means of damage can only be MOD_GRENADE or MOD_GRENADE_SPLASH – so either a direct impact or splash damage from a grenade. Other weapons that fire grenades or projectiles might also register as a hit on the trigger.
After hitting the trigger inside the tram with a grenade, you then need to activate the token_tram five times. token_tram activations are also tracked per-player. This means that the player_tram can be called up once per player, per match.
When a player uses a tram fuse, the first thing the game does is checks whether the following conditions are true:
– Has the player who used the fuse damaged the player_tram trigger?
– Has the player activated the token_tram five times?
If both conditions are true, it will activate the player_tram instead of the token_tram.
If the player_tram is activated, there is an equal chance (33.3%) of it rewarding the Monkey Bomb, the Pap’d Haymaker or the Pap’d Man-o-War.
If the token_tram is activated the first thing that happens is a random number is generated between 1-100. If the random number = 1, and the round number is 5 or higher, it selects the Ray Gun as the reward. So effectively the chance to get a Ray Gun is 1% – or 0% if you haven’t passed round 4 yet.
If the player that uses the fuse already has a Ray Gun, or a Ray Gun MK2, or a Pap’d version of either, or if the game otherwise deems the player ineligible to receive a Ray Gun, the game will instead reward the player with a Max Ammo.
If the Ray Gun isn’t selected as the reward, the game creates an array (a table) of rewards to pick from at random. Here’s how it decides the rewards that should be in the array:
The game first checks that both of the following conditions are true:
– Random number is between 1-20 (20% chance)
– The round number is 5 or higher
If both of those conditions are true, the only two rewards added to the array are: Fire Sale & Bonus Points.
If one or both of these conditions are not true, the game will instead add the following rewards to the array: Double Points, Insta Kill, Max Ammo.
– If the round number is 5 or higher, the nuke is also added to the array.
– If the player who called the tram possesses a shield, and if the shield does not already have max charges, the shield charge is added to the reward array.
Once the game has decided what rewards to add to the array, there is an equal chance of any of the rewards in the array being picked.
Finally, regardless of any of the outcomes above, if the random number is higher than 96 (i.e. a 4% chance), the game will also spawn a Hellhound. The Hellhound will spawn as well as your reward, not instead of your reward.
Because the Hellhound only spawns if the random number is above 96, this means there’s a 0% chance of getting a Hellhound spawn if you are rewarded with: a Ray Gun, Bonus Points or Firesale.
Source: function_1d6e73d0
I like breaking down functions like this, let me know if you thought this was interesting and if there’s anything else you think I should look at 🙂