Git Product home page Git Product logo

Comments (8)

BjossiAlfreds avatar BjossiAlfreds commented on July 17, 2024

I just tested myself and can confirm this.

Using listentities, the adrenaline's origin looks very strange, like it was moved algorithmically after being spawned. In the original dll its final location after droptofloor() is -622 398 72, while it is -604.55 410.65 15 in YQ2 which is very odd. That big difference in vertical position may be why it is unreachable.

I tried running my own dll using YQ2 and that works fine, so this has something to do with game.dll I would assume.

from xatrix.

NeonKnightOA avatar NeonKnightOA commented on July 17, 2024

So, what could be the function to check? Maybe I can create a PR and submit it.

from xatrix.

BjossiAlfreds avatar BjossiAlfreds commented on July 17, 2024

I did more digging, this is happening inside SV_Physics_Toss() in g_phys.c. The adrenaline item spends quite a few frames sliding around before falling into its final position. However in the original game it doesn't move at all and stops in the final position given by droptofloor(). So there is something different in the code, or possibly a side-effect of compiler options that have to do with optimizations or floating point precision.

from xatrix.

BjossiAlfreds avatar BjossiAlfreds commented on July 17, 2024

I figured it out. In SV_PushEntity() in g_phys.c, at lines 514 - 517 is new YQ2 code that when commented out fixes the problem. I guess it just so happens that in this case, the adjustments lead to the entity getting moved around and eventually falls into an inaccessible space.

I'm assuming Yamagi wouldn't want to remove the code as it prevents other issues with entities rendering black, so perhaps a map hack or a fixed .ent file would do the trick?

One side question - is trace.plane defined if trace.fraction == 1? Seems odd to me to adjust to trace.plane.normal if the trace didn't collide with anything.

from xatrix.

NeonKnightOA avatar NeonKnightOA commented on July 17, 2024

Indeed, a map fix via code may be the best solution.

from xatrix.

Yamagi avatar Yamagi commented on July 17, 2024

A map fix would be one option. The problem is, that we found the first place were the lighting fix breaks game logic. There might be more of them, especially in rather crude custom maps... @DanielGibson and I will ponder about it. If we can come up with another fix for the lighting problem, everything's okay. Otherwise we'll add a map fix.

from xatrix.

thesourcehim avatar thesourcehim commented on July 17, 2024

I tested mentioned commit (yquake2, debris_fix branch), but the problem persists.
EDIT: ok, my bad. Applied that patch to xatrix/game.so and now I can pick adrenaline just fine.

from xatrix.

Yamagi avatar Yamagi commented on July 17, 2024

I've pushed the fix to all addons.

from xatrix.

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.