The Dink Network

Reply to Re: How to keep a sound play in the background?

If you don't have an account, just leave the password field blank.
Username:
Password:
Subject:
Antispam: Enter Dink Smallwood's last name (surname) below.
Formatting: :) :( ;( :P ;) :D >( : :s :O evil cat blood
Bold font Italic font hyperlink Code tags
Message:
 
 
December 18th 2009, 05:29 AM
sob_scorpy.gif
DinkDude95
Peasant He/Him Australia
The guy with the cute D-Mod. 
Try something like this:

void main ( void )
{
 int &chk_map;
sndloop:
  playsound(##, #####, 0, 0, 0);
  wait(length of sound);
  &chk_map = &player_map;
  if (&chk_map != &player_map)
	kill_this_task();
  goto sndloop;
}


Attach this to every screen you want the ocean/wind blow on and it should work.

Just be sure to change the ##'s and the 'length of sound'.

EDIT: I'm pretty sure you can attach it to any sprites or just the base of the screen. What I've done when I do this, is:

int &lala = create_sprite(0, 0, 0, 0, 0);
sp_script(&lala, "script");