Ok, so I think you just want to re-evaluate the RTV condition when players leave. So, I would probably make these changes (this is the diff file of the changes):
PHP Code:
@@ -75,6 +75,8 @@ public client_disconnected(id)
g_rockedVote[id] = false
g_rockedVoteCnt--
}
+
+ check_rock_the_vote()
}
public cmdSayRTV(id)
@@ -128,6 +130,13 @@ public cmdSayRTV(id)
g_rockedVoteCnt++
client_print(id,print_chat, "[MG] You chose to change Mod")
+ check_rock_the_vote()
+
+ return PLUGIN_CONTINUE
+}
+
+check_rock_the_vote()
+{
if( g_rockedVoteCnt >= get_RocksNeeded() ) // Decide if we rock the vote
{
g_hasbeenrocked = true
@@ -139,8 +148,6 @@ public cmdSayRTV(id)
{
rtv_remind()
}
-
- return PLUGIN_CONTINUE
}
public startRockVote()
__________________