can anyone help me make those statements into one singular if statement ?
FloorNumber = ElevatorHandler.CurrentFloor.Value
if FloorNumber == 0 then
workspace.CurrentFloor:FindFirstChildWhichIsA("Folder"):Destroy()
local ChosenFloor = CurrentLayer.LayerDefault
local FloorClone = ChosenFloor:Clone()
FloorClone.Parent = workspace.CurrentFloor
CurrentFloorType = "Safe"
task.wait(0.5)
AnomalyButton.ClickDetector.MaxActivationDistance = 10
return
elseif FloorNumber == 5 then
workspace.CurrentFloor:FindFirstChildWhichIsA("Folder"):Destroy()
local ChosenFloor = CurrentLayer.LayerDefault
local FloorClone = ChosenFloor:Clone()
FloorClone.Parent = workspace.CurrentFloor
CurrentFloorType = "Safe"
task.wait(0.5)
AnomalyButton.ClickDetector.MaxActivationDistance = 10
return
elseif FloorNumber == 10 then
workspace.CurrentFloor:FindFirstChildWhichIsA("Folder"):Destroy()
local ChosenFloor = CurrentLayer.LayerDefault
local FloorClone = ChosenFloor:Clone()
FloorClone.Parent = workspace.CurrentFloor
CurrentFloorType = "Safe"
task.wait(0.5)
AnomalyButton.ClickDetector.MaxActivationDistance = 10
return
else
i tried doing if FloorNumber == 0 or 5 or 10 then
but that doesnt seem to work, even if the FloorNumber
is not equal to 0 or 5 or 10
(ex. FloorNumber is 2 or 7 or 9), it still goes thu the statement . if u need more information, please specify what and i will provide, thx