ZoriaRPG

Compass Beep Function for 2.55

Mar 3rd, 2019
272
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.41 KB | None | 0 0
  1. void beep()
  2. {
  3.     bool dosfx  = false;
  4.     if ( Screen->HasItem )
  5.     {
  6.         itemdata id = Game->LoadItemData(Screen->item);
  7.         switch(id->Family)
  8.         {
  9.             case IT_KEY: dosfx = true; break;
  10.             case IT_LKEY: dosfx = true; break;
  11.             case IT_BOSSKEY: dosfx = true; break;
  12.             default: break;
  13.         }
  14.         if ( dosfx ) Game->PlaySound(SFX_BEEP);
  15.     }
  16. }
Add Comment
Please, Sign In to add comment