Add Out of range battle list filter - #1237
Conversation
Hide lobbies whose titles advertise Min/Max chev or rating ranges the player is outside of.
|
ack, will go through all the resolutions on another pass. will be out for a few weeks so will address comments after |
Flow filter checkboxes into a bottom panel that wraps at narrow widths and relayouts after UI scale changes, fixing overlap and one-step-lag issues.
burnhamrobertp
left a comment
There was a problem hiding this comment.
Some potential simplifications, not sure all are definitely possible. Comments, naming and structure all look good to me, layout and element code looks good but I've not much experience there.
| local myRating | ||
| if me.accountID and WG.UserHandler and WG.UserHandler.GetSnapshotSkillValue then | ||
| myRating = WG.UserHandler.GetSnapshotSkillValue(me.accountID, battle) | ||
| end | ||
| if not myRating then | ||
| myRating = tonumber(me.skill) | ||
| end |
There was a problem hiding this comment.
I genuinely have no idea, but it's this not accessible through a single, reliable property?
There was a problem hiding this comment.
I went ahead and removed the check on me.skill.
Technically GetSnapshotSkillValue is more accurate as it filters by type (duel, ffa, etc), but it does fail for some edge cases (new player, etc). In those cases, me.skill is better, but even that doesn't cover all the cases since it just is the OS from the last played game. Unfortunately afaik there's no single check to get it accurately here.
The GetSnapshotSkillValue should cover the vast majority of cases/players though so I went ahead and removed the other one for clarity.
tbh, that makes both of us! I dabble in frontend and elements only when absolutely needed :') |






Adds a filter for min/max os and min/max chev to chobby battle lobby list. It parses the names of the lobbies to figure out which ones match your criteria.
For context im 6 chev ~35 os
without filter on


with filter on
AI used: cursor to understand/write, manual review & testing