Allow multiple defines for Player.MorphWeapon

Remember, just because you request it, that doesn't mean you'll get it.

Moderator: GZDoom Developers

User avatar
kevansevans
Spotlight Team
Posts: 429
Joined: Tue Oct 05, 2010 12:04 am
Graphics Processor: nVidia with Vulkan support

Allow multiple defines for Player.MorphWeapon

Post by kevansevans »

With current behavior, if you define multiple weapons in a morph class, it will only grant the last defined weapon. In this example:

Code: Select all

Player.MorphWeapon "WeaponA";
Player.MorphWeapon "WeaponB";
Player.MorphWeapon "WeaponC";
The player will only be granted WeaponC because it is defined last. The desired behavior should be that all three weapons (or more) are granted.
User avatar
Rachael
Posts: 13793
Joined: Tue Jan 13, 2004 1:31 pm
Preferred Pronouns: She/Her

Re: Allow multiple defines for Player.MorphWeapon

Post by Rachael »

With the existing morph system this likely would be a lot of work. Having a morph active will block you from switching weapons, and this is by design from the original Heretic/Hexen implementation of it.
User avatar
kevansevans
Spotlight Team
Posts: 429
Joined: Tue Oct 05, 2010 12:04 am
Graphics Processor: nVidia with Vulkan support

Re: Allow multiple defines for Player.MorphWeapon

Post by kevansevans »

I take it that this weapon limitation isn't the same sort of list of weapons that a default player uses? I imagine it would be an easier path if treated so, as having a singular weapon in this list (as in the case of heretic/hexen) would behave exactly the same as denying the ability to switch weapons.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49183
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: Allow multiple defines for Player.MorphWeapon

Post by Graf Zahl »

I really prefer not to touch the morph code - it was one of those features that in hindsight should never have been added in their current form.
User avatar
kevansevans
Spotlight Team
Posts: 429
Joined: Tue Oct 05, 2010 12:04 am
Graphics Processor: nVidia with Vulkan support

Re: Allow multiple defines for Player.MorphWeapon

Post by kevansevans »

That's understandable, even working with it in ZScript feels super hacky. I'd volunteer to figure it out if I was any decent with C++. Is any of the morph code exposed in ZScript? I couldn't find anything poking around.

EDIT: Found some parts of it, but definitely nothing accessible that I can change this behavior and offer it as a pull request. Oh well! I'll take the No on this one, maybe bump it if I ever decided to dig my teeth into the deeper source.

Return to “Feature Suggestions [GZDoom]”