local Q=script.Parent.AudioPlayerGui.Song local x=carSeat.Audio vol=1 function changeSong()local Q=carSeat.Audio.EqualizerSoundEffect if onOff.Text=="\079\085\084"then carSeat.AuidoPlayerEvent:FireServer(1,4)onOff.Text="\073\078"else carSeat.AuidoPlayerEvent:FireServer(2,4)onOff.Text="\079\085\084"end end function playSong()local x=script.Parent.AudioPlayerGui.TextBox.Text carSeat.AuidoPlayerEvent:FireServer(x,1)Q.Text=((game:GetService("\077\097\114\107\101\116\112\108\097\099\101\083\101\114\118\105\099\101")):GetProductInfo(x)).Name end function stopSong()carSeat.AuidoPlayerEvent:FireServer(nil,2)end function volUp()if vol+.1<=5 then vol=vol+.1 carSeat.AuidoPlayerEvent:FireServer(vol,3)script.Parent.AudioPlayerGui.Vol.Text=tostring(vol*100).."\037"end end function volDown()if vol-.1>=0 then vol=vol-.1 carSeat.AuidoPlayerEvent:FireServer(vol,3)script.Parent.AudioPlayerGui.Vol.Text=tostring(vol*100).."\037"end end ChangeButton.MouseButton1Click:connect(function()changeSong()end)VolUpButton.MouseButton1Click:connect(function()volUp()end)VolDownButton.MouseButton1Click:connect(function()volDown()end)PlayButton.MouseButton1Click:connect(function()playSong()end)PauseButton.MouseButton1Click:connect(function()stopSong()end)
--local Screen = carSeat.Parent.AudioPlayerScreen.SurfaceGui <-- soon
local Song = script.Parent.AudioPlayerGui.Song
local Audio = carSeat.Audio

vol = 1

function changeSong()
	local effect = carSeat.Audio.EqualizerSoundEffect
	if onOff.Text == "OUT" then
		carSeat.AuidoPlayerEvent:FireServer(1, 4)
		onOff.Text = "IN"
	else
		carSeat.AuidoPlayerEvent:FireServer(2, 4)
		onOff.Text = "OUT"
	end
end

function playSong()
	local id = script.Parent.AudioPlayerGui.TextBox.Text
	carSeat.AuidoPlayerEvent:FireServer(id, 1)
	--Screen.Song.Text = game:GetService("MarketplaceService"):GetProductInfo(id).Name
	Song.Text = game:GetService("MarketplaceService"):GetProductInfo(id).Name
	--Screen.ID.Text = id
end

function stopSong()
	carSeat.AuidoPlayerEvent:FireServer(nil, 2)
end

function volUp()
	if vol + 0.1 <= 5 then
		vol = vol + 0.1
		carSeat.AuidoPlayerEvent:FireServer(vol, 3)
		script.Parent.AudioPlayerGui.Vol.Text = tostring(vol * 100) .. "%"
		--Screen.Vol.Text = tostring(vol*100) .. "%"
	end
end

function volDown()
	if vol - 0.1 >= 0 then
		vol = vol - 0.1
		carSeat.AuidoPlayerEvent:FireServer(vol, 3)
		script.Parent.AudioPlayerGui.Vol.Text = tostring(vol * 100) .. "%"
		--Screen.Vol.Text = tostring(vol*100) .. "%"
	end
end

ChangeButton.MouseButton1Click:connect(function()
	changeSong()
end)

VolUpButton.MouseButton1Click:connect(function()
	volUp()
end)

VolDownButton.MouseButton1Click:connect(function()
	volDown()
end)

PlayButton.MouseButton1Click:connect(function()
	playSong()
end)

PauseButton.MouseButton1Click:connect(function()
	stopSong()
end)
