Fix roundStart and roundEnd hooks being called twice in sub editor
This commit is contained in:
@@ -1046,11 +1046,8 @@ namespace Barotrauma
|
||||
GameSession gameSession = new GameSession(backedUpSubInfo, "", GameModePreset.TestMode, CampaignSettings.Empty, null);
|
||||
gameSession.StartRound(null, false);
|
||||
|
||||
GameMain.LuaCs.Hook.Call("roundStart");
|
||||
|
||||
(gameSession.GameMode as TestGameMode).OnRoundEnd = () =>
|
||||
{
|
||||
GameMain.LuaCs.Hook.Call("roundEnd");
|
||||
Submarine.Unload();
|
||||
GameMain.SubEditorScreen.Select();
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user