Habboon Plus Edit Commands

May 1, 2015
470
154
Hi, I've been trying to code commands into boon's plus edit, and whenever i go onto the client it just says it as regular speech?
now, I thought this was because the command wasn't registered somewhere but i'm quite sure everything is where it's supposed to be.
Not familiar with this edit yet anyways,
Here is my command,
Code:
using System;
using System.Linq;
using System.Text;
using System.Collections.Generic;

using Plus.HabboHotel.Rooms;
using Plus.HabboHotel.GameClients;
using Plus.Communication.Packets.Outgoing.Rooms.Chat;

namespace Plus.HabboHotel.Rooms.Chat.Commands.User.Fun
{
    class dropkickcommand : IChatCommand
    {
        public string PermissionRequired
        {
            get { return "command_dropkick"; }
        }
        public string Parameters
        {
            get { return "%username%"; }
        }
        public string Description
        {
            get { return "Dropkick another user"; }
        }
        public void Execute(GameClients.GameClient Session, Rooms.Room Room, string[] Params)
        {
            if (Params.Length == 1)
            {
                Session.SendWhisper("Please enter the username of the person you want to dropkick.");
                return;
            }
            GameClient TargetClient = PlusEnvironment.GetGame().GetClientManager().GetClientByUsername(Params[1]);
            if (TargetClient == null)
            {
                Session.SendWhisper("The user was not found in the room.");
                return;
            }
            RoomUser TargetUser = Room.GetRoomUserManager().GetRoomUserByHabbo(TargetClient.GetHabbo().Id);
            if (TargetUser == null)
            {
                Session.SendWhisper("An error occured while finding that user, maybe they're offline or not in this room.");
            }
            if (TargetClient.GetHabbo().Username == Session.GetHabbo().Username)
            {
                Session.SendWhisper("You cannot dropkick yourself!");
                return;
            }
            TargetUser.Statusses.Add("sit", "1.0");
            TargetUser.UpdateNeeded = true;

            Room.SendMessage(new ChatComposer(TargetUser.VirtualId, "Dropkicks " + TargetClient.GetHabbo().Username + "*", 0, TargetUser.LastBubble));
        }
    }
}
and here is what it does,
UZViQ9J.png

Now, I have no idea if this command is even coded properly for this emulator,
this is my first attempt at coding into this edit, and i'm still getting used to it.

Thanks,
 

Users who are viewing this thread

Top