Thread: rs cache utility written in rust

Results 1 to 10 of 10
  1. #1 rs cache utility written in rust 
    Registered Member excl150's Avatar
    Join Date
    Jul 2014
    Posts
    108
    Thanks given
    35
    Thanks received
    24
    Rep Power
    48
    rs-cache

    I've made a simple-to-use basic RuneScape cache utility. It has some very basic reading capabilities and supports item/npc definition loading.
    The crate is currently (as of writing this thread) at version 0.2.6. The crate is passively maintained, meaning more features will be added in the
    future once I require them for my own server project.

    Links:
    You can find rs-cache on [Only registered and activated users can see links. ] or on [Only registered and activated users can see links. ].
    To get started try looking at the [Only registered and activated users can see links. ] or the [Only registered and activated users can see links. ].
    The crate contains integration tests and examples to make using rs-cache as easy as possible, you can also find more examples in the documentation.

    The following features are currently provided:
    • Reading from the cache.
    • Huffman buffer access.
    • Checksum with simple-to-use validation.
    • Compression and decompression:
      • Gzip
      • Bzip2
    • Loaders & Definitions
      • ItemLoader - ItemDefinition
      • NpcLoader - NpcDefinition

    At this time there are no other crates that offer OSRS cache interactions so I figured I would fill the void. This is my first crate and my understanding of RSPS's could be better.
    I wanted to share this crate anyway to make it easier for other people to start their own servers using rust and as a personal learning experience.
    I'm currently slowly working towards supporting RS3. More definitions are planned in future releases.

    If you have any feedback that would improve any aspect of my crate, please let me know! You can do this by creating an [Only registered and activated users can see links. ].
    I hope this crate is of some use to anyone. Thank you for reading!
    Reply With Quote  
     

  2. Thankful users:


  3. #2  




    Scu11's Avatar
    Join Date
    Aug 2007
    Age
    26
    Posts
    16,103
    Thanks given
    7,102
    Thanks received
    11,942
    Rep Power
    5000
    good shit

    [Only registered and activated users can see links. ]



    Reply With Quote  
     

  4. Thankful user:


  5. #3  
    Super Donator

    Tyluur's Avatar
    Join Date
    Jun 2010
    Posts
    4,093
    Thanks given
    1,400
    Thanks received
    1,342
    Rep Power
    916
    Quote Originally Posted by Scu11 View Post
    good shit
    mtsmts
    [Only registered and activated users can see links. ] | [Only registered and activated users can see links. ] | [Only registered and activated users can see links. ]

    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  6. #4  
    Registered Member
    Bartvh's Avatar
    Join Date
    May 2017
    Posts
    333
    Thanks given
    71
    Thanks received
    130
    Rep Power
    222
    Nice work! If I can give some recommendations after writing a cache library myself:

    1. Don't push your full cache to git. You can extract groups from the cache and push those for integration tests.

    2. Split domain codecs and file codecs. So put your "definitions" in a different crate. This makes it so you can re-use the core part for multiple different games.

    3. Use Jagex naming. See [Only registered and activated users can see links. ] for more information or check the NXT/TFU artifacts.
    Reply With Quote  
     

  7. Thankful user:


  8. #5  
    Registered Member excl150's Avatar
    Join Date
    Jul 2014
    Posts
    108
    Thanks given
    35
    Thanks received
    24
    Rep Power
    48
    Quote Originally Posted by Bartvh View Post
    Nice work! If I can give some recommendations after writing a cache library myself:

    1. Don't push your full cache to git. You can extract groups from the cache and push those for integration tests.

    2. Split domain codecs and file codecs. So put your "definitions" in a different crate. This makes it so you can re-use the core part for multiple different games.

    3. Use Jagex naming. See [Only registered and activated users can see links. ] for more information or check the NXT/TFU artifacts.
    I'm not sure if my core is reusable for other games because I'm reading the entire cache into memory, this way I can return slices.
    The problem is RS3's cache is too large so I might need something like a BufReader around a file handle for reading.
    At the moment I'm only trying to support OSRS but I might look into making it generic enough to support more different games.

    About splitting domain codecs and file codecs: do you mean as a sub-crate of rs-cache or as a stand-alone crate?

    These recommendations are really helpful, thank you!
    The repository you linked looks amazing with how detailed it is! I'm going to give it a look and apply some changes to my crate.
    Reply With Quote  
     

  9. #6  
    Registered Member
    Bartvh's Avatar
    Join Date
    May 2017
    Posts
    333
    Thanks given
    71
    Thanks received
    130
    Rep Power
    222
    Quote Originally Posted by excl150 View Post
    I'm not sure if my core is reusable for other games because I'm reading the entire cache into memory, this way I can return slices.
    The problem is RS3's cache is too large so I might need something like a BufReader around a file handle for reading.
    At the moment I'm only trying to support OSRS but I might look into making it generic enough to support more different games.

    About splitting domain codecs and file codecs: do you mean as a sub-crate of rs-cache or as a stand-alone crate?

    See, the repository I linked as an example. I have Jagex-Store-5 as a general purpose library for reading/writing data. It can be used for JS5 client/servers or for game specific implementations. I currently only support 1 game (OSRS) which is in a different repository: [Only registered and activated users can see links. ]. It uses Jagex-Store-5 to read/write the data. Reading all the data into memory can be good for stuff like file servers but other than that it's probably not that useful. I created an abstraction for just reading raw data and reading files/groups/archives. You can then also support multiple back-ends like from memory, from disk or from a remote server.
    Reply With Quote  
     

  10. Thankful user:


  11. #7  
    Registered Member excl150's Avatar
    Join Date
    Jul 2014
    Posts
    108
    Thanks given
    35
    Thanks received
    24
    Rep Power
    48
    Quote Originally Posted by Bartvh View Post
    See, the repository I linked as an example. I have Jagex-Store-5 as a general purpose library for reading/writing data. It can be used for JS5 client/servers or for game specific implementations. I currently only support 1 game (OSRS) which is in a different repository: [Only registered and activated users can see links. ]. It uses Jagex-Store-5 to read/write the data. Reading all the data into memory can be good for stuff like file servers but other than that it's probably not that useful. I created an abstraction for just reading raw data and reading files/groups/archives. You can then also support multiple back-ends like from memory, from disk or from a remote server.
    I did not think of that when I started building.. thanks for taking the time to elaborating more. This was really helpful and I'm going to look into applying this, thanks once again!
    Reply With Quote  
     

  12. #8  
    Extreme Donator

    Women's Avatar
    Join Date
    Mar 2010
    Posts
    1,691
    Thanks given
    439
    Thanks received
    709
    Rep Power
    563
    damn thank you coder
    Reply With Quote  
     

  13. #9  
    Donator

    Join Date
    Oct 2015
    Posts
    68
    Thanks given
    8
    Thanks received
    2
    Rep Power
    15
    Does this also grab anims for items from cache?
    Reply With Quote  
     

  14. #10  
    Registered Member excl150's Avatar
    Join Date
    Jul 2014
    Posts
    108
    Thanks given
    35
    Thanks received
    24
    Rep Power
    48
    Quote Originally Posted by IntArray View Post
    Does this also grab anims for items from cache?
    No, I have not yet looked into getting animation ids for items. I'm using the RuneLite client as reference and I believe they refer to them as SequenceDefinitions.
    I'm working on adding all of the definitions but lately I got a bit distracted with other stuff. I will get to sequences in the future though, I just don't know when.
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. runite | 667 server written in Rust
    By lepaco in forum Projects
    Replies: 9
    Last Post: 05-03-2017, 09:04 AM
  2. Npcs Cache... *Bit wtf in side*
    By T X in forum Tools
    Replies: 11
    Last Post: 03-08-2009, 02:23 PM
  3. Replies: 1
    Last Post: 01-16-2009, 12:01 AM
  4. RS Cache Extractor
    By Elid in forum Requests
    Replies: 2
    Last Post: 09-01-2008, 09:43 PM
  5. Command Maker purely written in java (beta)
    By quest rs in forum Tools
    Replies: 7
    Last Post: 03-02-2008, 01:39 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •