Almost anything is possible!
Here's what I think you are looking for.
void DarkGDK(void) {
dbSyncOn();
dbSyncRate(60);
dbLoadImage("gunflash.png", 1);
dbSprite(1, 0, 0, 1);
dbSizeSprite(1, 500, 500);
dbSetSpriteAlpha(1, 0);
while(LoopGDK()) {
dbCLS();
static int trans = 0;
static int iter = 0;
if(dbMouseClick() == 1) {
if(trans < 256 && iter != -70)
iter = 70;
else if(trans > -1)
iter = -70;
else
iter = 70;
trans += iter;
dbSetSpriteAlpha(1, trans);
}
else if(trans != 0) {
trans = (trans < 0) ? 0 : trans - 12;
dbSetSpriteAlpha(1, trans);
}
dbSprite(1, 0, 0, 1);
dbText(0, 0, dbStr(trans));
dbSync();
}
return;
}
Your_Health = (My_Mood == HAPPY) ? 100 : NULL;