Jump to content
Search In
  • More options...
Find results that contain...
Find results in...
Sign in to follow this  

Duke Nukem Style Water

Recommended Posts

I'm sure somebody here knows this trick, but I just figured it out and I think it's damn cool, and not really complicated either.

It's possible to make swimmable water in ZDoom, but it's very restrictive. The swimmable portion is just the area beneath a fake floor. In Duke Nukem, falling into water would take you to a different sector, such that you could have entirely different architecture under the water. You could, for example, jump off a pier, and then see the pier from the bottom underwater.

By using a few special Things, you can emulate this effect perfectly. I've made a dock that surrounds part of a building, and with this method you can go into the water and swim under the docks; something you couldn't do with regular underwater sectors.

First you need to know how to make ordinary deep water sectors.

To make a Duke Nukem style water sector, you will need a seperate sector for the underwater part(just like in duke), with the exact same dimensions as the above water sector.

In this sector you need a "Teleport Landing Remember Vert" object. You also need one of these in the water sector, in the exact same location. Set the Z coordinate of both objects such that the player warps to the appropriate height(for a sector with real floor -500 and fake floor -70, i find a Z coordinate of 250 works perfectly).

In the above water sector, put an "Eyes go below fake floor" Thing. Set it's special to "Teleport Group". The tid field should be 0(this will teleport the activator), source tid should be the tid of the teleport landing above water, and dest tid should be the tid of the teleport landing below water. Do the opposite underwater, putting an "Eyes go above fake ceiling", and reversing the tids.

The above water sector should be a regular deep water sector, such that if you removed those things, you could swim in it as normal. The underwater sectors are also deep water, except they have a fake ceiling instead of a fake floor. The fake floor and fake ceilings should be at equal heights. The real floor heights of the above and underwater sectors need to be the same as well. If you need a different floor height, but sure to adjust the Z coordinate of the teleport landing accordingly.

You also need "Water Sector" Things in the swimmable parts, and it helps to set the color of the underwater sectors to blue(the deep water example on the Zdoom page shows you how to do this).

It takes a while to fine tune it, but it works perfectly and opens up a whole new dimension of water sectors.

Share this post

Link to post

Indeed, I put one of these in capslock, and when you get out of the water your on a high ledge a few meters away from where you went in.

Share this post

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this