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

how to turn off respawnTime?

Asked by 3 years ago

Hello, I've got a script that makes a GUI visible when the player dies, but my problem is that when the player presses the RespawnButton it closes the gui which is good however it opens up right after because of the players Respawn Time. Is there a way to get around this? If I set it to zero it will just reopen the GUI after 0 seconds correct?

0
Yeah you should just be able to change the respawntime in players AnotherPerson_999 28 — 3y
0
AnotherPerson_999, I just tried that and it isn't working. Seems that RespawnTime isn't the one doing it i guess. It's teleporting me to the spawn and making the GUI visible again after like two seconds Sonnymacko 19 — 3y

2 answers

Log in to vote
0
Answered by 3 years ago
Edited 3 years ago

What if you just put it like 10 then when they died the UI popups right? So then it has like a timer for like 10 secs too so they will automatically spawn back if they didnt click it

0
Script 1 (Respawning Character) ~~~~~~~~~~~~~~~~~ local RemoteEvent = game.ReplicatedStorage.RemoteEvent RemoteEvent.OnServerEvent:Connect(function(player) game.Players.CharacterAutoLoads = false player:LoadCharacter() end) ~~~~~~~~~~~~~~~~~ Sonnymacko 19 — 3y
0
Here is my script for the GUI Button local RespawnButton = script.parent local menu = script.Parent.Parent local Players = game:GetService("Players") local player = Players.LocalPlayer local RemoteEvent = game.ReplicatedStorage.RemoteEvent --new variable RespawnButton.MouseButton1Click:Connect(function() if player then menu.Visible = false RemoteEvent:FireServer(game.Players.LocalPlayer Sonnymacko 19 — 3y
0
Oh I get what you mean acediamondn123 147 — 3y
0
wait let me try this to my self to make sure it works acediamondn123 147 — 3y
View all comments (10 more)
0
Ill edit my answer acediamondn123 147 — 3y
0
there it should work, If you have any problems reply here acediamondn123 147 — 3y
0
I turned character auto loads off in Players and now the GUI won't display Sonnymacko 19 — 3y
0
local RemoteEvent = game.ReplicatedStorage.RemoteEvent RemoteEvent.OnServerEvent:Connect(function(player) game.Players.PlayerAdded:Connect(function(player) game.Players.CharacterAutoLoads = false player:LoadCharacter() end) end) Sonnymacko 19 — 3y
0
wdym by that acediamondn123 147 — 3y
0
Ill try to remake what u tryin to do acediamondn123 147 — 3y
0
oh bc the script cant see the character acediamondn123 147 — 3y
0
I found a way hol up acediamondn123 147 — 3y
0
I made one work but its messsy acediamondn123 147 — 3y
0
Read my asnwer again I edited it acediamondn123 147 — 3y
Ad
Log in to vote
0
Answered by
NGC4637 602 Moderation Voter
3 years ago

well i mean you CAN just set the respawn time to more than 1200 (20 minutes), so that if the person does try to wait for respawn, the person gets kicked by the whole idle for 20 minutes thing, and set respawn time to zero, wait() and then set respawn time back to le big number when you decide the player should respawn.

0
Well i tried setting the RespawnTime to 1200 and it still teleports me back to the spawn point and the GUI pops up again Sonnymacko 19 — 3y

Answer this question