[COMPLETED] GlobalChat - Chat across multiple servers!

Discussion in 'WIP and Development Status' started by DrAgonmoray, Jul 26, 2011.

Thread Status:
Not open for further replies.
  1. Offline

    DrAgonmoray

    The idea- no, the vision behind GlobalChat, is being able to be in one server, and having the ability to talk to your friend in another server. Or even hook into HeroChat and have a global chat channel that spans across hundreds of servers.

    If anybody has a _good_ webserver that they would allow GlobalChat to run on, that would be great. My webserver is tiny and pretty slow. Speed is important.
    The webserver needs PHP and MySQL.

    What is GlobalChat?
    As of right now, GlobalChat allows you to chat across all servers with GlobalChat installed.

    What will GlobalChat become?
    Checking online players of every server*
    Inboxes that are persistent across every server you go to*
    Messaging to your friends no matter what server they are in*
    ..and more.
    *GlobalChat must be installed.

    Anyone have a better name than GlobalChat? It's going to have more than global chatting, so it needs something more suitible.

    Current progress:

    • Successfully sent an HTTP request to a php file, and got info back from it.
    • Messages get added to the database
    • New: lerned to sanitize my input n00b
    • New: Got rid of all chat lag by sending the HTTP request on a separate thread

    It's goin' good so far. :D

    Current progress:
    • Successfully sent an HTTP request to a php file, and got info back from it.
    • Messages get added to the database
    • lerned to sanitize my input n00b
    • Got rid of all chat lag by sending the HTTP request on a separate thread
    • New: Successfully retrieved chat messages from the database and displayed them on the server.

    Yeah, so making good progress. I've got to think this next part out though. How can I make it only display messages that haven't been displayed yet? (it gets messages from the database every 10 seconds atm)

    Got the global chat system working. I just need to make it so that it doesn't display messages from in your server.
    Ex: (this is what i don't want to happen)
    Joe: hey guys wats up
    Bob: not much
    [GlobalChat] Joe: hey guys wats up
    [GlobalChat] Bob: not much

    Does anybody know of a way to identify each server uniquely?

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 18, 2016
  2. Offline

    desmin88

  3. Offline

    DrAgonmoray

    i tried that, but if the IP isn't specified in the server.properties, it returns blank.
     
  4. Offline

    desmin88

    @DrAgonmoray
    use getServer().getServerId();, then getServer().getPort(); and make a unique string for each server
     
  5. Offline

    DrAgonmoray

    getServerId returned empty when I tried it
    Wait, it was probably because I was testing in offline mode. (when I release I will prevent offline mode)
    But used a different method.
    And it works now, it's kinda fun to talk to myself.

    I went on my old server (not hosted by me) logged on as DrAgonmoray. Then I logged in as "Player" in offline mode and went on my local server. Then i started talking to myself.
    [​IMG]
     
  6. Offline

    DrAgonmoray

    Oops, I forgot to update this. But the beta 1.0 version is ready. Check it out!
    GlobalChat Beta 1.0
     
Thread Status:
Not open for further replies.

Share This Page