aiannacc / Goko-Salvager

Enhance your Dominion Online experience!
13 stars 9 forks source link

Automatch via Quick Game doesn't use saved automatch rules #229

Closed theblankman closed 10 years ago

theblankman commented 10 years ago

When using Quick Game with "Use Automatch" turned on, the automatch request contains only the reqs from the Quick Game title, not the reqs I would see if I clicked the Automatch button manually. As a result, there is no way to make Quick Game request an automatch with requirements on what sets the opponent has. I just got automatched into a base-only game that way. Log of the automatch and game:

Failed to load resource: net::ERR_BLOCKED_BY_CLIENT https://ssl.google-analytics.com/ga.js
gatherUrlCookieParams found the following URL params: 
Array[1]
 FSSDK.js:553
ConnectionMaker merged the following cookie params: 
Array[1]
 FSSDK.js:563
FS.MessageWebSocketConnection.prototype.connect: currently trying - wss://wss.prod.dominion.makingfun.com:443 FSSDK.js:13424
event.returnValue is deprecated. Please use the standard event.preventDefault() instead.
FSSDK: webSocket: onopen: top: url:wss://wss.prod.dominion.makingfun.com:443 FSSDK.js:13479
Setting up GA connection heartbeat every: 60000 milliseconds FSSDK.js:13522
initMeetingRoom DominionClient.js:304
This element isn't a canvas - TypeError: undefined is not a function FSSDK.Notifier.js:198
This is a HTML Element FSSDK.Notifier.js:102
Dimension: W0px H0px @L638px T0px FSSDK.Notifier.js:115
Successfully subscribed to player notifications FSSDK.js:20398
Player Info Fetched  
Object
 DominionClient.js:847
Attr.specified is deprecated. Its value is always true.
Starting Goko Salvager 2.5.4.3 init.js:8
Loading Utils utils.js:7
Loading Settings Dialog blacklistSync.js:6
Loading Settings Dialog settingsDialog.js:6
Loading Notifications Module notifications.js:10
Loading autokick speedTweak.js:7
Loading Always Stack alwaysStack.js:7
Loading LaunchScreenLoader launchScreenLoader.js:6
Loading Module Loader
Preparing to load module WS Connection
Loading module WS Connection
Loading WS Connection module connection.js:28
Creating WebSocket connection to gokosalvager.com utils.js:11
Preparing to load module Avatars
Loading module Avatars
Preparing to load module Avatar Upload
Loading module Avatar Upload
Preparing to load module Blacklist
Loading module Blacklist
Preparing to load module Blacklist Sync
Loading module Blacklist Sync
Preparing to load module User Settings Dialog
Loading module User Settings Dialog
Preparing to load module Launch Screen Loader
Loading module Launch Screen Loader
Preparing to load module Notifications
Loading module Notifications
Preparing to load module Lobby Ratings
Loading module Lobby Ratings
Preparing to load module Deck Tracker
Loading module Deck Tracker
Preparing to load module Table State
Loading module Table State
Preparing to load module autokick
Loading module autokick
Preparing to load module Kingdom Generator
Loading module Kingdom Generator
Preparing to load module speedTweak
Loading module speedTweak
Tweaking animation speeds. speedTweak.js:20
Preparing to load module Always Stack
Loading module Always Stack
Preparing to load module Automatch Game Popup
Loading module Automatch Game Popup
Preparing to load module Automatch Offer Popup
Loading module Automatch Offer Popup
Preparing to load module Automatch Seek Popup
Loading module Automatch Seek Popup
Preparing to load module Automatch
Loading module Automatch
Preparing to load module QuickGame
Loading module QuickGame
Preparing to load module Sidebar
Loading module Sidebar
Preparing to load module Prettified Log Viewer
Loading module Prettified Log Viewer
Preparing to load module VP Calculator
Loading module VP Calculator
Preparing to load module VP Toggle
Loading module VP Toggle
Preparing to load module VP Counter
Loading module VP Counter
Preparing to load module Chat Box
Loading module Chat Box
Preparing to load module autozap
Loading module autozap
Connected to gokosalvager.com connection.js:49
TODO: Update icon for status: 1 connection.js:168
Launch Screen ready. launchScreenLoader.js:69
Personal currencyClient.js:64
Avatar Inventory currencyClient.js:64
Loaded avatar cache from gokosalvager.com avatars.js:23
Retrieved and cached common blacklist blacklist.js:36
Create achievements response:  
Object
 DominionClient.js:753
Quick game script loaded. utils.js:11
Initializing quick game. utils.js:11
Initializing quick game button utils.js:11
Not already loaded Automatch automatch.js:934
Automatch script loaded. utils.js:11
Initializing Automatch utils.js:11
Connecting to Automatch server at wss://gokosalvager.com:8889/automatch utils.js:11
Connected to Automatch server. utils.js:11
tname: all sets 5000+ #vpon utils.js:11
pcount: 2 utils.js:11
rSystem: pro utils.js:11
Reading rating range requirement utils.js:11
Object
 utils.js:11
Sending auto-automatch request utils.js:11
Sent SUBMIT_SEEK message to Automatch server: utils.js:11
Object
message: Object
seek: Object
blacklist: Array[2]
player: Object
requirements: Array[5]
0: Object
props: Object
max_players: 2
min_players: 2
__proto__: Object
rclass: "NumPlayers"
__proto__: Object
1: Object
props: Object
rating_system: "pro"
__proto__: Object
rclass: "RatingSystem"
__proto__: Object
2: Object
props: Object
vpcounter: true
__proto__: Object
rclass: "VPCounter"
__proto__: Object
3: Object
props: Object
max_pts: null
min_pts: 5000
rating_system: "pro"
__proto__: Object
rclass: "AbsoluteRating"
__proto__: Object
4: Object
props: Object
max_pts: null
min_pts: null
rating_system: "isotropish"
__proto__: Object
rclass: "AbsoluteRating"
__proto__: Object
length: 5
__proto__: Array[0]
__proto__: Object
__proto__: Object
msgid: "theblankman1400077738693"
msgtype: "SUBMIT_SEEK"
__proto__: Object
 utils.js:11
Got CONFIRM_SEEK message from Automatch server: utils.js:11
Object
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object
 utils.js:11
Receipt of message confirmed: theblankman1400077738693 utils.js:11
On Join all sets 5000+ #vpon 
d
 autokick.js:25
Ratings 5833 4104 35 9 autokick.js:44
RangeKickCriterion

RangeKickCriterion

NameKickCriterion

BlacklistKickCriterion
 autokick.js:76
2
false utils.js:11
3
true utils.js:11
my minimum Pro rating is 5000 utils.js:11
On Join all sets 5000+ #vpon 
d
 autokick.js:25
Ratings 5833 3531 35 3 autokick.js:44
RangeKickCriterion

RangeKickCriterion

NameKickCriterion

BlacklistKickCriterion
 autokick.js:76
2
false utils.js:11
3
true utils.js:11
my minimum Pro rating is 5000 utils.js:11
On Join all sets 5000+ #vpon 
d
 autokick.js:25
Ratings 5833 4104 35 9 autokick.js:44
RangeKickCriterion

RangeKickCriterion

NameKickCriterion

BlacklistKickCriterion
 autokick.js:76
false utils.js:11
4
true utils.js:11
my minimum Pro rating is 5000 utils.js:11
Got OFFER_MATCH message from Automatch server: utils.js:11
Object
offer: Object
accepted: true
acceptors: Array[0]
hostname: "count100"
matchid: "fd3344751086413b8606a3f92664dadb"
rating_system: "pro"
roomid: null
roomname: "Outpost"
seeks: Array[2]
0: Object
blacklist: Array[1]
player: Object
requirements: Array[5]
seekid: "28566b4ca0c84cbc82629fdd9a82d4db"
__proto__: Object
1: Object
blacklist: Array[2]
player: Object
requirements: Array[5]
seekid: "d46bdc885a7147a2b4489cd933b85301"
__proto__: Object
length: 2
__proto__: Array[0]
tableindex: null
vpcounter: true
__proto__: Object
__proto__: Object
 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object
 utils.js:11
Receipt of message confirmed: theblankman1400077761155 utils.js:11
Sent ACCEPT_OFFER message to Automatch server: utils.js:11
Object
 utils.js:11
Got ANNOUNCE_GAME message from Automatch server: utils.js:11
Object
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object
 utils.js:11
Receipt of message confirmed: theblankman1400077763182 utils.js:11
Got GAME_READY message from Automatch server: utils.js:11
Object
 utils.js:11
ready player not at table? FSSDK.js:15741
sitting seat player not at table? FSSDK.js:15760
ready player not at table? FSSDK.js:15741
Entered lobby: 5027185e14b17abbe206528f utils.js:11
Joining table: utils.js:11
Object
 utils.js:11
Joined game. Automatch finished. utils.js:11
FSSDK - called our ClientGameInstance constructor DominionGameClient.js:118
using query parameters for canvas size: 960 640 DominionUI.js:3953
calling FS.Advertising DominionGameClient.js:204
callback from FS.Advertising DominionGameClient.js:211
Using layout: layout960x640 DominionUI.js:1486
Sent GAME_STARTED message to Automatch server: utils.js:11
Object
 utils.js:11
Automatch server closed websocket. utils.js:11
Automatch connection failure: 1/100 utils.js:11
Not attempting to reconnect to automatch server. utils.js:11
creating dominionwindow DominionUI.js:13279
using card buidler. DominionUI.js:3740
canvas size: 960 640 layoutSize: [size 960 640] DominionUI.js:11399
using requestAnimationFrame DominionUI.js:13355
Room Chat: theblankman: Hello! May you have great fun and reasonable luck! utils.js:11
Room Chat: count100: gl utils.js:11
Room Chat: count100: gg utils.js:11
Options not closed. Error:TypeError: Cannot read property '_hide' of undefined DominionUI.js:12801
2
OPP EXIT chatbox.js:117
destroying  fan: hand DominionUI.js:6902
destroying flat: reveal DominionUI.js:6911
destroying deck: deck DominionUI.js:6906
destroying deck: discard DominionUI.js:6906
destroying  fan: hand DominionUI.js:6902
destroying flat: reveal DominionUI.js:6911
destroying deck: deck DominionUI.js:6906
destroying deck: discard DominionUI.js:6906
destroyed PlayerController DominionUI.js:13395
Entered lobby: null utils.js:11
Entered lobby: 5027185e14b17abbe206528f utils.js:11
Connecting to Automatch server at wss://gokosalvager.com:8889/automatch utils.js:11
Connected to Automatch server. utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400077990607"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400077990607"} utils.js:11
Receipt of message confirmed: theblankman1400077990607 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078015607"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078015607"} utils.js:11
Receipt of message confirmed: theblankman1400078015607 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078040606"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078040606"} utils.js:11
Receipt of message confirmed: theblankman1400078040606 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078065605"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078065605"} utils.js:11
Receipt of message confirmed: theblankman1400078065605 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078090608"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078090608"} utils.js:11
Receipt of message confirmed: theblankman1400078090608 utils.js:11
4
OPP EXIT chatbox.js:117
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078115607"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078115607"} utils.js:11
Receipt of message confirmed: theblankman1400078115607 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078140606"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078140606"} utils.js:11
Receipt of message confirmed: theblankman1400078140606 utils.js:11

After this occurred, I submitted an automatch request using the automatch button, here's the rest of the log:

requested seek utils.js:11
Sent SUBMIT_SEEK message to Automatch server: utils.js:11
Object {msgtype: "SUBMIT_SEEK", message: Object, msgid: "theblankman1400078664384"}
message: Object
seek: Object
blacklist: Array[2]
player: Object
requirements: Array[5]
0: Object
props: Object
rclass: "NumPlayers"
__proto__: Object
1: Object
props: Object
max_sets: 15
min_sets: 9
__proto__: Object
rclass: "NumSets"
__proto__: Object
2: Object
props: Object
pts_higher: 800
pts_lower: 800
rating_system: "pro"
__proto__: Object
rclass: "RelativeRating"
__proto__: Object
3: Object
props: Object
rating_system: "pro"
__proto__: Object
rclass: "RatingSystem"
__proto__: Object
4: Object
props: Object
vpcounter: null
__proto__: Object
rclass: "VPCounter"
__proto__: Object
length: 5
__proto__: Array[0]
__proto__: Object
__proto__: Object
msgid: "theblankman1400078664384"
msgtype: "SUBMIT_SEEK"
__proto__: Object
 utils.js:11
Got CONFIRM_SEEK message from Automatch server: utils.js:11
Object {seek: Object}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078664384"} utils.js:11
Receipt of message confirmed: theblankman1400078664384 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078666208"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078666208"} utils.js:11
Receipt of message confirmed: theblankman1400078666208 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078691185"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078691185"} utils.js:11
Receipt of message confirmed: theblankman1400078691185 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078716185"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078716185"} utils.js:11
Receipt of message confirmed: theblankman1400078716185 utils.js:11
Running ping loop utils.js:11
Sending ping utils.js:11
Sent PING message to Automatch server: utils.js:11
Object {msgtype: "PING", message: Object, msgid: "theblankman1400078741187"}
 utils.js:11
Got CONFIRM_RECEIPT message from Automatch server: utils.js:11
Object {msgid: "theblankman1400078741187"} utils.js:11
Receipt of message confirmed: theblankman1400078741187 utils.js:11

The second automatch request has NumSets and RelativeRating rules, and there doesn't seem to be a way to specify those rules when using Automatch with Quick Game (this might also be true with Create Game, I haven't checked). Not sure if it's a bug or intended that Quick Game with Automatch doesn't use saved Automatch settings. If it's intended, then Quick Game options need to include all the requirements in the regular Automatch UI.

yed commented 10 years ago

It is probably the same with Create Game.

Do you own any sets? If only base then why create a game? That game is base only, so others can join and you will have base only game even without automatch.

theblankman commented 10 years ago

I own all the expansions, so that's another weird thing, shouldn't Automatch have made me the host since I own more sets? Here's the game if that helps: http://gokosalvager.com/static/logprettifier.html?20140514/log.51600542e4b059d9adc7afea.1400077914183.txt

aiannacc commented 10 years ago

Putting everything the automatch dialog can do into the game title isn't a great solution. Some titles are getting truncated by the Goko UI already, and there's no point in putting info there that only applies to automatch and not to people who join your game manually.

We could add the missing automatch features to the existing Create Game dialog (like the "Use Automatch" button), or we could consolidate the dialogs into a single one that handles both functions. If we implement the latter solution, we could also fix some of the long-standing issues with the Create Game dialog, like the long delay when generating the first kingdom after login, the fact that the kingdom generator pops up in a modal dialog, etc.

The base-only issue is an outstanding automatch bug. I described it in the Salvager thread a while back, but I'd never made an issue for it here. It's #231.

theblankman commented 10 years ago

Yeah, I didn't mean to suggest putting everything in the title, I meant that the missing options could be added to the Quick Game section of User Settings as well as the Create Game dialog. But that puts the same stuff in three places, so I think your idea of having one place for Automatch settings is cleaner. Maybe make it a tab under User Settings? Then let Create Game, Quick Game and the Automatch lobby button all use settings from there. Create Game and Quick Game could also add requirements from the game title if needed.

I'm not sure about combining Create Game and Automatch settings into one dialog. If that's the single place for Automatch settings, having Quick Game and the Automatch button also use those settings isn't very intuitive. And the Automatch stuff plus the kingdom-building stuff might be too much for one dialog.

theblankman commented 10 years ago

If no one else is working this, I'm going to take a stab at making a single place for Automatch settings (probably a new tab under User Settings), and having all three sources of Automatch requests: Create Game, Quick Game and the Automatch button, use those settings. Create Game and Quick Game would start with those requirements and tack on additional ones parsed from the game title.

This would also give a workaround for #231. An Automatch Request from Quick Game will be able to have a number-of-sets requirement. Then if the server thinks the user owns no expansions, as happens in #231 when the user's sets owned info isn't populated, it would have to automatch the user with someone else who does own expansions. So for that request, the user would have fewer possible opponents, but wouldn't get an undesired game. It's not the perfect fix for #231 but it's an improvement.

aiannacc commented 10 years ago

Fixed by #238