• Official Post

    Hey developers!


    i will present a simple script how you can use the user api to write user statistics into the IRC (chat) network.
    (this is not a tutorial how you can write an irc bot ;) ...)


    first the PHP code:



    short description...
    i split the buffer by a empty space... if the first is ".rank" then we start our calls.
    the second is the instance value (example retro, int1 or de1) ... the third parameter is the username (or id)
    with this information we call the user api (with json output) ...
    Now we check there is an existing user given (userid not null) and will send a message into the channel with user statistics or a failure message...


    I hope this will help you :)
    When you want to see this script in action...
    you are welcome to our IRC channel spaceinvasion (the chat button on top of this page) ... and test the script by writing ".rank retro dschibait" :)


    best regards
    Dschibait