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

Where is Skin Info? #102

Open
allenzhang1997 opened this issue Dec 27, 2019 · 0 comments
Open

Where is Skin Info? #102

allenzhang1997 opened this issue Dec 27, 2019 · 0 comments

Comments

@allenzhang1997
Copy link

I was interested in whether a player is using skins in a replay.

I thought the skin info is this: m_syncLobbyState->m_userInitialData->m_skin

So the code was like (if I want to print out the first player's skin info):
archive = mpyq.MPQArchive(replay_path)
contents = archive.header['user_data_header']['content']
header = versions.latest().decode_replay_header(contents)
baseBuild = header['m_version']['m_baseBuild']
protocol = versions.build(baseBuild)
initData = archive.read_file('replay.initData')
InitData = protocol.decode_replay_initdata(initData)['m_syncLobbyState']['m_userInitialData']
print(InitData[0]['m_skin'])

But for all the replays I checked, all players had b'' , which means they are not using skin....?
While some of the replays did have players using skin.

So it that the right place to find skin info?
Or is it actually stored somewhere else?

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