Author Topic: Sounds with a script?  (Read 462 times)

I am trying to make a / command to make a sound to everyone on my server
How will i do it?

I'd like a answer on that too.

Without wax,
Tickle.

Code: [Select]
function serverCmdSoundAll(%client,%sound)
{
   for(%i = 0;%i < ClientGroup.getCount(); %i++)
   {
      %c = ClientGroup.getObject(%i);
      if(!isObject(%sound) || %sound.getClassName() !$= "AudioProfile")
         return;
      if(%sound.description.isLooping)
         return;
      %c.play2d(%sound);
   }
}
So you would have to type "/SoundAll someAudioDatablock"
Referenced Space Guy's Event_playSound mod for this.

k now thanks
Does anyone know the datablock for "Admin granted" sound?

Block_Admin_Sound
I'm pretty sure. That may just be if you have Space Guy's Sound_Blockland file.

k now thanks
Does anyone know the datablock for "Admin granted" sound?
Just do this:
messageAll('MsgAdminForce', "text");

If just want a beep but no text, make "text" to ""