/* Alternate ammo display 1.0, by Violet CLM http://www.jazz2online.com/snippets/130/alternate-ammo-display/ */ const array gunProfilePics = {0, 83+20+33, 25, 29, 34, 49, 57, 59, 62, 68}; const array gunPoweredProfilePics = {0, 18, 24, 28, 33, 48, 56, 59, 61, 67}; bool onDrawAmmo(jjPLAYER@ play, jjCANVAS@ screen) { uint8 an; if (play.powerup[WEAPON::CURRENT]) an = gunPoweredProfilePics[play.currWeapon]; else an = gunProfilePics[play.currWeapon]; if (play.currWeapon == WEAPON::BLASTER && play.charCurr == CHAR::SPAZ) ++an; for (int8 i = 0; i < play.ammo[WEAPON::CURRENT]; ++i ) screen.drawSprite(jjSubscreenWidth - 20 - i*(jjSubscreenWidth/128), jjSubscreenHeight - 20, 0, an, (jjRenderFrame+i)/5, 0, (i+1 == play.ammo[WEAPON::CURRENT]) ? SPRITE::NORMAL : SPRITE::TRANSLUCENT); return true; }