Mentrillum / Slender-Fortress-Modified-Versions

A modification of Team Fortress 2 based on the game Slender: The Eight Pages.
GNU General Public License v3.0
33 stars 22 forks source link

Make Grace period its own round state #58

Closed KitRifty closed 2 years ago

KitRifty commented 2 years ago

This converts the grace period into a defined round state. The code in SF2 treats grace period as its own separate state, so it should be converted to be so. The outputs OnStateEnterGrace and OnStateExitGrace are added to sf2_gamerules to make it consistent with the other outputs on the entity. OnGracePeriodEnded will stay for backwards compatibility.

The only thing to take note of here is that this adds the SF2RoundState_Grace value to the SF2RoundState enum. This will cause a shift, so any external plugins that depend on the enum needs to be recompiled. I considered adding it to the end instead, but instead kept it in the order that a round typically goes through states for consistency.

The .fgd has also been updated to Private's latest version.