Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sending "server_win" message instead of "server_draw" #314

Open
SullyTheUnusual opened this issue Jan 12, 2016 · 3 comments
Open

Sending "server_win" message instead of "server_draw" #314

SullyTheUnusual opened this issue Jan 12, 2016 · 3 comments

Comments

@SullyTheUnusual
Copy link

When there is a tie, the "server_win" message is sent instead of the "server_draw" message. For example, Bob and Doug play a match and tie, it sends "Bob was victorious over {loserlong}!"

@Europia79
Copy link

which competition ? which victoryCondition ?

@Europia79
Copy link

Here's the code that pulls the match.*.server_victory node from messages.yml
https://github.com/alkarinv/BattleArena/blob/master/src/java/mc/alk/arena/controllers/messaging/EventMessageImpl.java#L61-L64
So, we need to work backwards to find what is calling that method() sendEventVictory() to see what is happening:
https://github.com/alkarinv/BattleArena/blob/master/src/java/mc/alk/arena/competition/events/Event.java#L153-L159
Here we see that the logic is good... so i'm starting to wonder if the CompetitionResult object parameter is being messed up before it's passed in ?

Here's the implementation of the abstract CompetitionResult which is MatchResult:
https://github.com/alkarinv/BattleArena/blob/master/src/java/mc/alk/arena/objects/MatchResult.java#L13

Here's an instance of where a MatchResult object is created with a Match object:
https://github.com/alkarinv/BattleArena/blob/master/src/java/mc/alk/arena/competition/match/Match.java#L208

This is interesting:
https://github.com/alkarinv/BattleArena/blob/master/src/java/mc/alk/arena/competition/match/Match.java#L1366

Which leads me here:
https://github.com/alkarinv/BattleArena/blob/master/src/java/mc/alk/arena/objects/victoryconditions/NTeamsNeeded.java#L52

Which is why i ask which competition and which victoryCondition ? Altho, it doesn't look like these lines are being executed in the scenario that you're describing, it looks like one of the victoryConditions may have un-expected behavior.

@SullyTheUnusual
Copy link
Author

It's ArenaPaintball and it's during the two-team matches that end in a draw.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants