extern bool teleport_barrier(int m_idx);
extern bool magic_barrier(int m_idx);
extern bool multiply_barrier(int m_idx);
-
static MCI_OPEN_PARMS mop;
static char mci_device_type[256];
+int current_music_type = 0;
+int current_music_id = 0;
+
#endif /* USE_MUSIC */
#endif /* USE_MUSIC */
/* Sound disabled */
+
if(!use_music) return (1);
/* Illegal sound */
/* No sample */
if (i == 0)
{
- mciSendCommand(mop.wDeviceID, MCI_STOP, 0, 0);
- mciSendCommand(mop.wDeviceID, MCI_CLOSE, 0, 0);
+ //mciSendCommand(mop.wDeviceID, MCI_STOP, 0, 0);
+ //mciSendCommand(mop.wDeviceID, MCI_CLOSE, 0, 0);
return (1);
}
break;
}
+ if(current_music_type == n && current_music_id == v)
+ {
+ return (0);
+ }
+ current_music_type = n;
+ current_music_id = v;
+
#ifdef WIN32
mop.lpstrDeviceType = mci_device_type;
if (!use_music) return 1;
/* Make a sound (if allowed) */
- return Term_xtra(type , val);
+ return Term_xtra(type, val);
}
/*
if(dungeon_type)
{
- if(play_music(TERM_XTRA_MUSIC_DUNGEON, dungeon_type))
+ if(p_ptr->feeling == 2) play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_DUN_FEEL2);
+ else if(p_ptr->feeling >= 3 && p_ptr->feeling <= 5) play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_DUN_FEEL1);
+ else
{
- if(p_ptr->feeling == 2) play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_DUN_FEEL2);
- else if(p_ptr->feeling >= 3 && p_ptr->feeling <= 5) play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_DUN_FEEL1);
- else
+ if(play_music(TERM_XTRA_MUSIC_DUNGEON, dungeon_type))
{
if(dun_level < 40) play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_DUN_LOW);
else if(dun_level < 80) play_music(TERM_XTRA_MUSIC_BASIC, MUSIC_BASIC_DUN_MED);
int snipe_type = SP_NONE;
bool reset_concent = FALSE; /* Concentration reset flag */
bool is_fired = FALSE;
+