EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Development::Database/World Building (https://www.eqemulator.org/forums/forumdisplay.php?f=596)
-   -   VB forums user accounts as login accounts (https://www.eqemulator.org/forums/showthread.php?t=34529)

secondattack 11-29-2011 09:12 AM

VB forums user accounts as login accounts
 
Heya folks, i need alttle feed back
i'm looking for a way to merge my website forum user accounts into my servers login accounts so they are one in the same. Benefits of doing this would be to change things each account has access to on the game server based on their forum accounts user group. Like say i wanted forum mods to have gm access automatically or i want the doner group to have access to custom commands or vendors. I know this most likely is going to be no simple task, but i have time to figure it out as my server will not go public any time soon

Tabasco 11-29-2011 10:31 AM

You could have an NPC in game that has a registration script. They hail and go through whatever process you like, ultimately generating a random password and whispering it to the client. The perl script should write the account name and the generated password to a table in the db. You might query that table first to see if they've already completed registration or if they've only attempted it and decide how resets or forgotten temporary passwords will be handled.

Next, when they go to the forum to register, you would need to add two new form elements for the account name and the temporary password. In phpbb this is pretty easy. I already use the account_ip table on my server to keep spammers out of my forums without having to worry about registration emails. If it all matches up you update that original username/temp pw table to include the forum username and current status, which at creation should probably be 0. Just to be clear, login server account names should not be forum usernames. They really should never be exposed, instead map one to the other privately.

The last step would be to update status based on forum settings. The easy way would be to set up a cron job or scheduled task to process updates, but even with a cache to prevent redundant updates, your overhead will grow with your userbase, regardless of whether or not they are playing. If you really wanted to get intimate with your BB package you could insert immediate update hooks any time a group is changed, which would probably be more efficient but also a little more complex.
I think status gets re-read when a user logs in so just writing the status to the db should be fine. If I'm wrong you could use a telnet library.

This all assumes you're competent and comfortable with some programming, mostly perl and php. I've never used vBulletin (I'm guessing that's what your VB stands for) but you wouldn't be able to do this without source access.


All times are GMT -4. The time now is 06:55 PM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.