Darknut's Dwemer House

Post about your mods, learn about OpenMW mod compatibility, check for problematic mods, discuss issues, and give us feedback about your experience with modded OpenMW.
User avatar
Jemolk
Posts: 237
Joined: 20 Mar 2017, 02:12
Location: Sadrith Mora

Re: Darknut's Dwemer House

Post by Jemolk »

wareya wrote: 10 Dec 2018, 23:11 Vanilla lets actors pass through geometry that they're already overlapping. That's broken. It's not even up for debate whether it's broken or not.
That could be rather problematic. On the other hand, it might also be a reason why things like one-way walls work in vanilla, which are actually a desirable trick to have in some ways. Vanilla still seems to offer more possibilities for funky modding in no small part because of this, so I'm more than a little reluctant to call it broken and say we should get rid of it or do it another way.
wareya wrote: 10 Dec 2018, 23:11 The mannequins are also in the air (or, to be more precise, they're on a "steep slope" instead of a "floor", because they're overlapping the wall), which makes gravity apply to them, which means that they try to move.
I see. This makes it more appealing to have gravity not automatically apply to placed objects in midair, like in vanilla, and have the "fall" command to make it apply, for compatibility's sake. In dehardcoding, we could theoretically make it alterable which one is the default behavior and which needs to be specifically called to have it happen, so that this wouldn't limit new games with the engine much if at all, I hope.
wareya wrote: 10 Dec 2018, 23:11 It IS desirable to have actors not pop out of things that they're overlapping, but once they start moving, popping them out is the only thing you can do without being broken.

I tried a few ways of switching between popping-out and staying-still to fix the mannequins without affecting anything else, but they all caused other problems.
Hmm. Are we sure being broken in the way the OpenMW engine is broken is preferable to being broken in the way the vanilla engine is? Because I'm honestly still leaning the other way. (Not that I have any particular influence on anything, not having the coding skills to contribute, just food for thought.)
User avatar
wareya
Posts: 338
Joined: 09 May 2015, 13:07

Re: Darknut's Dwemer House

Post by wareya »

Going based on memory here, so I might be a little wrong, but if I'm wrong, just pretend that I'm talking about what OpenMW SHOULD be doing, IMO.

Ideally, one-way walls should still work, and you shouldn't collide with things if you're moving into them "from the back side".

The specific issue with the mannequins overlapping the wall is that the angle is basically 90 degrees, and because collision math with floating point numbers isn't perfect, that results in collision normals that don't point straight sideways away from the wall - they point slightly up or down, not just sideways. That means that half the time, it looks like a slope, causing the mannequin to think it's stuck inside of a very steep slope, and pop out of it.
User avatar
silentthief
Posts: 456
Joined: 18 Apr 2013, 01:20
Location: Currently traversing the Ascadian Isles

Re: Darknut's Dwemer House

Post by silentthief »

wareya wrote: 12 Dec 2018, 01:55 Going based on memory here, so I might be a little wrong, but if I'm wrong, just pretend that I'm talking about what OpenMW SHOULD be doing, IMO.

Ideally, one-way walls should still work, and you shouldn't collide with things if you're moving into them "from the back side".
Not of any help with the mannequins, however unless there was a change on how things work you cannot walk through walls from the back side. This is one thing that is different from how MW works. I had asked that question before and was told it doesn't work that way

ST
User avatar
wareya
Posts: 338
Joined: 09 May 2015, 13:07

Re: Darknut's Dwemer House

Post by wareya »

One of the changes my movement solver PR made was ignoring collisions with backwards normals, so that might have been fixed there. Not sure. (It's not merged yet.)
User avatar
Capostrophic
Posts: 794
Joined: 22 Feb 2016, 20:32

Re: Darknut's Dwemer House

Post by Capostrophic »

Doesn't look like it, I still get stuck inside Tel Vos coc destination position wall. Isn't backwards normal collision change specific to actor-actor collisions?
User avatar
wareya
Posts: 338
Joined: 09 May 2015, 13:07

Re: Darknut's Dwemer House

Post by wareya »

The actor-actor chance was making them act like cylinders if overlapping. You're right though, it looks like I forgot this part, oops.

Okay, let's look at this:

https://github.com/OpenMW/openmw/blob/5 ... ce.cpp#L39
https://github.com/OpenMW/openmw/blob/5 ... ce.cpp#L91
https://github.com/OpenMW/openmw/blob/5 ... e.cpp#L119

It's passing in "motion" into the misnamed "Up", btScalar(0.0) into the misnamed minSlopeDot, and taking the dot product of "Up" and the collision normal and throwing away the collision if it's on the wrong side of the minSlopeDot threshold (misnamed, again). This should be throwing away reverse-side collisions already. If it's not, it's because something about actor-mesh collision in bullet is failing to do internal edge rejection on the meshes.
User avatar
Jemolk
Posts: 237
Joined: 20 Mar 2017, 02:12
Location: Sadrith Mora

Re: Darknut's Dwemer House

Post by Jemolk »

wareya wrote: 12 Dec 2018, 01:55 Going based on memory here, so I might be a little wrong, but if I'm wrong, just pretend that I'm talking about what OpenMW SHOULD be doing, IMO.

Ideally, one-way walls should still work, and you shouldn't collide with things if you're moving into them "from the back side".

The specific issue with the mannequins overlapping the wall is that the angle is basically 90 degrees, and because collision math with floating point numbers isn't perfect, that results in collision normals that don't point straight sideways away from the wall - they point slightly up or down, not just sideways. That means that half the time, it looks like a slope, causing the mannequin to think it's stuck inside of a very steep slope, and pop out of it.
Interesting. So the mannequin problem is more properly solved with mesh changes, then?

Also, is there a way to make popping out only occur with actual coordinate shifting? It'd suddenly make a whole lot of things that work awkwardly at best in OpenMW either compatible (if using SkipAnim scripts, like mannequins frequently do) or merely reliant on Greatness7's idle animation fix (which people really should be more widely aware of anyway). I don't know if it's even possible, of course. As I've said, I still don't have the skill to work on the coding side of things, despite my desires.
Post Reply