02-25-2011, 04:53 AM
Hi everybody , is it possible to make a plugin who player can use a password to stay connected with his Nickname ? ( possibly not in mysql :p plz )
Authentification plugin
|
02-25-2011, 04:53 AM
Hi everybody , is it possible to make a plugin who player can use a password to stay connected with his Nickname ? ( possibly not in mysql :p plz )
02-25-2011, 06:05 AM
Nope, because it's not possible to kick a player.. yet. oO
02-25-2011, 06:51 AM
Well, I can, but it's not possible to disallow a player that connects.. yet.. (I hope)
Player:BanPlayer/Player:KickPlayer should be installed. :p EDIT: Btw.. If you want it non-MySQL, it would be usefull to install a word compiler, like MD5, else you could see everyone's pass. LUA doesn't normally have MD5 installed. But you should also need then a XML parser... For saving on a save way. :/
02-26-2011, 09:59 AM
(02-26-2011, 12:17 AM)Jockie Wrote: Well, I can, but it's not possible to disallow a player that connects.. yet.. (I hope)Yes it is Use the E_PLUGIN_LOGIN hook and the OnLogin( cPacket_Login ) function. Return true to kick the player. (02-26-2011, 12:17 AM)Jockie Wrote: Player:BanPlayer/Player:KickPlayer should be installed. :pYes it should, lol. Better make this my top priority then. (02-26-2011, 12:17 AM)Jockie Wrote: EDIT: Btw.. If you want it non-MySQL, it would be usefull to install a word compiler, like MD5, else you could see everyone's pass.I already have a md5 hasher for MCServer, just not exposed to Lua yet. I don't see why you'd need an XML parser though, you could use the ini files.
02-26-2011, 09:27 PM
Hm.. So it would look like this by then? oO
Code: [1] Also possible. :p
02-27-2011, 03:46 AM
(02-26-2011, 09:27 PM)Jockie Wrote: Hm.. So it would look like this by then? oOYou even can access the user.ini from MCServer and add a password by plugin. This way all user information will be stored at same place, which makes administration easier. greets, Tybor
02-27-2011, 06:37 AM
What Tybor suggests sounds like the smartest thing to do
If you want to use a seperate file, I'd suggest something like this: Code: [AuthenticationPlugin]
03-01-2011, 11:54 PM
(02-26-2011, 09:59 AM)FakeTruth Wrote:(02-26-2011, 12:17 AM)Jockie Wrote: Well, I can, but it's not possible to disallow a player that connects.. yet.. (I hope)Yes it is Is that sort of like 'cancelling' the event? If so, does that cancel other events too?
03-02-2011, 05:48 AM
On most (if not all, I think it's all) plugin callbacks you return false to let MCServer do its normal business like nothing ever happened. When you return true you will override default behavior or modify it. When you return true in the OnLogin function MCServer will simply close the connection with the player.
|
« Next Oldest | Next Newest »
|