Page 4 of 19 FirstFirst ... 2 3 4 5 6 14 ... LastLast
Results 31 to 40 of 181

Thread: Dota 2 Demo File Format

  1. #31
    Valve Developer Zoid's Avatar
    Join Date
    Sep 2011
    Posts
    1,065
    Quote Originally Posted by snevets View Post
    Will we need to worry about backwards compatibility at any point, or do you foresee the replay format staying as-is for a really long time? Will the proto files need to be changed at all in the future, requiring a re-compile? This is amazing btw, keep it up!
    One of the reasons we switched to Google's protobuf it allows you to add and remove fields from serialized messages without breaking compatibility. Our goal going forward is to ensure we don't break our demo format unless absolutely necessary.

    I'll definitely update the tool as we add more fields as Dota 2 grows. Mostly its just updating the .proto files as we expand and add messages.

    Note that this parser prints out all the messages except for the entity data. We currently do not provide the individual entity frame information contained in svc_PacketEntities so it will be harder to decode actual player, creep and other positions. This can be done, but its something we are not providing at this time.

    The messages that players will be most interested in are the svc_GameEvent and svc_UserMessage. The provide all the events of the game such as player deaths, combat log data, etc.

  2. #32
    Valve Developer Zoid's Avatar
    Join Date
    Sep 2011
    Posts
    1,065
    Quote Originally Posted by mitsuhiko View Post
    @Zoid: I also found a bug with the original code. There is a broken printf statement in the code:

    Code:
    'printf( "%s", msg.DebugString() );'
    DebugString() returns a std::string and not a char*, so a .c_str() is necessary there.
    Oops! I'll fix this and upload a new version today. Good catch!

  3. #33
    Basic Member
    Join Date
    Feb 2012
    Posts
    12
    Theres libraries for php that will do this aswell.. Just sayin... we dont need a executable file to do this.

  4. #34
    is there a way which we could download or save or anything possible for a match data statistic in json format?.....json format would be the most convenient way.i would like to have a web format parser if ever..tnx for this nice update anyway..

  5. #35
    Basic Member
    Join Date
    Nov 2011
    Posts
    5
    Zoid... are there any plans to expose team chat?

  6. #36
    Valve Developer Zoid's Avatar
    Join Date
    Sep 2011
    Posts
    1,065
    Not at present. We actually do not record team chat into the demo at all.

  7. #37
    Basic Member
    Join Date
    Nov 2011
    Posts
    5
    Bummer... Thats pretty much the one thing I was digging into replays for. One of those other games has a site that exposes the team chat with the kill times and I always found it highly amusing to read the team chat after a game.

  8. #38
    Basic Member Tsunami Nori's Avatar
    Join Date
    Sep 2011
    Location
    Vietnam
    Posts
    203
    only one thing now is player name and hero they pick ...
    sorry for my bad English ...

    From Vietnam with Love - Lagest DOTA 2 Community in Vietnam: DotA-2.Vn

  9. #39
    Basic Member Cyborgmatt's Avatar
    Join Date
    Sep 2011
    Location
    United Kingdom
    Posts
    389
    Quote Originally Posted by KaMiKaZe.PiG View Post
    So I just got here, and haven't looked into this at all... but it appears this will only run on Windows? Are you serious? How is this going to be useful for web sites?
    Here you go: https://github.com/mitsuhiko/dota2-demoinfo2
    // Economy
    "NotTheStringsYoureLookingFor"

  10. #40
    Quote Originally Posted by mitsuhiko View Post
    I made some minor changes to make it compile on OS X. Repo is on github: https://github.com/mitsuhiko/dota2-demoinfo2

    It should also compile on linux. Just make sure that protobuf and snappy are installed. Same goes for OS X. If you have brew just "brew install snappy" and "brew install protobuf". Then compile with "make".

    @Zoid: I also found a bug with the original code. There is a broken printf statement in the code:

    Code:
    'printf( "%s", msg.DebugString() );'
    DebugString() returns a std::string and not a char*, so a .c_str() is necessary there.
    Thanks, man.

    I literally have no time for this until late in the weekend, so this is great.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •