Original author: Pierre Sarrazin. Public-domain library and demo. Source: http://sarrazip.com/dev/cardgame-0.1.15.tar.gz Archive SHA-256: ca706dddd96fec63b829f8958c2e47485b0e1166129d45fda0b6369404c1bb54
29 lines
377 B
C
29 lines
377 B
C
#include "cardgame.h"
|
|
|
|
|
|
static byte *
|
|
work(void)
|
|
{
|
|
byte *dest = getCurrentCharPos();
|
|
for (byte i = 0; i < PIXEL_ROWS_PER_GLYPH; ++i)
|
|
{
|
|
*dest ^= 0xFF;
|
|
dest += BYTES_PER_SCREEN_ROW;
|
|
}
|
|
return dest;
|
|
}
|
|
|
|
|
|
void
|
|
invertCharAtCursorExceptRowBelowGlyph(void)
|
|
{
|
|
work();
|
|
}
|
|
|
|
|
|
void
|
|
invertCharAtCursor(void)
|
|
{
|
|
*work() ^= 0xFF; // row below glyph
|
|
}
|