Hello, I’ve noticed an error with my If then Statement, inside of a tool. I will give the full script if it is needed,
rock.Material = Enum.Material.Sand
rock.Color = Color3.new(0.968627, 1, 0.752941)
rock.Parent = tool
rock.Size = Vector3.new(math.random(1,2),math.random(1,2),math.random(1,2))
tool.Name = 'Ancient Sand'
tool.Parent = workspace
tool:PivotTo(handleclone.CFrame)
handleclone.Transparency = 1
Remove()
elseif Player:WaitForChild('Body').Value == 'Moon' or 'Quaerthunder' or 'Kernol' or 'Mercury' or 'Sector 1b' then
rock.Material = Enum.Material.Glass
rock.Shape = 1
rock.Color = Color3.new(0, 0, 0)
rock.Parent = tool
rock.Size = Vector3.new(math.random(1,2),math.random(1,2),math.random(1,2))
tool.Name = 'Dark Glass'
tool.Parent = workspace
tool:PivotTo(handleclone.CFrame)
handleclone.Transparency = 1
Remove()
else
Remove()
warn('Is not a planet that generates rocks with an explosive charge...')
end
Main Problem: See how it says if Player:WaitForChild('Body').Value == 'Persianta' or 'Titaniturn' then
? even if the Body value isn’t Persianta or Titaniturn, It will still generate sand, or glass (the elseif statement.)
I’ve tried rearranging this if statement, but it won’t change the outcome.