| 
    
    
    
      
       Note: You must be registered in order to post a reply.
  
      
       
     | 
   
 
  
    
      
        
          
            
              
                
               
              
                | kingkirb | 
                Posted - Jun 21 2006 : 3:09:31 PM  Sorry im being a pest with all these topics! I have started adding some very basic .wav sounds to my game. To do this i am using a module containing
  Option Explicit Declare Function sndPlaySound Lib "winmm.dll" Alias "sndPlaySoundA" (ByVal lpszSoundName As String, ByVal uFlags As Long) As Long Global Const SND_ASYNC = &H1
  and then to play the sounds i use the code
  rc = sndPlaySound(App.Path & "\Boss Theme.wav", SND_ASYNC) (boss theme being the name of the sound file)
  My problem is that the sound plays fine and i can stop it when i want by playing the victory sound but if the player is still fighting the boss and the sound runs out it stops and i dont know how to loop the sound until the boss dies. Has anyone any ideas???
  Thanks J(Kingkirb)
  | 
               
              
                
               
              
                | kingkirb | 
                Posted - Aug 11 2006 : 09:29:04 AM  thanks that works perfectly. Sorry my reply is so late i have major ISP problems. J kingkirb | 
               
              
                | PW7962 | 
                Posted - Jun 21 2006 : 5:06:20 PM  add this in the declarations:
  Public Const SND_LOOP = &H8
  Then call sndPlaySound(App.path & "\Boss Theme.wav", SND_ASYNC + SND_LOOP)
  I did not test this but I believe that is how you can make it loop. | 
               
             
           | 
         
       
       
     | 
   
 
  
    
      
        
          | VBGamer | 
          ©  | 
            | 
         
       
     | 
   
 
 | 
 |