Music Admin Commands Error?
My script will not work for some reason I asked my friends we could not find a way how.
It is suppost to change the song when you say ".m roll" then song id it will change it to the song id.
01 | function onChatted(msg, plr) |
08 | plr:GetRankInGroup( 2706982 ) = = 254 ; |
09 | plr:GetRankInGroup( 2706982 ) = = 253 ; |
10 | plr:GetRankInGroup( 2706982 ) = = 252 ; |
11 | plr:GetRankInGroup( 2706982 ) = = 251 ; |
14 | plr:GetRankInGroup( 2706982 ) = = 250 ; |
15 | plr:GetRankInGroup( 2706982 ) = = 249 ; |
18 | plr:GetRankInGroup( 2706982 ) = = 28 ; |
19 | plr:GetRankInGroup( 2706982 ) = = 26 ; |
20 | plr:GetRankInGroup( 2706982 ) = = 25 ; |
26 | if msg = = ".m play " then |
27 | if Owner [ plr.Name ] or Admin or Mod or LowerMod or VIP then |
28 | game.Workspace.Music.Sound.SoundId = "0" |
29 | game.Workspace.Music.MusicPlayer.Disabled = true |
30 | game.Workspace.Music.Sound:Stop() |
32 | local sound = msg:sub( 9 ) |
33 | game.Workspace.Music.PlayerSound.SoundId = sound |
35 | wait(game.Workspace.Music.PlayerSound.TimeLength) |
36 | game.Workspace.Music.PlayerSound:Stop() |
41 | game.Players.PlayerAdded:connect( function (plr) |
42 | plr.Chatted:connect( function (msg) onChatted(msg, plr) end ) |
Could anyone fix it?