I am trying to create a terminal and have 3 local scripts that all interact with each other, however the main script won't change the Value of a number value. The console has no errors and the code doesn't either. Main Code
game.Players.PlayerAdded:connect(function(player) if game.Players.player.TeamColor == "Navy blue" then script.Parent.Urbanity.Value = script.Parent.Urbanity.Value + 1 end if game.Players.player.TeamColor == "Maroon" then script.Parent.Urbanity.Value = script.Parent.Hostiles.Value + 1 end if script.Parent.Urbanity.Value == 3 and script.Parent.Hostiles.Value == 2 then game.Players.player.PanelGui.Frame2.Tweenie.LocalScript.Disabled = false game.Workspace.Sensor.Script.Disabled = false local T = player.PanelGui.Frame2.Time T = "20" wait(60) T = "19" wait(60) T = "18" wait(60) T = "17" wait(60) T = "16" wait(60) T = "15" wait(60) T = "15" wait(60) T = "14" wait(60) T = "13" wait(60) T = "12" wait(60) T = "11" wait(60) T = "10" wait(60) T = "9" wait(60) T = "8" wait(60) T = "7" wait(60) T = "6" wait(60) T = "5" wait(60) T = "4" wait(60) T = "3" wait(60) T = "2" wait(60) T = "1" wait(60) T = "0" local W = Instance.new("Message") W.Parent = workspace if game.Workspace.Sensor.Urbanity.Value == true then local W = Instance.new("Message") W.Parent = workspace W.Text = "The Hostiles have Failed!" else if game.Workspace.Sensor.Hostiles.Value == true then W.Text = "The Hostiles have Won!" end end end end)
Terminal Code
script.Parent.Touched:connect(function(hit) if hit.Parent:FindFirstChild("Humanoid") == true then local character = game.Workspace.hit local player = game.Players:GetPlayerFromCharacter(character) if character.TeamColor == "Maroon" then if script.Parent.Urbanity.Value == true then script.Parent.Uranity.Value = false end script.Parent.Hostiles.Value = true end if character.TeamColor == "Navy blue" then if script.Parent.Hostiles.Value == true then script.Parent.Hostiles.Value = false end script.Parent.Urbanity.Value = true end end local character = game.Workspace.hit local player = game.Players:GetPlayerFromCharacter(character) if script.Parent.Hostiles.Value == true then character.PanelGui.Frame2.Owner.Text = "Hostiles" end local character = game.Workspace.hit local player = game.Players:GetPlayerFromCharacter(character) if script.Parent.Urbanity.Value == true then character.PanelGui.Frame2.Owner.Text = "Urbanity" end end)
One of these 2 scripts right here are giving me trouble, the trouble is I have no clue why it won't change the .Value