Page 1 of 3 123 LastLast
Results 1 to 15 of 37

Thread: TTP Save Game Viewer

  1. #1
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0

    TTP Save Game Viewer

    Hello Survivalists! I was working lately on viewer for TTP save game files. My goal is to make server admin support tool that they could view players inventory in order to search for anomalies. I know that Alloc's tool alredy has this feature, but I needed to check out inventory while player is offline. Also I wanted to add other cool info that is stored in .ttp files.

    [Update! - see changelog]
    For now there is only some basic functionality - player name, steam ID, belt and backpack grid with player items. Items are displayed in the same order as in game. But ttp files have a lot more info inside i.e. known recipes, spawn position, item durability or all "physiology" data and more. I'm pretty sure I can access and read this data although this is sluggish process.

    All it takes is to upload valid Alpha 9 .ttp file and info should appear. Note the ttp viewer is under development and bugs are expected! :-)


    Link to the tool


    Known bugs:
    • TTP Tool is unstable with game save files converted from previous versions of game. I.e. If you have one tpp file from alpha 9.0 to alpha 9.3 tool can display gibberish data. This is on TODO list, after implementing all basic stable features.


    Changelog:

    v0.8
    • Fixed food and water indicators. Now when player have 0% it should display correctly.
    • If item stack is greater or equals 64, items are highlighted - this going to be improved. Each item will be checked for the proper max. stack size.
    • Minor layout improvements.


    v0.7
    • Added "Known Recipes" list
    • Fixed "Already Crafted" and "Known Recipes" function. No more "bushes".
    • Added items counter for "Already Crafted" and "Known Recipes"
    • Integration with crafting.7dtd.pl. Now recipes in "Already Crafted" and "Known Recipes" lists are clickable and show you recipe for each item.

    v0.6
    • Added Last Spawn Position Coordinates
    • Food indicator
    • Water indicator


    v0.5
    • Added to Items Data Base: Old Sham Sandwich, Nailgun, Nail
    • Added Player Stats: Zombie Kills, Lives Lost, Players Kills, Total Score.
    • Minor layout changes


    v0.4
    • Added Waypoint coordinates.
    • Small "already crafted" improvements

    v0.3
    • Added basic "already crafted" items list
    • Changed some layout fixes

    v0.2
    • Added basic file header validation
    • Added SteamID64 link to profile
    • Added displaying game version of the ttp file from header

    v0.1
    • Added Player name
    • Added SteamID64
    • Added basic tool-belt and backpack support
    Last edited by laredo; 09-18-2014 at 06:10 PM. Reason: update v.08

  2. #2
    Reconstructionist bigc90210's Avatar
    Join Date
    Jan 2014
    Location
    Newcastle, UK
    Posts
    658
    Rep Power
    1
    havent had a chance to test this yet as im at work but this concept wise is brilliant! thank you for your hard work!!!

  3. #3
    Scavenger
    Join Date
    Jul 2014
    Posts
    45
    Rep Power
    0
    Just tried it out and it works foe me. great tool

  4. #4
    Reconstructionist Koolio's Avatar
    Join Date
    Nov 2013
    Location
    http://7dtd.tk
    Posts
    534
    Rep Power
    0
    planning to open source it?

  5. #5
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0
    bigc90210 and zleipt - thanks guys!

    Quote Originally Posted by Koolio View Post
    planning to open source it?
    I was thinking about it. But for now it is no, and those are two reasons:
    - Code is total mess and to be honest I'm little ashamed of it ^^ I'm more art person than coder.
    - There is very small difference between viewer and editor. Therefore knowledge about ttp file structure can be nasty for players with bad intentions.

  6. #6
    Fun Pimps Staff
    Join Date
    Oct 2013
    Location
    Germany - Darmstadt
    Posts
    2,991
    Rep Power
    1
    Quote Originally Posted by laredo View Post
    - There is very small difference between viewer and editor. Therefore knowledge about ttp file structure can be nasty for players with bad intentions.
    Well, only for singleplayer, as those files are stored server side
    Also, the full TTP structure can be easily found out by looking at the games code, took me no more than 5minutes a few days ago.

    Btw, the server mod also allows to look at an offline players inventory since rev147 (2 days ago)


    Good job on this tool though, hope you keep improving it

  7. #7
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0
    Quote Originally Posted by Alloc View Post
    Well, only for singleplayer, as those files are stored server side
    This is true however I was thinking about other vectors of attack i.e. pockets spoofing. I don't know it is even possible but it is easier when you know what to look for

    Quote Originally Posted by Alloc View Post
    Also, the full TTP structure can be easily found out by looking at the games code, took me no more than 5minutes a few days ago.
    Ohh, If I only knew that few days ago I was like change item, save, quit game and search for differences... lol

    Quote Originally Posted by Alloc View Post
    Btw, the server mod also allows to look at an offline players inventory since rev147 (2 days ago)
    Good job on this tool though, hope you keep improving it
    I'll check it out. Thank you Alloc! Your work is awesome!

  8. #8
    Reconstructionist Koolio's Avatar
    Join Date
    Nov 2013
    Location
    http://7dtd.tk
    Posts
    534
    Rep Power
    0
    I'd be interested in knowing where to see that code myself

    "Btw, the server mod also allows to look at an offline players inventory since rev147 (2 days ago) "

    I was going to start making a tool similar to this using the output from that, nice to know its working off offline players aswel now.

    laredo I don't mind messy code if you do ever open source it

  9. #9
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0
    I've added few things for the viewer. First is some basic ttp header validation and game version check. Interesting thing is that version bit repeats few times in the whole file. But I'm not quite sure why yet Maybe some crc stuff maybe coincidence.

    Second new buggy feature is "already crafted items" list. It should work but on occasion it can display few "bushes" like "����C;". This is because I didn't catch firm grip on the offset for now (todo). Next step is "Known Recipes" list - this should be easy when "already crafted" will be done.

    Huge problem for me with that list was item delimiter. It seems to be probably random hex number but always lower than 0x1E. I'll investigate it further.
    eee.jpg

    Also some layout changes and other minor stuff.

    I've also decided to prepare some graphic visualization for the ttp file structure when I'll figure most of it. This should help some folks with their tools.

  10. #10
    Refugee
    Join Date
    Jul 2014
    Posts
    8
    Rep Power
    0
    Awesome tool thanks.

    Is their any way to add Items to a players Inventory by editing this? It could be very helpful for giving out lost keystones and other items.

  11. #11
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0
    Quote Originally Posted by SuspectX View Post
    Is their any way to add Items to a players Inventory by editing this? It could be very helpful for giving out lost keystones and other items.
    Technically writing/adding items to file is pretty easy task. But before this I have to understand ttp file in 100% and read all it's contents (for now it's like half of file for me). With that, making full editor would be cakewalk.

    Now I think such editor could be useful for admins. I'll keep that in mind. Thanks!

  12. #12
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0
    New feature:
    - If player set way point, viewer will display its coordinates.
    - Also some minor "already crafted items" improvements

    Way point was easy to read from file, but harder to implement. PHP is not really big endian and long int friendly ಠ_ಠ But now player position should be easy to decode.

    waypoint.jpg

  13. #13
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0
    New version is out! I think I've made some progress with decoding so rest of the info from ttp file should appear on viewer real soon. Next will be editor

    v0.5
    • Added to Items Data Base: Old Sham Sandwich, Nailgun, Nail
    • Added Player Stats: Zombie Kills, Lives Lost, Players Kills, Total Score.
    • Minor layout changes

  14. #14
    Scavenger laredo's Avatar
    Join Date
    Nov 2013
    Location
    Poland
    Posts
    56
    Rep Power
    0
    Another update. I'm having trouble finding health value as well as stamina. I'm not sure if it's even stored in tpp. Maybe server side? Any info on this will be appreciated

    v0.6
    • Added Last Spawn Position Coordinates
    • Food indicator
    • Water indicator

  15. #15
    Fun Pimps Staff
    Join Date
    Oct 2013
    Location
    Germany - Darmstadt
    Posts
    2,991
    Rep Power
    1
    Yup, they aren't stored.

Posting Permissions

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