Closed seiyria closed 10 years ago
@IdleMaster Introducing "Gamblers and Templars"! They don't need a catchphrase, because ConanTheLibrarian and Shion are too cool for that! @IdleMaster Gamblers and Templars passed by Shion, smiling and waving.
Also, it should avoid situations like this.
Grooglar [ HP 981/1571 MP 122/122 ], Grooglar [ HP 1250/1571 MP 122/122 ]
and like this.
Is the ask that the battles mix all available groups and players into two big teams (up to max)?
As I understand the system currently does: Existing Party vs Existing Party Solo player vs Solo Player (How did your second post happen, if Existing Party vs Player is not a scenario? Did I misunderstand or Mystery?)
Re: that second scenario, I have no idea how it happened. Also, I've updated that post with yet another mistake on my part.
Moving on to the issue: Suppose I have 4 players and two parties with these scores:
PartyA: 1300
PartyB: 1600
Gooby: 900
Rooby: 1000
Mooby: 200
Stooby: 600
These would be the available match ups (they're score-based and they might not reflect the actual constant that dictates if this can happen, but this is how I'd like it to be able to happen):
PartyA v. PartyB
PartyA v. Rooby
Gooby v. Rooby
(may be more, but these should all be possible, for example)
The key here is that if the first method fails, the second should always try, it should not be an if/else. However, the method that starts should be random, otherwise we will get a whole lot of one type of combat, all the time. Also, it should attempt to get a close enough match with scores the first time, then we don't have to keep trying (ie, the battle event rate is currently 1/75 or something absurd). A solution that I would do is something like gather all of the players, is map the players array to each player + their score, then sort highest to lowest, and when building parties, pick them in an order like this:
1 2 3 4 5 6 7 are the scores
party A: 7 4 1 = 12
party B: 5 6 2 = 13
For picking a battle of two players, it should always a sequential set of 3 players and just pick a random 2 out of there, since it should be "close enough" (if not, it will fail anyway).
But I'm open to better algorithms
Battles should be able to start with a mix of a party and players, and it should try to check for both able parties, and able groups of people - not just picking one and stopping - it should actively try to create a battle if it can.