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

[SCHEMA] Comics Heroes Wars #80

Open
Freeman322 opened this issue Jul 31, 2016 · 13 comments
Open

[SCHEMA] Comics Heroes Wars #80

Freeman322 opened this issue Jul 31, 2016 · 13 comments

Comments

@Freeman322
Copy link

Settings
SHEMA
ConsoleLog
Addon_game_mode

@jimmydorry
Copy link
Member

You've come a lot closer. Now you need to decide what you actually want to track. Your schema is empty.

Have a look at what the mod NWR did at line 51: http://pastebin.com/jQp7YXEn

At a minimum, I suggest recording the heroID, playerTeam, Kills, Assists, Deaths, Items in slot.

Another example to look at is in the files: here and here

We even have some commonly used functions: here in the files.

@jimmydorry
Copy link
Member

Take the time to do your schema properly.

I'll be back on tomorrow, so there is no rush to get it done immediately.

@jimmydorry jimmydorry changed the title [SCHEMA]Comics Heroes Wars [SCHEMA] Comics Heroes Wars Jul 31, 2016
@Freeman322
Copy link
Author

One question, i can only send data? Can i get needed me data when game starts?

@jimmydorry
Copy link
Member

What kind of data are you wanting to grab from the server?

We did have a library for that but didn't port it over to Reborn, as no-one asked for it.

We have a few APIs that were made for specific mods, like a player summary one (described in technical details here). That API lets a mod display stuff about players like when they last played, when they last abandoned, etc.

@Freeman322
Copy link
Author

I want create myself mmr system, for that i need get it from server and change after game ends

@jimmydorry
Copy link
Member

That's very much out of the scope of what I have the time to do right now. :(

I would suggest looking at the Valve docs, and asking questions in #dota2mods .

You also have this library's code to look at, but setting up a MMR is going to need more work than figuring out how to talk to servers.

@Freeman322
Copy link
Author

Updated SHEMA

@jimmydorry
Copy link
Member

Have you tested it? I'm not sure if you have defined line 46 and 47.

@Freeman322
Copy link
Author

No errors were observed

@jimmydorry
Copy link
Member

If you're happy, then let's do this!

Two suggestions:

  • Your line 46 should be wrapped with floor. We don't want fractions of a second.

game.gl = math.floor(GAME_TIME_ELAPSED) -- Game length, from the horn sound, in seconds

  • Your variable names are too long. I've shortened them for you, as it has no impact on how they are displayed on the site, but saves data.

pt = player_team, -- Team this hero belongs to
hn = GetHeroName(playerID), -- Hero by its short name
hl = hero:GetLevel(), -- Hero level at the end of the game
pn = GetNetworth(hero), -- Sum of hero gold and item worth
pk = hero:GetKills(), -- Number of kills of this players hero
pa = hero:GetAssists(), -- Number of deaths of this players hero
pd = hero:GetDeaths(), -- Number of deaths of this players hero

You should double check your schema fields match the site schema.

https://getdotastats.com/#s2__mod_schema?mid=144

Your schemaID should be in your account now: https://getdotastats.com/#s2__my__mods

@Freeman322
Copy link
Author

I should copy it without v1?

@SinZ163
Copy link
Member

SinZ163 commented Aug 1, 2016

without

@jimmydorry
Copy link
Member

Mind clarifying? I'm not sure what you meant by "copy without v1".

Have you pushed the schema live yet? You don't have any schema data, which suggests that there is a mistake somewhere.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants