Navigate InfoSuite
Hosted At
Link to DNR

Link to Duke4
Advanced FX - Tricks - A2 : Transparent Water

Transparent Water

This effect was invented by Bob Averill. This is quite complex to construct. I explain it almost exactly as Bob explains it in his Transparent Water FAQ.



Deep Pools (Standard)


Switch to the largest grid size and create a sector 4 grid squares by 4 grid squares.

MISSING IMAGE!


Stay on the largest grid size and create another sector inside the first. Make this sector 2 grid squares by 2 grid squares. Use Alt + S to turn it into valid player space.

MISSING IMAGE!


Switch to the smallest grid size and move each vertex of the inner sector diagonally outwards by 1 square. The image below is taken in the largest grid size so you can see a clearer result.

MISSING IMAGE!


Switch to the largest grid size. Create another 2 by 2 valid player space sector inside the first. There will be a very thin gap between the walls of both inner sectors. Since this is only a demonstration, I'm leaving the gap at that size. Usually, however, I turn grid locking off (with L) and make that gap as thin as possible.

MISSING IMAGE!


Texture the outer sector however you want. Parallax all three sector's ceilings, and parallax only the two inner sector's floors (I parallaxed texture #94). Make sure both inner sector's floors are parallaxed.

MISSING IMAGE!


Hold the Left Mouse Button on the thin inner sector's floor, and press PGDN until you can no longer see it (even while looking down). Release the Left Mouse Button. Now place the mouse cursor over the area where the big inner sector's floor should be, and press PGDN twice. You should now be able to walk over the gaping pit without falling through.

MISSING IMAGE!


Switch to grid size 2. Place four sprites in the locations shown in the image. Make sure they are not blocked/hittable.

MISSING IMAGE!


Texture all of the sprites with water (#336). Use the R key to floor-align them. They should all be directly on the big invisible floor (use Ctrl + PGDN on each of them). Use T to make them as transparent as you wish. You can also texture the walls of your pool.

MISSING IMAGE!


The innermost sector will now be referred to as the above-water sector. Tag it [0,1], and place an S[Channel,7] within it.

MISSING IMAGE!


Use Right Alt to encapsulate all of the sectors. They will flicker green when highlighted. Copy the sectors with Insert, then use the Left Mouse Button to drag them next to the original (although this isn't reflected in the image below, you should move the copy an even number of spaces on grid size 1, or twice that amount per grid resolution; This will keep the floor/ceiling textures in proper co-ordination with the above-water texture alignment). The copy and the original should be completely independent of one another. Change the copied innermost sector's tag from [0,1] to [0,2]. This will be the below-water sector. In the remaining steps, we will be dealing with the below-water sector only.

MISSING IMAGE!


Raise the below-water sector's water sprites by a few units. You have to raise them so you can access the invisible floor beneath them. Turn the floor parallaxing off, and lower the floor until it matches the height of the bordering parallaxed floor. Disable the bordering floor's parallaxing as well, then texture both floors. The S should still be directly on the floor (use Ctrl + PGDN if it isn't).

MISSING IMAGE!


Temporarily disable parallaxing from the below-water sector's ceiling. Lower it until it is at equal height with the surrounding outer sector's floor, then lower it by 2 more units. Enable parallaxing again, and it will become invisible. This will force the player to be teleported below the water sprites when trying to submerge. The final step is to raise the water sprites directly onto the invisible ceiling (with Ctrl + PGUP).

MISSING IMAGE!


Notes:

  • The ceiling and floor must be parallaxed.
  • If the water sector is very large, the water will have to be ridiculously deep to hide the parallaxed floor. The workaround is described in the Shallow Pools section below.



Shallow Pools


To build a shallow pool, hide the parallaxed floor with sprites. It's not completely perfect (sometimes a floor sprite may show through the water), but it works well enough. Graphical glitches are less apparent when the gap between the two inner sectors is extremely thin.

MISSING IMAGE!


Note: Using the same trick, it is possible to create things such as invisible columns and slopes.


Return to top