I am currently working on a time stop script that anchors all players for 12 seconds and unanchors them. However, the time stop movement is where I'm having the trouble. I'm having a server script check if any players have a certain user name. If they do, then they will be unanchored; but whenever i check for the player, the script doesn't fire OR print anything even though I have a localscript fire the event. Here is the script if needed:
game.ReplicatedStorage.PlayerCheck.OnServerEvent:Connect(function()
game.Players.PlayerAdded:Connect(function(player)
player.CharacterAdded(function(character)
if player.Name == "Crimsonknightzone" then
print("Unfreezing")
end)
end)
end)
bonus points if you can [somehow] fit the check for player into my TS script (Optional) :)
game.ReplicatedStorage.FreezePop.OnClientEvent:Connect(function()
local player = game.Players.LocalPlayer
local character = player.Character
if not character or not character.Parent then
character = player.CharacterAdded:wait()
end
if character then
character.Torso.Anchored = true
local Larm = character["Left Arm"]
local Rarm = character["Right Arm"]
local Lleg = character["Left Leg"]
local Rleg = character["Right Leg"]
Larm.Anchored = true
Rarm.Anchored = true
Lleg.Anchored = true
Rleg.Anchored = true
character.Head.Anchored = true
if player.Character == "Crimsonknightzone" then
print("Player is fit for TS, Removing constraints")
end
wait(12)
local sound = game.Workspace.TSRes
sound:Play()
Larm.Anchored = false
Rarm.Anchored = false
Lleg.Anchored = false
Rleg.Anchored = false
character.Torso.Anchored = false
character.Head.Anchored = false
end
end)
