-env_global only works with transitions, not changelevels. The only way to use a transition (changelevel2 "map_name") is by running the game in single player.
-SetValue needs to have a parameter override in order for it to actually set a value, I left it at <none>.
-env_global on the 2nd map sets value back to 0 on map start up (as if the initial value overrides the set saved value.
You actually need to set a value. On my multistage stuff (this was for a different source game, not TF2, so I can't say if this will even work the same), I was using logic like this on the final "win" trigger for stage 1:
Code:
OnStartTouch -> round_control (name of env_global) -> AddOutput -> globalstate round1
OnStartTouch -> round_control -> TurnOn
OnStartTouch -> round_control -> AddOutput -> globalstate round2
OnStartTouch -> round_control -> TurnOff
Then using logic_auto entities with GlobalStateToRead set to round2 and firing outputs with OnNewGame.
I'm not really clear on why I was doing the TurnOn before changing the globalstate and then TurnOff after. Maybe I needed to make sure it always had a "default" custom value first, or maybe an env_global needs to be "off" before it will persist, or maybe it's just leftover code from experimenting. I honestly can't remember.
[EDIT] Strike all of that. I forgot: you have to turn on the state. So basically what I was doing was setting round1 as the globalstate and turning that on, then setting round2 as the globalstate and turning that one off. So this is in fact not the logic from the end of stage1 trigger, it's the one that sets it to stage1 on a FAIL to win of stage1 (essentially saying restart the same level).
But even still, this is a lot simpler than what you're trying to do. I was basically just setting toggles to determine which stage of the map the players were supposed to be in; and I was only doing this because there was no equivalent of the TF2 logic that normally handles multistage maps.
What you might try now is AddOutput -> globalstate <some number>, then TurnOn. Then on the new map try checking with a logic_auto for GlobalStateToRead <some_number> and show a sprite or something if the value is there to see if it carries over.
I still feel like your strongest solution to this is to use a plugin and database. Then you'll be able to track time per player as well as whatever other info you want.