weird flex but ok

This commit is contained in:
neon 2019-11-28 15:45:31 +01:00
parent f36bb5a946
commit 5eb7ba5491

View File

@ -1296,7 +1296,7 @@ public void Handler_VoteFinishedGeneric(Handle menu,
SetConVarInt(g_Cvar_Fraglimit, fraglimit + GetConVarInt(g_Cvar_ExtendFragStep));
}
CPrintToChatAll("[MCE] %t", "Current Map Extended", RoundToFloor(float(item_info[0][VOTEINFO_ITEM_VOTES])/float(num_votes)*100), num_votes);
CPrintToChatAll("[MCE] %t", "Current Map Extended", RoundToFloor(float(item_info[0][VOTEINFO_ITEM_VOTES])/float(num_votes)*100.0), num_votes);
LogAction(-1, -1, "Voting for next map has finished. The current map has been extended.");
CPrintToChatAll("[MCE] Available Extends: %d", GetConVarInt(g_Cvar_Extend) - g_Extends);
@ -1308,7 +1308,7 @@ public void Handler_VoteFinishedGeneric(Handle menu,
}
else if(strcmp(map, VOTE_DONTCHANGE, false) == 0)
{
CPrintToChatAll("[MCE] %t", "Current Map Stays", RoundToFloor(float(item_info[0][VOTEINFO_ITEM_VOTES])/float(num_votes)*100), num_votes);
CPrintToChatAll("[MCE] %t", "Current Map Stays", RoundToFloor(float(item_info[0][VOTEINFO_ITEM_VOTES])/float(num_votes)*100.0), num_votes);
LogAction(-1, -1, "Voting for next map has finished. 'No Change' was the winner");
g_RunoffCount = 0;
@ -1337,7 +1337,7 @@ public void Handler_VoteFinishedGeneric(Handle menu,
g_HasVoteStarted = false;
g_MapVoteCompleted = true;
CPrintToChatAll("[MCE] %t", "Nextmap Voting Finished", map, RoundToFloor(float(item_info[0][VOTEINFO_ITEM_VOTES])/float(num_votes)*100), num_votes);
CPrintToChatAll("[MCE] %t", "Nextmap Voting Finished", map, RoundToFloor(float(item_info[0][VOTEINFO_ITEM_VOTES])/float(num_votes)*100.0), num_votes);
LogAction(-1, -1, "Voting for next map has finished. Nextmap: %s.", map);
}
}
@ -1355,7 +1355,7 @@ public void Handler_MapVoteFinished(Handle menu,
g_RunoffCount++;
int highest_votes = item_info[0][VOTEINFO_ITEM_VOTES];
int required_percent = GetConVarInt(g_Cvar_RunOffPercent);
int required_votes = RoundToCeil(float(num_votes) * float(required_percent) / 100);
int required_votes = RoundToCeil(float(num_votes) * float(required_percent) / 100.0);
if(highest_votes == item_info[1][VOTEINFO_ITEM_VOTES])
{