assuming you have already loaded the sound (ie wheelspinsound=loadsound("something.wav") outside of your main
loop then on the first frame that the wheels start spinning, or when the user pulls the slot machine arm do this:
wheelspinchannel=playsound(wheelspinsound)
then when the wheels stop spinning run the command if soundplaying(wheelspinchannel)<>0 then stopchannel(wheelspinchannel)
loop then on the first frame that the wheels start spinning, or when the user pulls the slot machine arm do this:
wheelspinchannel=playsound(wheelspinsound)
then when the wheels stop spinning run the command if soundplaying(wheelspinchannel)<>0 then stopchannel(wheelspinchannel)