Prevent duplicate map changes in randomcycle.sp (#1428)

This commit is contained in:
steph 2021-03-14 05:02:42 -04:00 committed by GitHub
parent ee27a48714
commit 4dd5ab7576
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -4,7 +4,7 @@
* SourceMod Random Map Cycle Plugin * SourceMod Random Map Cycle Plugin
* Randomly picks a map from the mapcycle. * Randomly picks a map from the mapcycle.
* *
* SourceMod (C)2004-2014 AlliedModders LLC. All rights reserved. * SourceMod (C)2004-2021 AlliedModders LLC. All rights reserved.
* ============================================================================= * =============================================================================
* *
* This program is free software; you can redistribute it and/or modify it under * This program is free software; you can redistribute it and/or modify it under
@ -76,7 +76,7 @@ public void OnConfigsExecuted()
} }
} }
CreateTimer(5.0, Timer_RandomizeNextmap); // Small delay to give Nextmap time to complete OnMapStart() CreateTimer(5.0, Timer_RandomizeNextmap, _, TIMER_FLAG_NO_MAPCHANGE); // Small delay to give Nextmap time to complete OnMapStart()
} }
public Action Timer_RandomizeNextmap(Handle timer) public Action Timer_RandomizeNextmap(Handle timer)