Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Camera not blurring based on playbackloudness?

Asked by 5 years ago
Edited 5 years ago

Hello, I have a hard question, I think lol, I am trying to make the camera blurred based on playbackloudnes (PBL) I made this question 8 days ago but it wasn't being answered, I have the Link: https://scriptinghelpers.org/questions/87556/camera-blurring-not-working-on-playbackloudness

Script here:

local sound = game.Workspace.Sound
local fire = game.Lighting.Blur ---Blur in the lightning that will activate when its called

while true do
    if sound.IsPlaying then
        local number = (sound.PlaybackLoudness / 100) * (2 + sound.Volume)
        fire.Enabled = true ---Called to activate blur
        fire.Size = NumberSequence.new(number) ---Makes the blur size based on the playbackloudness
    else
        fire.Enabled = false   ---Disable blur
    end
    wait()
end

(I did put this LOCALSCRIPT in: Game > StarterPlayer > StarterPlayerScripts)

I have an error: Players.JustSxript.PlayerScripts.LocalScript:7: attempt to index local 'fire' (a number value) Maybe one of you guys can help me?

Thanks, again.

0
replace NumberSequence.new(number) with number SerpentineKing 3885 — 5y
0
i will test that out JustSxript 36 — 5y
0
Omg thank you, you could put it in the answers i'll accept it. JustSxript 36 — 5y

1 answer

Log in to vote
0
Answered by 5 years ago

Replace the

fire.Size = NumberSequence.new(number)

with

fire.Size = number

The Size of the Blur is a float (i.e. a number) not a NumberSequence

Ad

Answer this question