Missing water level checks for portal water

Is there something that doesn't work right in the latest GZDoom? Post about it here.

Moderator: GZDoom Developers

Forum rules
Please construct and post a simple demo whenever possible for all bug reports. Please provide links to everything.

If you can include a wad demonstrating the problem, please do so. Bug reports that include fully-constructed demos have a much better chance of being investigated in a timely manner than those that don't.

Please make a new topic for every bug. Don't combine multiple bugs into a single topic. Thanks!

Missing water level checks for portal water

Postby Rachael » Tue Oct 26, 2021 2:27 am

Hello! I am working on a project with a few friends and we discovered a pretty major bug with how GZDoom handles waterlevel checks when it concerns portal water.

Our enemy in question is a giant fish that is allowed to float except when too far over the surface of the water - if that happens to him he's supposed to be pushed back down.

That works well with 3D floor water as demonstrated in this example, but it does not work at all well with portal water. In our project we really want to give mappers the option to use either water.

The attached example will show how these waterlevel checks affect the player as well - via a bit of console spam.

In checking p_mobj.cpp - I noticed that there are no portal checks at all in that code. I would fix this myself but this does not at all seem to be a simple fix - the waterlevel checking code here seems to be fairly involved, and may have even been copy-pasted a couple of times, making what should be a simple fix like this a lot more complicated. The only way I will be able to touch this code is if I refactor it, and streamline it through some function checks.
You do not have the required permissions to view the files attached to this post.
User avatar
Rachael
Admin
 
Joined: 13 Jan 2004
Discord: Rachael#3767
Twitch ID: madamerachelle
Github ID: madame-rachelle
Operating System: Debian-like Linux (Debian, Ubuntu, Mint, etc) 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: nVidia with Vulkan support

Re: Missing water level checks for portal water

Postby Graf Zahl » Tue Oct 26, 2021 2:35 am

There are indeed no portal checks for water. It is assumed that a portal boundary is not a boundary between water and non-water.
Due to the mess involved I skipped that scenario entirely.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
 
Joined: 19 Jul 2003
Location: Germany


Return to Bugs

Who is online

Users browsing this forum: yum13241 and 1 guest