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

How do i make so the player stays in his and doesn't change his team even if he died?

Asked by 5 years ago
Edited 5 years ago

Hello! I'm new for scripting teams and I'm making my tycoon with no kits or help from the toolbox. But I ran into a problem Where you can change teams even if you are in one so Please help. The script:

01local sL = script.Parent
02local claimed = false
03sL.Touched:Connect(function(hit)
04    if game.Players:FindFirstChild(hit.Parent.Name)and claimed == false then
05        claimed = true
06        local player = game.Players:FindFirstChild(hit.Parent.Name)
07        player.Neutral = false
08        player.Team = game.Teams.Blue
09        if not player.Team.Blue then
10 
11        end
12    end
13 
14end)
0
Can you include the script? youtubemasterWOW 2741 — 5y
0
Included it. Baselistic 103 — 5y

1 answer

Log in to vote
0
Answered by
Nckripted 580 Moderation Voter
5 years ago

I honestly don't think you need to do anything as long as no team has AutoAssign or whatever that boolean is called to automatically assign someone to a team.

Ad

Answer this question