Open LearningDave opened 8 years ago
Lua can do pdd = hero..damageDealt or 0
and that gets rid of your lines 58 to 66 if you do the same for damage taken.
I am not sure what is @jimmydorry liking these days in terms of items, but I think sending 6 item slot entries is problematic because it doesn't tell you anything about item pick rates
@MNoya
Thanks :) updated my schema.lua:
http://pastebin.com/f0vKmiaM
Waiting for @jimmydorry response before removing/changing? the items.
Looks good, including six item slots.
You should add a duration variable in the game array. Make sure to math.floor() the time.
@jimmydorry
Done :)
Output: http://pastebin.com/Xx0vnnn1 schema.lua update http://pastebin.com/T6ZDjKd1
Your schema has been approved. Please double check I didn't make any mistakes in field names or display names.
https://getdotastats.com/#s2__mod_schema?mid=140
Your schemaID is here: https://getdotastats.com/#s2__my__mods
@jimmydorry
No mistakes done, schema is live, thanks a lot! :)
I'm just wondering about some games having the length of "0:04" where only the host would be connected. I'm aware of a problem where people fail loading the addon, however getdotastats should only get games when "SetGameWinner" is used right?
So there are a lot of games like this listed: https://getdotastats.com/#s2__match?id=6098207
Should i make a new issue for this? Must be something on my end, but i'm not really sure where to look into to solve this.
I saw your message on IRC and left you a memo.
You are correct in that this should not be happening. You are either doing something funky, or it's a valve bug.
Your mod is essentially failing to load, and yet progressing through all of the game stages to post_game. It could be some kind of crash error, where some of the hosts are quick enough to send out the stats, but this shouldn't really be possible.
Do you manually set the game stages anywhere in your mod?
I think your best bet is to try and reproduce this error and get the console log.
Phase 2 would only ever be sent if:
DOTA_GAMERULES_STATE_PRE_GAME
and the override isn't enabled in settings.kvstatCollection:sendStage2()
Phase 3 would only ever be sent if Phase 2 has been sent and if:
SetGameWinner(winner)
is called and enabled in your statcollection settings.kv
settings.kv
statCollection:sendPhase3(winners, isLastRound)
For GDS to think the match lasted 0:04, phase 2 and phase 3 must have been sent.
@jimmydorry Thanks for your fast responses :) I managed to let someone reproduce it and send me the console output: http://pastebin.com/afMV8QHw Result on getdotastats: https://getdotastats.com/#s2__match?id=6138148
I don't set the game stages manually (using barebones)
Those lines might be interesting out of the log (409 - 427):
S:Gamerules: entering state 'DOTA_GAMERULES_STATE_DISCONNECT' SV: Disconnect client 'ПІЙМАВ НА ГЕНЗЮЦУ' from server(69): NETWORK_DISCONNECT_SERVER_SHUTDOWN ConVarRef debug_spew doesn't point to an existing ConVar ConVarRef barebones_spew doesn't point to an existing ConVar SV: Dropped client 'ПІЙМАВ НА ГЕНЗЮЦУ' from server(69): NETWORK_DISCONNECT_SERVER_SHUTDOWN SV: Disconnect client 'ХОКАГЕ' from server(69): NETWORK_DISCONNECT_SERVER_SHUTDOWN ConVarRef debug_spew doesn't point to an existing ConVar ConVarRef barebones_spew doesn't point to an existing ConVar SV: Dropped client 'ХОКАГЕ' from server(69): NETWORK_DISCONNECT_SERVER_SHUTDOWN ConVarRef debug_spew doesn't point to an existing ConVar ConVarRef barebones_spew doesn't point to an existing ConVar Stat Collection: Attempting to send pregame stats... Stat Collection: Attempting to send final stats... C:Gamerules: entering state 'DOTA_GAMERULES_STATE_DISCONNECT' Could not find data for item! item_aegis SV: Receiving C2S_CONNECT [protocol 43 2836131016 auth 3] from [U:1:180073861]:0 Connection to Steam servers lost. Stat Collection: Match pregame settings have been recorded! Stat Collection: Match stats were successfully recorded!
According to line 409 "DOTA_GAMERULES_STATE_DISCONNECT" it tries to send stuff ( line 420+421) inside the disconnect state?
Looks like a networking issue. Some one smarter than me (like sinz, bmd, or noya) may have a better idea of how that can happen.
@MNoya @SinZ163 @bmddota your wisdom is needed :), please help me out
Ok thats an easier fix than expected, on line 195, add an elseif statement for DISCONNECT, or change line 196 to be an exact comparison (not needed for POST_GAME because if it made it to PRE_GAME, its a legit enough match)
In your copy of the stat-collection library.
@SinZ163 @jimmydorry Thank you! Seems to work now :)
Link to your console log http://pastebin.com/u7SLdA8w Link to your settings.kv http://pastebin.com/RMmPf9WQ Link to your schema.lua http://pastebin.com/jQp7YXEn Link to your Lua files that defines the functions you pull stats from addon_game_mode.lua : http://pastebin.com/BETgverc custom hero name : http://pastebin.com/zHpr2E1G damage dealt / taken : http://pastebin.com/9kmp5HZd
Playerstat meanings: ph = hero name pt = team name pk = kills pa = assists pd = deaths pl = level plh = last hits pde = denies pnw = money pdd = damage dealt to heroes pdt = damage taken from heroes i1 = itemname slot 1 i2 = itemname slot 2 i3 = itemname slot 3 i4 = itemname slot 4 i5 = itemname slot 5 i6 = itemname slot 6