On my head, they keep falling

Feel free to discuss here about news on our blog
User avatar
Okulo
Posts: 636
Joined: 05 Feb 2012, 16:11

On my head, they keep falling

Post by Okulo » 16 Oct 2014, 12:08

It's been a while since the last update, so you're probably curious what has happened in the meantime. Well, we've got 108 closed issues on the 0.33.0 tracker now and many more bugs have been fixed that did not appear on there. Let's look at a few.

One particularly interesting bug left Dagoth Ur dead. In Morrowind you were supposed to defeat seven of Dagoth Ur's cronies before facing the big bad himself. A script would be running that lowered Dagoth Ur's health by 50 points every time you killed one of them, making for a total of 350 points of damage to the Sharmat. In vanilla Morrowind, this script was broken so the damage was not done. However, OpenMW didn't have this bug in the first place, so the script ran as instructed. The result was that Dagoth Ur, who only had 300 health, would already be lying dead in his cavern before you had even reached him. Ironically, the effects of the bug needed to be replicated to make the game function as intended.

There was also an issue with the rain, a visual effect that is actually all smoke and mirrors. You wouldn't (or rather shouldn't) notice, but when it rains in-game, it doesn't rain everywhere. There's no reason to, really; it would be unneccessarily taxing your system for little (visual) gain. Instead, it only rains where the player, you, is walking. In first person you wouldn't see the difference anyway. But once you switched you third person, you could see how extremely local the rain actually was. That's been fixed now. Rain will fall wherever your camera is positioned, not wherever your character is.

Another issue was with followers. When teleporting or traveling via silt strider your follower would be sent to your destination first. After that, you would go. This happened almost simultaneously, so normally you'd never notice. But since your follower has the exact same destination as you, you would be placed on top of your follower's head. In outside areas that was silly at best, but if you were transported to a destination inside a building (such as one of the Mages Guild halls), you would end up not just on top of your follower, but with the top part of your body clipping through the ceiling. That is fixed now, too, so no more Philadelphia Experiment-esque fusings in the guild halls.

Some news from the OpenCS corner, too. Terrain rendering has been included, which means you can now properly view the terrain from OpenCS. Those squares with text you see on the screenshot are the x,y-coordinates and the name of the cell. This way you know exactly where you are as you are flying over the terrain.

cc9cii has spent some time cleaning up code and Lazaroth has been playing around with shaders. He wondered what it would look like if water changed its behaviour based on the weather. For example, when it rains, that should be reflected in the water, right? He has already replicated the effect, but right now only one such effect can be applied to the water itself. Right now it is not possible to apply different effects to the water surface depending on the current weather, but Scrawl mentioned that with some work that should not be a big issue. It's definitely work that is worth doing, because not only does it allow developers to change the shape of the water surface, it also allows for other cool effects, like streets getting a nice sheen from the rain.

Speaking of Scrawl, he has started a blog of his own. This blog will not only chronicle the more technical sides of OpenMW, but also that of other projects he's working on. As of now, his most recent post is about porting OpenMW to Ogre 2.0, which should give OpenMW a nice performance boost. If you've got a little background in software development, this is bound to interest you. Check out Scrawl's blog for more of his coding (mis)adventures.

That's it for now. Version 0.33.0 is making good progress and the sheer amount of fixes has prompted talk of another release soon, so stay tuned.

Mistahtokyo
Posts: 87
Joined: 07 Sep 2013, 18:31

Re: On my head, they keep falling

Post by Mistahtokyo » 16 Oct 2014, 17:51

Does rain look decent when you're outside, but under a ledge? Or does it simply clip through everything? The local rain thing seems like it would break if you're under a roof and looking out a window. It'd be clear outside if the rain had collision and was being blocked, or it'd be raining indoors. Either way, not very appealing.

Chris
Posts: 1370
Joined: 04 Sep 2011, 08:33

Re: On my head, they keep falling

Post by Chris » 16 Oct 2014, 22:19

Mistahtokyo wrote:Does rain look decent when you're outside, but under a ledge? Or does it simply clip through everything?
It clips through everything. The way precipitation is handled (in terms of the vanilla engine, which we try to replicate) is really inefficient... it just drops a bunch of models around the camera, and adding physics to all of them them to detect collisions is pretty costly. I've had thoughts on alternate ways to do it, but I have no idea if it would be feasible, nor do I have a way to try it.

SquireNed
Posts: 397
Joined: 21 Dec 2013, 22:18

Re: On my head, they keep falling

Post by SquireNed » 17 Oct 2014, 05:37

If it's localized on the camera, would an upwards ray trace be feasible? If the edge is detected, maybe they could be set up for a further draw distance, essentially (in not C++):

Code: Select all

$rainradius=0;

if(collidesUp($playerX,$playerY){
$isUnderSurface==true;
}

while($isUnderSurface==true){

$rainRadius=$rainRadius+10; //rainradius=int starting at 0

foreach $testdegrees as $testdegree{
    if(collidesUp(trigKyleDoesntKnowX*rainradius,trigKyleDoesntKnowY*rainradius)==true){
    $isUnderSurface==true;
    }else{
        $isUnderSurface==false;
    }
}
Where collidesUp is a function that takes a point, the player's height, and looks to see if it is below a mesh. It should probably also have something to check to see if you've gone under the landscape.

This would cause rain particles to be drawn out rainRadius units in all directions, which is hacky but might be a super-cheap solution.

Chris
Posts: 1370
Joined: 04 Sep 2011, 08:33

Re: On my head, they keep falling

Post by Chris » 17 Oct 2014, 16:45

My idea is to render a top-down orthographic depth map, then render the precipitation at various distances in front of the camera. Where the rendered pixels are lower down than the depth map value, it doesn't render anything (kind of like shadow mapping, except instead of shaded/unshaded, it's rendered/discarded).

Main problem is I don't think this will be particularly cheap on the GPU, since it's yet another render pass. As it is, there's already a shadow mapping render pass, a water reflection render pass, and the main scene render pass.

User avatar
scrawl
Posts: 2143
Joined: 18 Feb 2012, 11:51
Contact:

Re: On my head, they keep falling

Post by scrawl » 17 Oct 2014, 17:15

My idea is to render a top-down orthographic depth map, then render the precipitation at various distances in front of the camera. Where the rendered pixels are lower down than the depth map value, it doesn't render anything (kind of like shadow mapping, except instead of shaded/unshaded, it's rendered/discarded).
I like this idea. We can probably distribute the workload by only updating the depth map once every few frames. The texture wouldn't have to be particularly high-resolution either.

Mistahtokyo
Posts: 87
Joined: 07 Sep 2013, 18:31

Re: On my head, they keep falling

Post by Mistahtokyo » 18 Oct 2014, 05:59

There's no shortage of overhangs/ledges/cliffs in Morrowind and TR, so the feature certainly would be appreciated :P

User avatar
xirsoi
Posts: 8
Joined: 21 Oct 2014, 21:14

Re: On my head, they keep falling

Post by xirsoi » 21 Oct 2014, 21:23

How do you intend to deal with the Dagoth Ur bug?
Off of the top of my head, re-instate the fix and reduce the dealt damage to 20 per Ash Vampire, reducing his HP by just under half.

I think this allows you to fix a bug in the script while still maintaining the *intent* of it.

But then again, that is a content issue, completely outside the purview of OpenMW...

So, 1.01 then?

[edit]

In regards to rain, the MCP managed to let rain collide, and I've seen it in more modern games that are way, way more resource intensive than MW, I think its worth looking into.

HiPhish
Posts: 323
Joined: 02 Jul 2012, 08:36

Re: On my head, they keep falling

Post by HiPhish » 22 Oct 2014, 08:13

Could the Dagoth Ur bug be fixed/reintroduced using a mod? If so, then how about having a built-in mod for this one exception that ships with the engine by default? That way the engine code stays clean of any exception hacks.

User avatar
raevol
Posts: 2600
Joined: 07 Aug 2011, 01:12
Location: Caldera

Re: On my head, they keep falling

Post by raevol » 22 Oct 2014, 08:33

I was hoping this was fixed in the MPP, but I don't see it in there. Can't be sure that I am correct though.

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests