since habbohotel is quit professionally made, i think they will be using a socket to comunicate with flash.
another possibility is to use sendAndLoad Vars. these are functions of flash that read the data that is written on a certain webpage.
to make a login in flash, you just have to create a mysql table and a login script. in flash you have to create a frame where you put in 2 inputfields and a button: 1 for the username, and 1 for the password. in the script area of the frame, you place something like this:
take a look at this post as well:
http://www.programmingtalk.com/showthread.php?t=28770
Hope this helps a little,
UnrealEd