Skip to content

StopChannel

Narta Xaymar Dirks edited this page Oct 28, 2026 · 6 revisions

Blitz3DBlitzPlusBlitzBasic

StopChannel

StopChannel:Void channel:Int32
Parameter Mode Type Default Description
channel In Int32 required A channel handle from PlaySound or PlayMusic.

Description

Stops a channel and releases it. The handle can not be used afterwards, and commands that are given a channel that has ended are ignored.

Differences

  • A debug build (-d) stops the program when the channel was never given out. A channel that is over is fine everywhere, see Debug handle checks.

Examples

; MakeBeep writes beep.wav, see the LoadSound example for the code.
Local snd = LoadSound("beep.wav")
LoopSound snd
Local ch = PlaySound(snd)
Delay 700
StopChannel ch
Print ChannelPlaying(ch)

Related Commands

ChannelPan, ChannelPitch, ChannelPlaying, ChannelVolume, PauseChannel, ResumeChannel

Home · Command Index



Differences
Language Features
BlitzBasic
Blitz3D
BlitzPlus

Clone this wiki locally