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

Any easy way to get total gold net worth #93

Open
hiddenfun opened this issue Jan 17, 2018 · 2 comments
Open

Any easy way to get total gold net worth #93

hiddenfun opened this issue Jan 17, 2018 · 2 comments

Comments

@hiddenfun
Copy link

hiddenfun commented Jan 17, 2018

I've parsed OnCDOTAMatchMetadataFile(func(m *dota.CDOTAMatchMetadataFile) but it only gives slices of netWorth. Not the final one.

Here is the code:

parser.Callbacks.OnCDOTAMatchMetadataFile(func(m *dota.CDOTAMatchMetadataFile) error {
fmt.Println("lll>>", m.Metadata.GetTeams()[0].GetPlayers()[4].GetGraphNetWorth()[len(m.Metadata.GetTeams()[0].GetPlayers()[2].GetGraphNetWorth())-1])
return nil
})

Is final net worth value hidden and need calculations?

@rjcortese
Copy link

Hey there.
I suggest that you try a parse using:
p.Callbacks.OnCMsgDOTACombatLogEntry(func(m *dota.CMsgDOTACombatLogEntry) error { ... }
You can test the type of the combat log message something like:
` if m.Type == DOTA_COMBATLOG_PLAYERSTATS {
// and then test for something like m.Networth
}

Check out https://github.com/dotabuff/manta/blob/master/dota/dota_gcmessages_common.pb.go for the particular struct.
Hope this helps!

@hiddenfun
Copy link
Author

Thanks a lot. I'll try it

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