소스 검색

Check for connecting clients

Connecting clients aren't counted in `IsClientConnected()`.
nosoop 7 년 전
부모
커밋
cdec173b69
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      scripting/csrd_uptime_limiter.sp

+ 2 - 2
scripting/csrd_uptime_limiter.sp

@@ -15,7 +15,7 @@
 
 #pragma newdecls required
 
-#define PLUGIN_VERSION "0.2.0"
+#define PLUGIN_VERSION "0.2.1"
 public Plugin myinfo = {
     name = "[CSRD] Uptime Limiter",
     author = "nosoop",
@@ -81,7 +81,7 @@ bool IsHumanConnected() {
 			return true;
 		}
 	}
-	return false;
+	return (GetClientCount(false) - GetClientCount(true)) != 0;
 }
 
 /**