Skip to content

Hey, Sprites are backwards and not in correct bit orders #36

@GIGGLES-PROJECTS

Description

@GIGGLES-PROJECTS

Hey, how's it going. The application has a hiccup when exporting. It gives users 8 bit chunks for the tiles when the TILE struct through devkitPro and TONC require an array of 8 x 32bit values. Moreover the values that the program spits out are backwards. I'm new to coding so I don't understand where I can go to rectify the problem.

Essentially, all tiles/sprites must be: typedef struct { u32 data[8]; } TILE, TILE4;
Also the bits have to be mirrored opposite to the image they want to make

The system expects something like this. It's a number 4, using palette 8. It's written backwards. When it gets copied in to the GBA it'll read correctly
// 4
0x00000000,
0x08880880,
0x08880880,
0x08888880,
0x08888000,
0x08888000,
0x08888000,
0x00000000,

The programs output looks like this.
// Sprite : S5
// Size : 1x1 = 1 tiles
// Tile #4
0x00,0x00,0x00,0x00,
0x10,0x11,0x11,0x01,
0x00,0x11,0x11,0x01,
0x10,0x11,0x11,0x01,
0x00,0x11,0x11,0x01,
0x00,0x11,0x11,0x01,
0x10,0x11,0x11,0x01,
0x00,0x00,0x00,0x00,

Thanks for your time. Have a good one.

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