atomic-penguin / sm-hidden

Hidden:Source like mod for TF2
GNU General Public License v3.0
2 stars 2 forks source link

use of bool playing and bool started aswell as GetConVarBool(cv_enable) #28

Closed ghost closed 11 years ago

ghost commented 11 years ago

after looking over all the uses of the two bools it seems we have to keep track of whether the gamemode is enabled (either through started or GetConVarBool(cv_enabled) and whether or not a map has begun spawning players with playing (or similar). There is however a slight problem with the Start/EndPlugin functions, they currently check if started is which ever value they need to proceed then toggle it to indicated that it has started or ended. If we were to replace started with GetConVarBool(cv_enabled) in these cases and update the value with ServerCommand("tf2_hidden_enabled 0") f.e this would call ->cvhool_enabled() -> CheckEnable()-> and then back to Start/EndPlugin() over and over.

I think our best bet is to create a global cvar_enabled or started and use that for all instances of checking and keep playing the same for now at least.

atomic-penguin commented 11 years ago

Fixed in v2.2.0 tag