Solved] Button doesn't reset after winning

Veliass

L1: Registered
Dec 29, 2016
30
17
So i'm making a deathrun map. But i have a problem. After winning, the buttons doesn't reset. Can you help me ?
 

worMatty

Repacking Evangelist
aa
Jul 22, 2014
1,258
999
Hello, there. Welcome to tf2maps.net. I am a fellow Deathrun mapper. I made dr_castle_steveh, am working on dr_steamworks_extreme and helped out a little with dr_bank.

When a round changes in TF2, nearly every entity resets. There are some exceptions but nothing that would normally interfere with your trap logic. If you have entities that aren't resetting, then either the round has not changed or your trap logic is broken. If you send me your VMF or a recently-compiled BSP I will take a look.
 

worMatty

Repacking Evangelist
aa
Jul 22, 2014
1,258
999
When you test a Deathrun map locally, the game treats it as a box with no game mode, so if all the players on one team die, they just respawn and there is never a winner. If you run a map on a server with a deathrun plugin enabled it gets treated as if it's an arena map, so players never respawn and when one team is all dead the other is declared the victor and the map is reset.

If you want to simulate a round reset when running your map locally, there are a couple of ways to do it.
  1. Insert a tf_logic_arena entity in your map. In order to play test it you require a player on each team, so you will need to spawn a puppet bot using the console command bot.
  2. Trigger a round win for the team of your choice by sending RoundWin to a game_round_win entity. You can have one configured for each team.
The console command mp_restartgame 1 will reset the map whenever you like. I've tested it with your map, and the traps are reset.
 

Veliass

L1: Registered
Dec 29, 2016
30
17
Ok, thank you so much.