generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Disconnecting a player?

Previous Thread :: Next Thread 
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Oct 2012 08:49 AM
I don't want to use Player:Destroy(), but I want to 'disconnect' a Player, so would a "ManualSurfaceJointsInstance" in the CurrentCamera or PlayerGui crash the player or would it still crash a server? If it would crash the server, would someone tell me an alternate method?
Report Abuse
gerit99 is not online. gerit99
Joined: 21 Jul 2010
Total Posts: 521
27 Oct 2012 08:59 AM
Use a local script with a while true do end in the player :3
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Oct 2012 09:00 AM
I know localscripts only work clientside, but I'm making a GUI. Using RbxGui.

Soooooo, that wouldn't work.
Report Abuse
gerit99 is not online. gerit99
Joined: 21 Jul 2010
Total Posts: 521
27 Oct 2012 09:01 AM
Oh, that sux xD. I have an idea: Don't use RbxGui.
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Oct 2012 09:04 AM
I can't NOT use it. It would be too hard. Look:

function quitGame()
end
function saveAll()
local plr = script.Parent.Parent.Parent.Parent.Parent.Parent.Parent
plr:SaveNumber("Studs", game.Lighting[plr.Name].Studs.Value)
plr:SaveNumber("Minerals", game.Lighting[plr.Name].Minerals.Value)
plr:SaveNumber("Crystals", game.Lighting[plr.Name].Crystals.Value)
plr:SaveInstance("Planet", workspace[plr.Name.."_Planet"])
quitGame()
end
RbxGui = assert(LoadLibary("RbxGui"))
script.Parent.MouseButton1Down:connect(
function()
local saveDialogMessageBox
local messageBoxButtons = {}
messageBoxButtons[1] = {}
messageBoxButtons[1].Text = "No"
messageBoxButtons[1].Style = Enum.ButtonStyle.RobloxButtonDefault
messageBoxButtons[1].Function = function() saveDialogMessageBox:Remove() quitGame() end
messageBoxButtons[2] = {}
messageBoxButtons[2].Text = "Yes"
messageBoxButtons[2].Style = Enum.ButtonStyle.RobloxButtonDefault
messageBoxButtons[2].Function = function() saveDialogMessageBox:Remove() saveAll() end

saveDialogMessageBox = RbxGui.CreateStyledMessageDialog("Save Game","Do you want to save your game before quitting?", "Confirm", messageBoxButtons)
saveDialogMessageBox.Visible = true
saveDialogMessageBox.Parent =script.Parent.Parent.Parent.Parent.Parent
end
)

What do I do, if I don't use RbxGui?
Report Abuse
gerit99 is not online. gerit99
Joined: 21 Jul 2010
Total Posts: 521
27 Oct 2012 09:11 AM
bump
Report Abuse
MeBilly8440 is not online. MeBilly8440
Joined: 27 Jul 2009
Total Posts: 2783
27 Oct 2012 09:20 AM
Make a LocalScript with some fancy linked source junk so it loads "Instance.new("ManualSurfaceJointInstance")" from a pre-made model, then load it into the game. Something like that c:
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Oct 2012 09:24 AM
But wouldn't ManualSurfaceJointsInstance crash the server? It's used in RemoteErrorMonitorScript, like so:

function shutdown()
-- game:RequestShutdown()
-- game:FinishShutdown()

-- until RequestShutdown is implemented, will have to use gross hack to just crash the server :(
Instance.new("ManualSurfaceJointInstance", workspace)
end

So, how would I change it so the ManualSurfaceJointInstance would ONLY crash the player? The reason why I want the player to crash is because if you use Player:Destroy() then everything still works - I want the player to not be able to update the camera. Mabye if I destory CurrentCamera after destroying the Player?
Report Abuse
MeBilly8440 is not online. MeBilly8440
Joined: 27 Jul 2009
Total Posts: 2783
27 Oct 2012 09:28 AM
Don't give it a parent, and run it from a LocalScript, and it will crash the client instead. However, if you give it a parent or don't run it from a LocalScript, it will crash the server.
Report Abuse
digpoe is not online. digpoe
Joined: 02 Nov 2008
Total Posts: 9092
27 Oct 2012 09:29 AM
Okay.. I thought the default place where things created with Instance.new() was nil....

Ok. My mental logic just had a breakdown.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image