Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
✓ ANSWER ACCEPTED

Death GUI help. Is it possible to do this?

I am currently wanting to make a GUI that when you die, it rotates your screen 30 degrees to the right you can't look up or down, only side to side, and you do NOT respawn until you press the left mouse button. I was wanting to know if this is possible. The GUI also says "You have died. Press FIRE to Respawn." I already have the GUI object in my game.

3 answers

✓ Accepted answer

You would use the Died event

Died Event

You would probably be better off adding the script into the player, but putting it in StarterGui, then, if it is in the startergui you could start your script by

plr=script.Parent.Parent

hum=plr.Character.Humanoid

hum.Died:connect(function()
--use plr.PlayerGui then get the GUI you want rotated, then rotate it. This is all i'm giving since its not a request site.
end)

As for rotating the GUI, this script rotates the scripts parent, you will have to edit it. Basically what it will do is rotate the parent (If it is a GUI of course) 180 degrees (Upside down basically)

You can edit the 360 to 180 and it will turn 1/4 of the way around, and you can mess around with it.

for i=1,360 do
script.Parent.Rotation=script.Parent.Rotation+.5
wait(.1)
end

2 comments

0

I'm actually wanting to rotate the camera when you die.

0

Ok you would want to edit the Rotation property. I will update with what you would do to rotate it

Yes, it is possible to do this.

3 comments

0

Can you help me? We can get into contact on ROBLOX.

0

No, this is a forums where we give advice and help with scripts that are in progress. I am not going to help you write this from scratch. Sorry.

0

Eh. Base script? Like the function to determine when someone dies?

This discussion is preserved as it was. New answers, comments, and votes are closed.