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

Make transmog sync in MP #1

Open
buffyuwu opened this issue Apr 27, 2022 · 3 comments
Open

Make transmog sync in MP #1

buffyuwu opened this issue Apr 27, 2022 · 3 comments

Comments

@buffyuwu
Copy link

buffyuwu commented Apr 27, 2022

setting the clothing's asset via setClothingItemAsset is a clientside change, but what you could do is store their menu selection in a variable, get that selection's stats (scratch defense, other defenses etc) values and apply them to a new additem, the 'transmog', and have them wear that; that way the user is not getting a whole new item, armor, etc they only get that item with its texture/model/etc and the same stats as the base item (probably delete the base item after to avoid duping lol)

here's the reference for the clothing stats: https://zomboid-javadoc.com/41.65/zombie/inventory/types/Clothing.html#getScratchDefense()

the new item should sync automatically, but in the event that it does not,

sendVisual(player);
triggerEvent("OnClothingUpdated", player)
player:resetModel();
@mxswat
Copy link
Owner

mxswat commented Apr 27, 2022

I'm not sure if this is possible at all, but I'll give it a try

@buffyuwu
Copy link
Author

I'm not sure if this is possible at all, but I'll give it a try

i've been watching this mod for a bit, ill PR what i'm talking about when i have the time. it's simple but tedious

@mxswat
Copy link
Owner

mxswat commented Apr 29, 2022

Thank you I appreciate it, I'm quite busy with some front-end projects at the moment.

@mxswat mxswat changed the title suggestion Make transmog sync in MP Apr 29, 2022
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

2 participants