A way to disable the underwater reverb of a 3D floor

Moderator: GZDoom Developers

Post Reply
User avatar
SPZ1
Posts: 388
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois
Contact:

A way to disable the underwater reverb of a 3D floor

Post by SPZ1 »

I'm asking for this because I use a swimmable sector to simulate a ladder.
User avatar
Misery
Posts: 158
Joined: Sun Nov 04, 2018 4:57 pm

Re: A way to disable the underwater reverb of a 3D floor

Post by Misery »

viewtopic.php?f=3&t=50063
User avatar
Enjay
 
 
Posts: 26952
Joined: Tue Jul 15, 2003 4:58 pm
Location: Scotland
Contact:

Re: A way to disable the underwater reverb of a 3D floor

Post by Enjay »

SPZ1 wrote:I use a swimmable sector to simulate a ladder.
Perhaps worth mentioning that if someone has the Tilt++ mod loaded ( viewtopic.php?t=55413 ), there is a good chance that the underwater view rotating and shifting effect of that mod would probably engage while they were on the ladder.
User avatar
SPZ1
Posts: 388
Joined: Wed Aug 02, 2017 3:01 pm
Location: Illinois
Contact:

Re: A way to disable the underwater reverb of a 3D floor

Post by SPZ1 »

I noticed this...
This would also allow the player to drown on the ladder.
Looks like it would also need something such as a new SetActorProperty to specify that oxygen wouldn't run out. :( Otherwise you would just have to hope that the player wouldn't stop on the ladder for too long.
User avatar
Nash
 
 
Posts: 17487
Joined: Mon Oct 27, 2003 12:07 am
Location: Kuala Lumpur, Malaysia
Contact:

Re: A way to disable the underwater reverb of a 3D floor

Post by Nash »

Yeah don't try to hack engine features to do what they're not meant to do. There so many more little details hardcoded into the underwater movement and physics beyond just reverb and drowning. Don't order a cheeseburger without cheese yadda yadda.

Just implement a proper ladder system. There are several ways to properly do it, using either DECORATE, ACS or ZScript.
User avatar
Misery
Posts: 158
Joined: Sun Nov 04, 2018 4:57 pm

Re: A way to disable the underwater reverb of a 3D floor

Post by Misery »

Code: Select all

script 0 (int down)

{
	int z = GetActorZ (0), >> 0;

	if (GetActorPitch (ActivatorTID ()) > 1024) down = !down;

	if ((down && z > LADDER_BOTTOM && z < LADDER_TOP + 24) || (!down && z < LADDER_TOP))
	{
		SetPlayerProperty (0, 1, PROP_FLY);
		ThrustThingZ (0, 16, Down, 0);
		SetLineBlocking (LADDER_FRONT, BLOCK_CREATURES);
		SetLineBlocking (LADDER_BACK, BLOCK_CREATURES);

		ladder = 1;
	}

	else
	{
		SetPlayerProperty (0, 0, PROP_FLY);
		SetLineBlocking (LADDER_FRONT, BLOCK_NOTHING);
		SetLineBlocking (LADDER_BACK, BLOCK_NOTHING);

		if (ladder)
		{
			if (!down) ThrustThing (128, 8);

			ladder = 0;
		}
	}
}
This is the code used in Knee Deep In ZDoom (Z1M3). No underwater reverb, no drowning, etc. Maybe this could serve as a viable alternative.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49225
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: A way to disable the underwater reverb of a 3D floor

Post by Graf Zahl »

Hacks like this is what commonly breaks mods.
User avatar
Misery
Posts: 158
Joined: Sun Nov 04, 2018 4:57 pm

Re: A way to disable the underwater reverb of a 3D floor

Post by Misery »

Graf Zahl wrote:Hacks like this is what commonly breaks mods.
It would really break the game? Isn't underwater reverb just a boolean?
User avatar
Rachael
Posts: 13921
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her
Contact:

Re: A way to disable the underwater reverb of a 3D floor

Post by Rachael »

He isn't talking about that. He's talking about using underwater sectors in a way they clearly weren't made for. And while I can't think of anything that is likely to break anytime soon due to using underwater sectors for ladders, it still has a whole host of problems and additional consequences that obviously the map author did not consider, and if GZDoom ever does expand the concept of underwater any more than it already has, his mod would be impacted by those decisions as well.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49225
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: A way to disable the underwater reverb of a 3D floor

Post by Graf Zahl »

Just an example: Imagine we decide to add some view warping for underwater sectors. That would also trigger on the ladder - which is clearly not expected. So we'd have to add the next exception - but since this is an old mod it won't have that feature toggled off.
Post Reply

Return to “Closed Feature Suggestions [GZDoom]”