Advertisement
Shiny_

Untitled

Jul 19th, 2014
290
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.47 KB | None | 0 0
  1. -- Serwer:
  2. addCommandHandler("whatislove", function()
  3.     triggerClientEvent(root, "PlaySong", root)
  4. end)
  5.  
  6. -- Klient:
  7. function Sound()
  8.     -- zmienna song przypisana do playSound:
  9.         local song = playSound("http://alldev.eu/whatislove.mp3")
  10.     -- Maksymalna głośność = 1
  11.         setSoundVolume(song, 1)
  12.         -- Maksymalny dystans = 100
  13.         setSoundMaxDistance(song, 100)
  14. end
  15.  
  16. addEvent("PlaySong", true)
  17. addEventHandler("PlaySong", getRootElement(), Sound)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement