Advertisement
Guest User

Untitled

a guest
Aug 20th, 2017
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.77 KB | None | 0 0
  1. #include <sourcemod>
  2. #include <sdktools>
  3.  
  4. bool: Restarted = false
  5.  
  6. public Plugin:myinfo = {
  7. name = "Auto restart dupa warmup",
  8. author = "tre3fla",
  9. description = "Da restart dupa warmup",
  10. version = "1.0",
  11. url = "http://tre3fla"
  12. }
  13.  
  14. public OnPluginStart( ) {
  15. HookEvent( "round_start", Event_RoundStart )
  16. }
  17.  
  18. public OnMapStart( ) {
  19. Restarted = false
  20. }
  21.  
  22. public Event_RoundStart( Handle:event, const String:name[], bool:dontBroadcast ) {
  23. if (GameRules_GetProp( "m_bWarmupPeriod") == 1 && !Restarted ) {
  24. DoRestart( )
  25. }
  26. }
  27.  
  28. public DoRestart( ) {
  29. PrintToChatAll( "*\x04 Runda se restarteaza ..." )
  30. PrintToChatAll( "*\x04 Runda a fost restartata cu succes!" )
  31. PrintToChatAll( "*\x04 GL & HF" )
  32.  
  33. ServerCommand( "mp_restartgame 1" )
  34. Restarted = true
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement