Show username in welcome message

Results 1 to 4 of 4
  1. #1

    Show username in welcome message

    Hi, i'm use PlusEMU and RevCMS I want show on welcome message a username
    Screenshot by Lightshot

    Sorry for my bad english :P i'm Italian


    Inviato dal mio  iPhone 6s Plus utilizzando Tapatalk


  2. #2
    Account Upgraded | Title Enabled! streamhotel is offline
    MemberRank
    Apr 2012 Join Date
    EarthLocation
    511Posts

    Re: Show username in welcome message

    Try something like the code below. But why it's relevant that you're using RevCms? By you're question I'm very sure you can only setup a retro hotel by instructions. So I don't think you can use Visual Studio tools properly and build with it but succes!

    Code:
    string message =  "welcome message %username%";
    var realMessage = message.Replace("%username%", session.GetHabbo().Username);
     
    return realMessage;

  3. #3
    Member DJGOMEZV is offline
    MemberRank
    Mar 2013 Join Date
    56Posts

    Re: Show username in welcome message

    Quote Originally Posted by Mattia Genova View Post
    Hi, i'm use PlusEMU and RevCMS I want show on welcome message a username
    Screenshot by Lightshot

    Sorry for my bad english :P i'm Italian


    Inviato dal mio  iPhone 6s Plus utilizzando Tapatalk

    Go: HabboHotel/GameClients/GameClient.cs and Search: welcome_message

    Replace this:

    Code:
    if (!string.IsNullOrWhiteSpace(PlusEnvironment.GetDBConfig().DBData["welcome_message"]))
                            SendMessage(new MOTDNotificationComposer(PlusEnvironment.GetDBConfig().DBData["welcome_message"]));
    For this:

    Code:
    if (!string.IsNullOrWhiteSpace(PlusEnvironment.GetDBConfig().DBData["welcome_message"]))
                            SendMessage(new MOTDNotificationComposer(PlusEnvironment.GetDBConfig().DBData["welcome_message"].Replace("%username%", GetHabbo().Username)));

  4. #4

    Re: Show username in welcome message

    Quote Originally Posted by DJGOMEZV View Post
    Go: HabboHotel/GameClients/GameClient.cs and Search: welcome_message

    Replace this:

    Code:
    if (!string.IsNullOrWhiteSpace(PlusEnvironment.GetDBConfig().DBData["welcome_message"]))
                            SendMessage(new MOTDNotificationComposer(PlusEnvironment.GetDBConfig().DBData["welcome_message"]));
    For this:

    Code:
    if (!string.IsNullOrWhiteSpace(PlusEnvironment.GetDBConfig().DBData["welcome_message"]))
                            SendMessage(new MOTDNotificationComposer(PlusEnvironment.GetDBConfig().DBData["welcome_message"].Replace("%username%", GetHabbo().Username)));
    Don't work


    Inviato dal mio  iPhone 6s Plus utilizzando Tapatalk



Advertisement