Scripting/Squirrel/Functions/Player.PlaySound

From Vice City Multiplayer
Revision as of 21:00, 17 December 2018 by Sseebbyy (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
Caution icon
This wiki is using an old backup from 2020
Some information may be old/missing

This function will play a sound for a specific player

Syntax

Player.PlaySound( sound )

Arguments

  • instance Player - The player to play sound for
  • int sound - The sound ID

Example

function OnPlayerCommand( player,cmd , text )
{
     if ( cmd == "sound" )
     {
          player.PlaySound( 30 );
     }
}

Related Functions

Player Game Functions

These functions exist for compatibility with the R2 Squirrel server.