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

Add support for fire textures in ANIMDEFS #2680

Merged
merged 2 commits into from
Sep 12, 2024

Conversation

Cacodemon345
Copy link
Contributor

@Cacodemon345 Cacodemon345 commented Aug 19, 2024

This PR adds support for defining fire textures in ANIMDEFS.

Syntax is:
FIRETEXTURE tics

followed by a series of either "palette index" or "color red green blue alpha".

Example (converted from Legacy of Rust's SKYDEFS definition):

firetexture FIRETEST tics 2.00025
	palette 0
	palette 47
	palette 191
	palette 187
	palette 235
	palette 234
	palette 232
	palette 167
	palette 166
	palette 165
	palette 223
	palette 221
	palette 220
	palette 219
	palette 217
	palette 216
	palette 215
	palette 214
	palette 213
	palette 164
	palette 163
	palette 162
	palette 161
	palette 160
	palette 231
	palette 230
	palette 229
	palette 228
	palette 227
	palette 226
	palette 225
	palette 224

Copy link
Member

@coelckers coelckers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please make this work in the software renderer as well.

@Cacodemon345
Copy link
Contributor Author

Is implementing Get8BitPixels enough for the software renderer? If so, it has been done now.

@prof-hastig
Copy link
Contributor

Why don't you just test it?
Enabling both modes of the software renderer is not that hard...

@Cacodemon345
Copy link
Contributor Author

It only works with the hardware renderer and the non-truecolor software renderer. On truecolor software renderer it remains frozen.

@prof-hastig
Copy link
Contributor

My suggestion here would be to look how warped flats force their update and replicate it for this texture.

@Cacodemon345
Copy link
Contributor Author

Fixed for truecolor software renderer.

Copy link
Member

@coelckers coelckers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hardware and paletted software renderer are working - but for the true color software renderer the black background is transparent and causes HOM.

Does this texture need the transparency for black? If not, make it fully opaque.

@Cacodemon345
Copy link
Contributor Author

It needs the black parts to be fully transparent otherwise it will be rendered useless for dual sky parallax effects.

@Cacodemon345
Copy link
Contributor Author

As an addendum: Specifying the first color with the color syntax with the alpha part maxed out (color 0 0 0 255) should disable transparency.

@coelckers
Copy link
Member

It may be a bug in the true color software renderer, but I don't really know how to address it.

@Cacodemon345
Copy link
Contributor Author

Does this happen with the sky or just linedefs? At least I could attempt fixing the truecolor sky renderer but I'm not sure about anything else.

@Cacodemon345
Copy link
Contributor Author

It happens with the sky, not linedefs. I have no idea why it happens; the sky drawer code's not easy to read.

@Cacodemon345
Copy link
Contributor Author

Defining an opaque black color as the first one indeed deals with the HOM problem.

@Cacodemon345
Copy link
Contributor Author

The HOM problem should be addressed now.

@coelckers
Copy link
Member

Seems to work now

@coelckers coelckers merged commit 38290b6 into ZDoom:master Sep 12, 2024
9 checks passed
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

Successfully merging this pull request may close these issues.

3 participants