#4794 - Saj - Wed Apr 09, 2003 9:44 pm
Greetings,
I'm trying to display several (16-colour) sprites. How do I set up different palettes for them?
I know I have to set attribute 2 but I can't find any source code on this matter( everyone seems to be using 256 colour sprites :( )
Also, I know the first value for attribute 2 is the character name but what do I have to 'OR' with it? btw, Im using Pern's headers.
Some example code would help me a lot.
Thanks.
bonus question for 50 points - what does this do?
_________________
---------------------------------------------------
Click here to give free food to starving animals.
--------------------------------------------------
Last edited by Saj on Wed Apr 09, 2003 9:54 pm; edited 1 time in total
I'm trying to display several (16-colour) sprites. How do I set up different palettes for them?
I know I have to set attribute 2 but I can't find any source code on this matter( everyone seems to be using 256 colour sprites :( )
Code: |
sprites[1].attribute0 = COLOR_16 | SQUARE | ghost.y; sprites[1].attribute1 = SIZE_8 | ghost.x; sprites[1].attribute2 = ?; |
Also, I know the first value for attribute 2 is the character name but what do I have to 'OR' with it? btw, Im using Pern's headers.
Some example code would help me a lot.
Thanks.
bonus question for 50 points - what does this do?
Code: |
pSlot->attribute0 = attribute0; pSlot->attribute1 = attribute1; pSlot->attribute2 = attribute2; |
_________________
---------------------------------------------------
Click here to give free food to starving animals.
--------------------------------------------------
Last edited by Saj on Wed Apr 09, 2003 9:54 pm; edited 1 time in total