Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Heretic: HHE end-of-episode flat renaming clashes with animated flats #1567

Open
ETTiNGRiNDER opened this issue Jan 2, 2023 · 3 comments
Open

Comments

@ETTiNGRiNDER
Copy link

Background

Version of Chocolate Doom: built from Git repository 2023-01-02

Operating System and version: GNU/Linux (MX-19.4 "patito feo")

Game: Heretic

Any loaded WADs and mods (please include full command line):
chocolate-heretic -hhever 1.3 -deh e2end.hhe

Bug description

Observed behavior:
Startup halts with the following error:
P_InitPicAnims: bad cycle from FLAT516 to FLATHUH4

Expected behavior:
This patch should change the flat displayed behind the end-of-episode text for E2, and not touch animation cycles.
A similar patch for E1 (which works with both the original HHE and under chocolate, presumably since the E1 default flat isn't from an animation cycle) is also attached.

end-flat-hhes.zip

@turol
Copy link
Member

turol commented Jan 5, 2023

In the code it's defined as animated:
https://github.com/chocolate-doom/chocolate-doom/blob/master/src/heretic/p_spec.c#L184

I'm not sure why since it doesn't look like it animates or it's really subtle. But changing the endname without also changing startname so they're not contiguous will probably break something. You should fix the .deh to change that, I don't know how.

@fabiangreffrath
Copy link
Member

The FLATHUH1 flat is used as both the start point of an animation sequence and as the background for the Episode 2 intermission:

{false, "FLATHUH4", "FLATHUH1", 8}, // Super Lava

finaleflat = DEH_String("FLATHUH1");

In Boom (but not Vanilla Doom) this problem was circumvented by introducing separate BEX pointers for the intermission background flats, e.g. bgflate1of bgflat06.

I guess you'll have to apply another HHE rule to change the FLATHUH4 flat to point past your new FLATHUH1 flat.

@ETTiNGRiNDER
Copy link
Author

HHE should use separate pointers for strings in general. That's how the program works, it shouldn't be touching the string anywhere but the intermission flat listing when given those offsets.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants