Giter Site home page Giter Site logo

Chunk limit issue. about librg HOT 7 CLOSED

zpl-c avatar zpl-c commented on May 9, 2024
Chunk limit issue.

from librg.

Comments (7)

inlife avatar inlife commented on May 9, 2024 1

Hey @Tonyx97

Very interesting problem, I'm going to test it out tomorrow or the day after and try to find the bug. Any pieces of code that would help replicate the issue would be of great help!

from librg.

Tonyx97 avatar Tonyx97 commented on May 9, 2024 1

Thanks for the quick reply, I will attach the actual test project. I'm using VS 2022 with v143 MSVC compiler and C++20 as default language, it's currently in debug and x86 because I'm implementing the library as part of my mod in an existing game which requires reversing and so on. There may be useless files in the project but everything needed is linked by the project file itself so it should compile right away.

A quick summary, you should focus on server.cpp which is where I'm doing all the tests mostly. In line 115 I set the default chunk for entities, you can change the hardcoded chunk from there, if it's above 2^15 no events will be called, among other things. In line 220, I left some debug code to change from chunk to chunk which could be helpful for runtime tests. Hopefully I didn't make any stupid mistake regarding chunks lmao.

librg test.zip

from librg.

inlife avatar inlife commented on May 9, 2024 1

Thank you for the details! I will take a look :)

from librg.

inlife avatar inlife commented on May 9, 2024 1

Found the root cause, overflow indeed!

Here is the place with fix: 5b42c08
(Also added a special test case to verify against that)

Going to push the new release now

from librg.

inlife avatar inlife commented on May 9, 2024 1

Also, did you know you can just download a single header file from our releases page?

That way, you won't have to download and set up all of the structure and build and link librg binaries as you did in your example

from librg.

Tonyx97 avatar Tonyx97 commented on May 9, 2024

Oh nice work! I'm so glad to see you fixed it :D
. Yeah I know about the single .h but actually I want a static library instead, matter of preferences :D

from librg.

inlife avatar inlife commented on May 9, 2024

Got it!

Thank you for the report. Please let us know if you'll encounter any other problems.

from librg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.