• Advertisement
Sign in to follow this  
  • entries
    557
  • comments
    1237
  • views
    422730

Avatar Support!

Sign in to follow this  

255 views

Hooray, DruinkMUD has avatar support! Unfortunately, there's no clients that support it yet. I didn't get around to that early night, I was up till 1am designing a plugin for DruinkIM that will provide avatar support, and some extra DruinkMUD stuff, like a constant visual representation of your stats and weapons.
The reason I'm doing a plugin instead of building it into DruinkIM, is that DruinkIM isn't just for my MUD. In fact, there's about 10 people that use it for connecting to TA. I think I'll eventually write a new client, specificly for DruinkMUD, once I get the server done.

The way avatars work is like this. When you login, the plugin will send a .druinkwho command, that causes the server to send a list of users to the client, along with a URL to their avatar, and a Last-Modified time.
The client reads this info, and checks its cache of avatar files against the info it's recieved. If it doesn't have the file cached, or the Last-Modified time doesn't match the cached version, then it'll mark that user as dirty.
Whenever a user changes their avatar (with .setavaraturl, the server sends a message to all connected users using Druink protocol, and they'll all update their caches as above.

Now the plugin starts a thread, which goes and downloads all the images for dirty users via HTTP. Then I can load any images I need, and display them as avatars.

That'll do for now, I'm tired :P
Sign in to follow this  


0 Comments


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Advertisement