Voting fakeouts

The voting cursor can land early, or go up a position, on vote end. Not only is this hilarious and makes it more unpredicatable, it also makes it easier for the game to pick a vote and move on to the next level .

(I bet people will mistake this for a bug on release :V)
This commit is contained in:
TehRealSalt 2018-06-12 22:10:26 -04:00
parent d1e206072a
commit d5f311681f

View file

@ -2403,7 +2403,9 @@ void Y_VoteTicker(void)
{
if (voteclient.rendoff == 0)
{
if (tempvotes[((pickedvote + voteclient.roffset + 4) % numvotes)] == pickedvote
if ((tempvotes[((pickedvote + voteclient.roffset + 4) % numvotes)] == pickedvote // Pick normally
|| tempvotes[((pickedvote + voteclient.roffset + 3) % numvotes)] == pickedvote // Fake out: land early
|| tempvotes[((pickedvote + voteclient.roffset + 2) % numvotes)] == pickedvote) // Fake out: cheat and move
&& voteclient.rsynctime % 51 == 0) // Song is 1.45 seconds long (sorry @ whoever wants to replace it in a music wad :V)
{
voteclient.rendoff = voteclient.roffset+4;