Skip to content

Conversation

@DinnerCalzone
Copy link

This constructor creates a new Layer by copying the contents of another Layer. This is used in SpriteSystem.CopySprite() to copy the contents of one sprite to another. Currently, the constructor checks if the source's Shader is null, and if it isn't it copies the source's Shader, UnShaded, and ShaderPrototype variables. However, since Shader is meant to be null whenever a layer is unshaded, it doesn't properly copy over the necessary information for rendering unshaded layers. This moves the UnShaded and ShaderPrototype variable setting out of the Shader null check.

Resolves space-wizards/space-station-14#41948

Before fix:

image

After fix:

image

@DinnerCalzone DinnerCalzone changed the title Fix Layer constructor in SpriteComponent no properly copying unshaded sprite layers Fix Layer constructor in SpriteComponent not properly copying unshaded sprite layers Jan 5, 2026
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.

Chameleon items do not properly imitate unshaded layers of a sprite

1 participant