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

KI Incoming read/unread status is broken #1246

Open
dgelessus opened this issue Sep 25, 2022 · 0 comments
Open

KI Incoming read/unread status is broken #1246

dgelessus opened this issue Sep 25, 2022 · 0 comments

Comments

@dgelessus
Copy link
Contributor

If an avatar has any items in the KI's Incoming folder, the KI icon in the bottom bar will flash on login to notify the player. The game is supposed to track when the player reads incoming items and then stop flashing the KI icon once all items have been read, but this is currently broken. At the moment, the only way to stop the flashing KI icon is to move or delete all items out of Incoming.

Fixing this is not straightforward, because not only is the client code buggy/incomplete, but the necessary server support is also broken or unimplemented.

Internally, the "seen" status is stored in the vault, but not in the node itself. Instead, it's an extra field on every node ref (parent/child relationship). This was presumably done so that when the same item is sent to multiple different avatars, each one has its own seen status, even though the node itself is shared across all recipients.

However, no current server implements this properly. DIRTSAND and MOSS don't support the network message that lets the client change a node ref's seen status. Cyan's server accepts the message, but silently ignores it. DIRTSAND hardcodes all node refs as unseen, MOSS hardcodes them all as seen, and Cyan's server sends unpredictable junk data in the seen field (seems to be always nonzero, i. e. seen, but can't know for sure).

The client code is there in principle, but the Python glue code is incomplete/buggy, so even if the server side worked correctly, it wouldn't do anything useful. Specifically:

  • pyVaultNodeRef::BeenSeen/ptVaultNodeRef.beenSeen always returns false and doesn't even try to look up the seen status.
  • pyVaultNodeRef::SetSeen/ptVaultNodeRef.setSeen has the parent and child nodes reversed, so it never finds the right RelVaultNodeLink to update, and as a result also never sends the Cli2Auth_VaultSetSeen message to the server. The correct implementation would be fChild->SetSeen(fParent->GetNodeId(), v);.

The client code would be easy to fix I think, but it wouldn't be of any use without working server support. Fixing the client would actually cause problems for fan servers, because both DIRTSAND and MOSS error out when receiving the Cli2Auth_VaultSetSeen message. The fan servers could be updated to support this message and store the seen status properly, although in both cases this would require extending the database. In any case, Cyan's implementation will probably never be fixed, so any client-side fixes still need to handle that.

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

1 participant