Skip to content

Sprite z-ordering #114

@xaviershay

Description

@xaviershay

Currently to control z-ordering I remove a sprite from a scene then re-add it to place it on top (example). This is kind of hackish.

Did you envision this library handling such a thing? I might have a crack at it if you're interested. I was thinking of adding a z-attr to Sprite then sorting by that before drawing at https://github.com/PistonDevelopers/sprite/blob/master/src/scene.rs#L84

Thanks!
Xavier

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions