PlaySoundFrontEnd: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
{{Needs_Checking|
*playsound function needs sound list - I (Talidan) have found one though i need clarification on how to organise it...need to speak with ChrML
*Creation functions should have their corresponding XML formats listed on the their page (createVehicle ( ... ) is <vehicle ...>, createRadarArea ( ... ) is <radararea ...>, etc).|Erorr404}}
__NOTOC__  
__NOTOC__  
This function plays a sound for the specified player
This function plays a sound for the specified player

Revision as of 04:23, 10 September 2006

Dialog-information.png This article needs checking.

Reason(s):
  • playsound function needs sound list - I (Talidan) have found one though i need clarification on how to organise it...need to speak with ChrML
  • Creation functions should have their corresponding XML formats listed on the their page (createVehicle ( ... ) is <vehicle ...>, createRadarArea ( ... ) is <radararea ...>, etc).


This function plays a sound for the specified player

Syntax

bool playSound ( player player, sound )   

Required Arguments

  • player: The player you want the sound to play for.
  • sound: A whole integer specifying the sound id to play.

Returns

Returns true if the sound was successfully played , false otherwise.

Example

addCommandHandler ( "onPlayerSpawn", root, "onPlayerSpawn" )
function onPlayerSpawn ( player )
  playSound ( player, 16 )
end

See Also