CSGSI icon indicating copy to clipboard operation
CSGSI copied to clipboard

gs.Map.HasData always returns true

Open zzhabib opened this issue 3 years ago • 1 comments

When using gs.Map.HasData to detect whether the user is in game or on the main menu, I noticed that it seems to always return true regardless of condition. I did find a workaround which is to use gs.Map.JSON.Equals("{}") which will return true if when the player is on the main menu.

zzhabib avatar Jul 09 '21 04:07 zzhabib

Just use something like if (gs.Map.Phase != CSGSI.Nodes.MapPhase.Live) to check if the player is in a match or not.

spreedated avatar Nov 06 '22 03:11 spreedated