Author Topic: sound  (Read 1437 times)

Kevin

  • Newbie
  • *
  • Posts: 32
  • Karma: +9/-35
    • View Profile
    • www.edgarcain.zz.mu
sound
« on: January 27, 2013, 06:43:01 pm »
hi guys please help I need a script to start the game when I leave I want sound please help 8)
Kevin  ;)

Mido_Pop

  • Full Member
  • ***
  • Posts: 168
  • Karma: +6/-20
  • The_Pops ( War )
    • View Profile
Re: sound
« Reply #1 on: January 27, 2013, 08:07:28 pm »
function onScriptLoad()
{
     spawn_Sound <- null;
}

function onClientRequestClass( player )
{
    if ( !spawn_Sound )
    {
         spawn_Sound = FindSound( "welcome.mp3" );
         if ( spawn_Sound )
         {
              spawn_Sound.Open();
              spawn_Sound.Play();
                       
              return 1;
         }
    }
    else
    {
             spawn_Sound.Open();
         spawn_Sound.Play();
                 
         return 1;
    }
}

~~~~~~~~~~~~~~~~

Script :<script file="welcome.nut" client="1"/>
          <sound file="welcome.mp3"/>

. :P
« Last Edit: January 27, 2013, 08:11:25 pm by mido_pop »



Kevin

  • Newbie
  • *
  • Posts: 32
  • Karma: +9/-35
    • View Profile
    • www.edgarcain.zz.mu
Re: sound
« Reply #2 on: February 04, 2013, 08:43:37 pm »
Thanks for your help I worked great
Kevin  ;)

SugarD

  • Argonath RPG Dev/Manager
  • Tester
  • Sr. Member
  • ****
  • Posts: 820
  • Karma: +37/-75
  • STOP IN THE NAME OF THE COLESLAW!
    • View Profile
    • Clan Xperience
Re: sound
« Reply #3 on: April 06, 2013, 09:32:50 pm »
Moved to the correct board.

Issue resolved, topic locked. :)

 

© Liberty Unleashed Team.