//
//    SNDMOD HEADER AND DEF'S
//

#define     S_THUNDER1              0
#define     S_THUNDER2              1
#define     S_THUNDER3              2
#define     S_THUNDER4              3
#define     S_WINDLOOP1             4
#define     S_WAVELOOP1             5
#define     S_LAVALOOP1             6
#define     S_FIRELOOP1             7
#define     S_STONELOOP1            8
#define     S_BATSLOOP              9
#define     S_PLRWEAPON0            10
#define     S_PLRWEAPON1            11
#define     S_PLRWEAPON2            12
#define     S_PLRWEAPON3            13
#define     S_PLRWEAPON4            14
#define     S_GOBLIN1               15
#define     S_GOBLIN2               16
#define     S_GOBLIN3               17
#define     S_GOBPAIN1              18
#define     S_GOBPAIN2              19
#define     S_GOBDIE1               20
#define     S_GOBDIE2               21
#define     S_GOBDIE3               22
#define     S_KSNARL1               23
#define     S_KSNARL2               24
#define     S_KSNARL3               25
#define     S_KSNARL4               26
#define     S_KPAIN1                27
#define     S_KPAIN2                28
#define     S_KDIE1                 29
#define     S_KDIE2                 30
#define     S_DEMON1                31
#define     S_DEMON2                32
#define     S_DEMON3                33
#define     S_DEMON4                34
#define     S_DEMON5                35
#define     S_DEMONDIE1             36
#define     S_DEMONDIE2             37
#define     S_MSNARL1               38
#define     S_MSNARL2               39
#define     S_MSNARL3               40
#define     S_MSNARL4               41
#define     S_MPAIN1                42
#define     S_MDEATH1               43
#define     S_DRAGON1               44
#define     S_DRAGON2               45
#define     S_DRAGON3               46
#define     S_RIP1              	  47
#define     S_RIP2              	  48
#define     S_RIP3              	  49
#define     S_SKELHIT1          	  50
#define     S_SKELHIT2          	  51
#define     S_SKELETONDIE           52
#define     S_GUARDIAN1         	  53
#define     S_GUARDIAN2         	  54
#define     S_GUARDIANPAIN1     	  55
#define     S_GUARDIANPAIN2     	  56
#define     S_GUARDIANDIE           57
#define     S_WISP              	  58
#define     S_WISP2             	  59
#define     S_SPLASH1               60
#define     S_SPLASH2               61
#define     S_SPLASH3               62
#define     S_SPLASH4               63
#define     S_SPLASH5               64
#define     S_SPLASH6               65
#define     S_WILLOWDIE         	  66
#define     S_FATWITCHDIE           67
#define     S_JUDY1             	  68
#define     S_JUDY2             	  69
#define     S_JUDY3             	  70
#define     S_JUDY4             	  71
#define     S_JUDYDIE               72
#define     S_SKULLWITCH1           73
#define     S_SKULLWITCH2           74
#define     S_SKULLWITCH3           75
#define     S_SKULLWITCHDIE     	  76
#define     S_GRONDEATHA        	  77
#define     S_GRONDEATHB        	  78
#define     S_GRONDEATHC        	  79
#define     S_CHAIN1                80
#define     S_FLAME1                81
#define     S_GRONPAINA        	  82
#define     S_GRONPAINB        	  83
#define     S_GRONPAINC        	  84
#define     S_CLUNK                 85
#define     S_DEMONTHROW            86
#define     S_WITCHTHROW            87
#define     S_DOOR1                 88
#define     S_DOOR2                 89
#define     S_DOOR3                 90
#define     S_CREAKDOOR1            91
#define     S_CREAKDOOR2            92
#define     S_CREAKDOOR3            93
#define     S_STING1                94
#define     S_STING2                95
#define     S_POTION1               96
#define     S_GENTHROW              97
#define     S_GENSWING              98
#define     S_ARROWHIT          	  99
#define     S_WALLHIT1          	  100
#define     S_GONG                  101
#define     S_SPELL1                102
#define     S_FREEZE                103
#define     S_FREEZEDIE             104
#define     S_TRAP1                 105
#define     S_TRAP2                 106
#define     S_RATS1                 107
#define     S_RATS2                 108
#define     S_WINDLOOP2         	  109
#define     S_BREATH1               110
#define     S_BREATH2               111
#define     S_PUSH1             	  112
#define     S_PUSH2             	  113
#define     S_PLRPAIN1			  114
#define     S_PLRPAIN2              115
#define     S_GORE1                 116
#define     S_GORE2                 117
#define     S_GORE1A                118
#define     S_GORE1B                119
#define     S_DEADSTEP          	  120
#define     S_HEARTBEAT         	  121
#define     S_SOFTCHAINWALK     	  122
#define     S_SOFTCREAKWALK     	  123
#define     S_LOUDCHAINWALK     	  124
#define     S_GRATEWALK         	  125
#define     S_SCARYDUDE             126
#define     S_WATERY                127
#define     S_GLASSBREAK1           128
#define     S_GLASSBREAK2           129
#define     S_GLASSBREAK3           130
#define     S_TREASURE1         	  131
#define     S_SWORD1                132
#define     S_SWORD2                133
#define     S_SWORDCLINK1           134
#define     S_SWORDCLINK2           135
#define     S_SWORDCLINK3           136
#define     S_SWORDCLINK4           137
#define     S_SOCK1                 138
#define     S_SOCK2                 139
#define     S_SOCK3                 140
#define     S_SOCK4                 141
#define     S_KOBOLDHIT         	  142
#define     S_SPIDERBITE            143
#define     S_FIREBALL              144
#define     S_WOOD1             	  145
#define     S_CHAINDOOR1            146
#define     S_PULLCHAIN1            147
#define     S_PICKUPAXE         	  148
#define     S_EXPLODE               149
#define     S_SKELSEE               150
#define     S_BARRELBREAK           151
#define     S_WARP              	  152
#define     S_SPELL2                153
#define     S_THROWPIKE         	  154
#define     S_PICKUPFLAG        	  155
#define     S_DROPFLAG          	  156
#define     S_LAUGH             	  157
#define     S_DRINK                 158
#define     S_PAGE                  159
#define     S_BOTTLES               160
#define     S_CRACKING              161
#define     S_PLRDIE1               162
#define	   S_FATLAUGH			  163


#define  MAX_SAMPLES       200
#define  MAX_ACTIVE_SAMPLES   10
#define  MAX_ACTIVE_SONGS     4
//num of array elements in ambsoundarray[]
#define MAX_AMB_SOUNDS       8
#define  MAX_ACTIVE_FXLOOPS   4

#define  MAX_SND_LOOPS        8

#define  DIG_MIDI 2
#define  MIDI     1
#define  DIGI     0

#define  MENUSONG   0
#define  DEATHSONG   1

#define BASE_SONG   0
#define EMB_SONG        1
#define SPICE_SONG  2

#define  WINDSNDBIT        1
#define  WAVESNDBIT        2
#define  WATERSNDBIT       4
#define  LAVASNDBIT        8
#define  GRATESNDBIT       16
#define  CARTSNDBIT        32
#define  FIRE1SNDBIT       64
#define  FIRE2SNDBIT       128

struct ambsounds {
	int soundnum;       //the actual sound number S_x
	int hsound;     //the handle returned by hmi
};

#ifdef SND_CALLER

	//
	//    MIDI SPECIFIC
	//

//midimusic vars

	unsigned char     ActiveSongBits = 0x00;


	struct ambsounds ambsoundarray[] = {
		{ 0,0 },
		{ S_WINDLOOP1,-1 },
		{ S_WINDLOOP2,-1 },
		{ S_WAVELOOP1,-1 },
		{ S_LAVALOOP1,-1 },
		{ S_WATERY,-1 },
		{ S_STONELOOP1,-1 },
		{ S_BATSLOOP,-1 }
	};




	//
	//          GLOBAL VARIABLES
	//
	int     SoundMode;
	int     MusicMode;


#else




extern int  SoundMode,MusicMode;

extern struct ambsounds ambsoundarray[];
extern int lavasnd,batsnd,cartsnd;


#endif



