#round system thinking players died immidiatly
42 messages · Page 1 of 1 (latest)
here is the whole script
although i think the problem is in here:
for i, player in pairs(plrs) do
if player then
character = player.Character
if character then
--Teleport them
character:FindFirstChild("HumanoidRootPart").CFrame = AvailableSpawnPoints[1].CFrame
table.remove(AvailableSpawnPoints,1)
--give them gun
local gun = ServerStorage.Gun:Clone()
gun.Parent = player.Backpack
local GameTag = Instance.new("BoolValue")
GameTag.Name = "GameTag"
GameTag.Parent = player.Character
else
--there is no character
if not player then
table.remove(plrs, i)
end
end
end
end
Status.Value = "Get ready to play!"
task.wait(2)
for i = GameLength,0,-1 do
for x, player in pairs(plrs) do
if player then
character = player.Character
if not character then
--left the game
else
if character:FindFirstChild("GameTag") then
print(player.Name.."IS STILL IN THE GAME")
else
--they dead lol
table.remove(plrs,x)
print(player.Name.." has been removed")
end
end
else
table.remove(plrs,x)
print(player.Name.." has been removed")
end
end
Status.Value = " " ..i.." seconds left / "..#plrs.." remaining"
I think the same players get re-added in the plrs table and generally the whole variable gets messed up.
I fixed it some how
I’m not sure what I did but it works now
Onr more thing tho
At the bottom of the script it’s supposed to destroy the player
Which it doesn’t
Right here
do u know ur own script 😭
Then how do I destroy the player
I’ve been working on this singular script for 2 weeks
I’m not good at scripting
I just keep trying things until it works
Wait
i think its a good time to just get a tutorial for scripting
I’m dumb I can just do character:destroy right
force them to die or destroy their character cuh
Like this???
Character:destroy()
@dusk tapir
Stay with me now
how else
Gang give me a yes or a no
I guess I’ll try it and see if it works