Skip to content

colkind uses BBoxMode #12

@ithinkandicode

Description

@ithinkandicode

Atm colkind uses BBoxMode, so sprites like this:

swing-1-rectangle

Are exported like this:

swing-2-ellipses

In this example, because the BBoxMode is 2, colkind is also set to 2

Precise   - <colkind>0</colkind>
Rectangle - <colkind>1</colkind>
Ellipse   - <colkind>2</colkind>
Diamond   - <colkind>3</colkind>

Not sure how to fix this as UMT can't tell what the mask shape is

But it does know if the sprite uses a separate collision mask (values here), so:

  • if sprite.SepMasks == 1 (Precise), <colkind> = 0
  • if sprite.SepMasks == 0 (AxisAlignedRect ie. Rectangle), <colkind> = 1

It's not perfect as Precise is also used for Ellipses and Diamond. But we know at least when Rectangle is being used, and Precise is probably a safe default in any other case.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions