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

Death GUI help. Is it possible to do this?

Asked by 10 years ago

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

Log in to vote
1
Answered by 10 years ago

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
0
I'm actually wanting to rotate the camera when you die. TheRings0fSaturn 28 — 10y
0
Ok you would want to edit the Rotation property. I will update with what you would do to rotate it Tempestatem 884 — 10y
Ad
Log in to vote
0
Answered by
acecateer 130
10 years ago

These will help.

http://wiki.roblox.com/index.php?title=Died_(Event) It is fired after a humanoid's health reaches 0.

http://wiki.roblox.com/index.php?title=MouseButton1Click_(Event) Fires when you left click the GUI object specified.

GUI objects have a 'Rotation' property. http://wiki.roblox.com/index.php?title=Rotation_(Property)

Log in to vote
-1
Answered by
Necrorave 560 Moderation Voter
10 years ago

Yes, it is possible to do this.

0
Can you help me? We can get into contact on ROBLOX. TheRings0fSaturn 28 — 10y
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. Necrorave 560 — 10y
0
Eh. Base script? Like the function to determine when someone dies? TheRings0fSaturn 28 — 10y

Answer this question