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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Outfit dialog sends hat=0-1 #377

Closed
nhnb opened this issue May 26, 2020 · 4 comments
Closed

Outfit dialog sends hat=0-1 #377

nhnb opened this issue May 26, 2020 · 4 comments
Assignees
Labels
component: webclient Related to the web client. type: bug Causes a negative impact or not working as intended.

Comments

@nhnb
Copy link
Member

nhnb commented May 26, 2020

馃悶 Describe the bug

According to the server log, the client sends a outfit_ext action with hat=0-1

馃敟 How to reproduce

I was not able to reproduce the issue

馃實 Environment

  • Web client
@nhnb nhnb added the type: bug Causes a negative impact or not working as intended. label May 26, 2020
@AntumDeluge
Copy link
Member

The problem is that the client is prepending "0" to outfit codes. "-1" is the value to use when a layer should not be drawn. So what is being sent is "0-1".

ERROR [verManager] CommandCenter            (165 ) Player [deluge, -1335443416] Attributes of Class(): [sourceid=68][zone=0_fado_forest_s_e2][zoneid=0_fado_forest_s_e2][type=outfit_ext][value=body=995,dress=01,head=0-1,mouth=00,eyes=0-1,mask=0-1,hair=0-1,hat=0-1]- Cannot execute action Attributes of Class(): [sourceid=68][zone=0_fado_forest_s_e2][zoneid=0_fado_forest_s_e2][type=outfit_ext][value=body=995,dress=01,head=0-1,mouth=00,eyes=0-1,mask=0-1,hair=0-1,hat=0-1] send by Player [deluge, -1335443416]

What should have been sent is:

value=body=995,dress=1,head=-1,mouth=0,eyes=-1,mask=-1,hair=-1,hat=-1

@AntumDeluge
Copy link
Member

AntumDeluge commented Dec 18, 2021

The problem appears to be here: https://github.com/arianne/stendhal/blob/88e9269/srcjs/stendhal/ui/outfitdialog.js#L482

This is unnecessary with the new outfit system.

Edit: Okay, it is necessary, but needs to be omitted if the value is "-1" I think.

@AntumDeluge
Copy link
Member

I believe this is fixed by c9e12b0, but should be tested more.

@AntumDeluge AntumDeluge self-assigned this Dec 18, 2021
@AntumDeluge AntumDeluge added the component: webclient Related to the web client. label Dec 18, 2021
@AntumDeluge
Copy link
Member

Working correctly on test server now. So closing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: webclient Related to the web client. type: bug Causes a negative impact or not working as intended.
Projects
None yet
Development

No branches or pull requests

2 participants