How to use else?

So I’m basically trying to make a survival System if the players value == true if not they don’t get cash

local players = game:GetService("Players")
local localPlayer = players.LocalPlayer;
local Gui = localPlayer.PlayerGui.NightSurvive
local Info = TweenInfo.new(1)
game.ReplicatedStorage.CheckPlayer.OnClientEvent:Connect(function()
	if localPlayer.Handler.Survived == true then
		localPlayer.PlayerGui.Sounds.Survived:Play()
		local Tween2 = game:GetService("TweenService"):Create(Gui.NightHasEnded,Info,{TextTransparency=0}):Play()
		local Tween1 = game:GetService("TweenService"):Create(Gui.YesCredits,Info,{TextTransparency=0}):Play()
		local Tween2 = game:GetService("TweenService"):Create(Gui.YesSurvive,Info,{TextTransparency=0}):Play()
		
		wait(5)
		
		local Tween2 = game:GetService("TweenService"):Create(Gui.NightHasEnded,Info,{TextTransparency=1}):Play()
		local Tween1 = game:GetService("TweenService"):Create(Gui.YesCredits,Info,{TextTransparency=1}):Play()
		local Tween2 = game:GetService("TweenService"):Create(Gui.YesSurvive,Info,{TextTransparency=1}):Play()
		
		
		
	else
		
		localPlayer.PlayerGui.Sounds.NoSurvived:Play()
		local Tween2 = game:GetService("TweenService"):Create(Gui.NightHasEnded,Info,{TextTransparency=0}):Play()
		local Tween3 = game:GetService("TweenService"):Create(Gui.NoCredits,Info,{TextTransparency=0}):Play()
		local Tween4 = game:GetService("TweenService"):Create(Gui.NoSurvive,Info,{TextTransparency=0}):Play()
		
		wait(5)
		
		local Tween2 = game:GetService("TweenService"):Create(Gui.NightHasEnded,Info,{TextTransparency=1}):Play()
		local Tween3 = game:GetService("TweenService"):Create(Gui.NoCredits,Info,{TextTransparency=1}):Play()
		local Tween4 = game:GetService("TweenService"):Create(Gui.NoSurvive,Info,{TextTransparency=1}):Play()
		end
	
	

end)

Is this meant to be if localPlayer.Handler.Survived.Value then?

3 Likes

Freak I keep making these dumb mistakes but thanks for your help on them :slight_smile:

2 Likes

Anytime! I would recommend keep a clever and careful look at your code before making a post so you may be able to spot out the dumb mistakes! But it’s okay, a fresh pair of eyes help out as well!

If you have anymore issues don’t be afraid to make another post!

1 Like