Author Topic: Surface 2 Consistent Spawn Guards  (Read 662 times)

Icy

  • Posts: 2462
    • GE
    • PD
    • twitch
    • 2014SilverStar
    • 2015SilverStar
    • 2022FantasyChamps
Surface 2 Consistent Spawn Guards
« on: August 01, 2018, 10:57:47 am »
I've been scouring through the code of the game lately and collecting a pile of interesting info, and I stumbled upon an idea that should help with the spawning guards on Surface 2. First a little bit of detail on how they work:

As soon as the level begins during the first cutscene, a 5-second initial timer starts, and no spawn guards are able to spawn until these 5 seconds have passed. After that and after the first cutscene is over (I think they can spawn during the second cutscene), spawn guards will begin spawning and respawning every 2 seconds. That is, after every 2 seconds, the game checks if all 4 spawns are alive, and if any haven't spawned/are dead and finished fading out, it'll respawn any that need to be.

However, during each of these respawn checks, there's actually an RNG element based on what weapon you're currently wielding. When a spawn guard tries to spawn, they have a 55 / 256 chance (~21.4%) chance of doing so if you're wielding Unarmed, Hunting Knife, Throwing Knife, PP7, PP7 Silenced, or Sniper Rifle. They have a 205 / 256 (~80%) chance of doing so if you're wielding Klobb, Grenade Launcher, or KF7. If you have anything else wielded, they have a 100% chance of doing so. This code is copied from Surface 1, which is why there are strange weapon choices. This is also related to why we pick up the KF7 for the new "M Strat".

So normally, a spawn can only be successful 21.4% of the time when we're running around with PP7 Silenced. However, we're also carrying a Remote Mine, which will cause a 100% spawn success chance! This completely bypasses the RNG check!

Here's a demonstration where I use 2.X and fully watch both cutscenes in order to demonstrate the consistency of the spawn guards:


And here's a demonstration of what real runs would look like by starting with the Remote Mine and switching to PP7 before we make it to the trees. Because spawn cycles are only every 2 seconds, we only need to carry the Remote Mine for a full 2 seconds before needing to switch back:


You could also use this trick while running from the first to the second cam, as spawns who are 1500 units or more away from you (basically the length across a good chunk of the level) are immediately deleted. You could get them to respawn nearby as you approach the tower, for hopes of a late grenade.

I think this will help out a lot for those involved in the Surface 2 craze, and also answer why spawn guards normally seem somewhat inconsistent, even if we use the same cutscene timing each time. Hopefully we see some players make good use of it. :v
« Last Edit: August 01, 2018, 02:01:57 pm by Icy »

Wyst3r

  • Posts: 4374
  • Train Strat Master
    • Henrik
    • GE
    • PD
    • twitch
    • 2018SilverStar
Re: Surface 2 Consistent Spawn Guards
« Reply #1 on: August 01, 2018, 11:17:20 am »
I actually mentioned this in Illu's twitch chat yesterday. Didn't have time to look into it in more detail but since you already did that I guess I don't have to anymore :nesquik:

Whiteted

  • Posts: 745
  • Frig 21 or bust
    • GE
    • PD
    • twitch
    • 2018SilverStar
    • 2020SilverStar
    • 2021CommunityContributor
Re: Surface 2 Consistent Spawn Guards
« Reply #2 on: August 01, 2018, 01:09:07 pm »
The 11 in 256 is only to roll for a grenade, and I'm pretty sure their grenade probabilities are 3/4 giving nearly exactly 1 in 31 for a grenade from a single action. I think that if they pass the 11 in 256 test but fail the 3/4 test then they just do nothing (so do no animation).

Post with references to the scripts here
Ex Runway 21 consultant
TASpap chief scientist
Positionally top of Yendis' top GE players of 2020 :nesquik:
Noticably absent from Yendis' top GE players of 2021

Icy

  • Posts: 2462
    • GE
    • PD
    • twitch
    • 2014SilverStar
    • 2015SilverStar
    • 2022FantasyChamps
Re: Surface 2 Consistent Spawn Guards
« Reply #3 on: August 01, 2018, 02:01:39 pm »
I was trying to figure out that bit, and that seems to make a lot of sense, thanks.