Menu
Forums
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Trending
What's new
New posts
New profile posts
Latest activity
Members
Current visitors
New profile posts
Search profile posts
Upgrades
Log in
Register
What's new
Search
Search
Search titles only
By:
All threads
Latest threads
New posts
Trending threads
New posts
Search forums
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
Server Development
Habbo Retros
Habbo Q&A
Boon Emulator Issues! + Custom Commands
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Kods" data-source="post: 367978" data-attributes="member: 62226"><p>I'm unsure if you know exactly how to implement the commands if not just follow the spoilers.</p><p></p><p>First you need to create and save your commands into the emulator.</p><p>[spoiler=Creating the commands]</p><p><strong>Create a new file in HabboHotel/Rooms/Users/Chat/Commands/User/Fun and save it as KissCommand.cs</strong></p><p>[code]</p><p>using System;</p><p>using System.Linq;</p><p>using System.Text;</p><p>using System.Collections.Generic;</p><p></p><p>using Plus.HabboHotel.Rooms;</p><p>using Plus.HabboHotel.Pathfinding;</p><p>using Plus.HabboHotel.GameClients;</p><p>using Plus.Communication.Packets.Outgoing.Rooms.Chat;</p><p></p><p>namespace Plus.HabboHotel.Rooms.Chat.Commands.User.Fun</p><p>{</p><p> class KissCommand : IChatCommand</p><p> {</p><p> public string PermissionRequired</p><p> {</p><p> get { return "command_kiss"; }</p><p> }</p><p></p><p> public string Parameters</p><p> {</p><p> get { return "%target%"; }</p><p> }</p><p></p><p> public string Description</p><p> {</p><p> get { return "Give another user a kiss."; }</p><p> }</p><p></p><p> public void Execute(GameClients.GameClient Session, Rooms.Room Room, string[] Params)</p><p> {</p><p> if (Params.Length == 1)</p><p> {</p><p> Session.SendWhisper("Please enter the username of the user you wish to kiss.");</p><p> return;</p><p> }</p><p></p><p> GameClient TargetClient = PlusEnvironment.GetGame().GetClientManager().GetClientByUsername(Params[1]);</p><p> if (TargetClient == null)</p><p> {</p><p> Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online.");</p><p> return;</p><p> }</p><p></p><p> RoomUser TargetUser = Room.GetRoomUserManager().GetRoomUserByHabbo(TargetClient.GetHabbo().Id);</p><p> if (TargetUser == null)</p><p> {</p><p> Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online or in this room.");</p><p> return;</p><p> }</p><p></p><p> if (TargetClient.GetHabbo().Username == Session.GetHabbo().Username)</p><p> {</p><p> Session.SendWhisper("Come on, you can't kiss yourself!");</p><p> return;</p><p> }</p><p></p><p> RoomUser ThisUser = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id);</p><p> if (ThisUser == null)</p><p> return;</p><p></p><p> if (!((Math.Abs(TargetUser.X - ThisUser.X) >= 2) || (Math.Abs(TargetUser.Y - ThisUser.Y) >= 2)))</p><p> {</p><p> Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "*Kisses " + Params[1] + "*", 0, ThisUser.LastBubble));</p><p> Session.GetHabbo().Effects().ApplyEffect(9);</p><p> TargetClient.GetHabbo().Effects().ApplyEffect(9);</p><p> }</p><p> else</p><p> {</p><p> Session.SendWhisper("Oops, " + Params[1] + " is not close enough!");</p><p> return;</p><p> }</p><p> }</p><p> }</p><p>}[/code]</p><p><strong>Create a new file in HabboHotel/Rooms/Users/Chat/Commands/User/Fun and save it as SexCommand.cs</strong> <em>Credits to [USER=59038]@Altercationz[/USER] </em></p><p>[code]</p><p>using System;</p><p>using System.Linq;</p><p>using System.Text;</p><p>using System.Collections.Generic;</p><p></p><p>using Plus.HabboHotel.Rooms;</p><p>using Plus.HabboHotel.Pathfinding;</p><p>using Plus.HabboHotel.GameClients;</p><p>using Plus.Communication.Packets.Outgoing.Rooms.Chat;</p><p></p><p>namespace Plus.HabboHotel.Rooms.Chat.Commands.User.Fun</p><p>{</p><p> class SexCommand : IChatCommand</p><p> {</p><p> public string PermissionRequired</p><p> {</p><p> get { return "command_sex"; }</p><p> }</p><p> public string Parameters</p><p> {</p><p> get { return "%username%"; }</p><p> }</p><p> public string Description</p><p> {</p><p> get { return "Have sex with another user"; }</p><p> }</p><p> public void Execute(GameClients.GameClient Session, Rooms.Room Room, string[] Params)</p><p> {</p><p> if (Params.Length == 1)</p><p> {</p><p> Session.SendWhisper("Please enter the username of the person you want to have sex with.");</p><p> return;</p><p> }</p><p> GameClient TargetClient = PlusEnvironment.GetGame().GetClientManager().GetClientByUsername(Params[1]);</p><p> if (TargetClient == null)</p><p> {</p><p> Session.SendWhisper("The user was not found in the room, maybe they're offline.");</p><p> return;</p><p> }</p><p> RoomUser TargetUser = Room.GetRoomUserManager().GetRoomUserByHabbo(TargetClient.GetHabbo().Id);</p><p> if (TargetUser == null)</p><p> {</p><p> Session.SendWhisper("An error occured while finding that user, maybe they're offline or not in this room.");</p><p> }</p><p> if (TargetClient.GetHabbo().Username == Session.GetHabbo().Username)</p><p> {</p><p> Session.SendWhisper("You cannot have sex with yourself!");</p><p> return;</p><p> }</p><p> RoomUser ThisUser = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id);</p><p> if (ThisUser == null)</p><p> return;</p><p></p><p> if (!((Math.Abs(TargetUser.X - ThisUser.X) >= 2) || (Math.Abs(TargetUser.Y - ThisUser.Y) >= 2)))</p><p> {</p><p> Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "*Bends " + Params[1] + " over and starts to have sex with them*", 0, ThisUser.LastBubble));</p><p> System.Threading.Thread.Sleep(1000);</p><p> Room.SendMessage(new ChatComposer(TargetUser.VirtualId, "Gets bent over and starts to have sex with " + Session.GetHabbo().Username + "*", 0, ThisUser.LastBubble));</p><p> System.Threading.Thread.Sleep(1000);</p><p> Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "Slap's " + Params[1] + "'s ass and pulls their hair*", 0, ThisUser.LastBubble));</p><p> System.Threading.Thread.Sleep(1000);</p><p> Room.SendMessage(new ChatComposer(TargetUser.VirtualId, "Climaxes and sprays juice all over the place", 0, ThisUser.LastBubble));</p><p> System.Threading.Thread.Sleep(1000);</p><p> Room.SendMessage(new ChatComposer(TargetUser.VirtualId, "Collapses onto the floor, tired and worn out.", 0, ThisUser.LastBubble));</p><p> TargetUser.Statusses.Add("lay", "0.1");</p><p> TargetUser.isLying = true;</p><p> TargetUser.UpdateNeeded = true;</p><p> }</p><p> else</p><p> {</p><p> Session.SendWhisper("Oops, " + Params[1] + " is not close enough!");</p><p> return;</p><p> }</p><p> }</p><p> }</p><p>}[/code]</p><p><strong>Create a new file in HabboHotel/Rooms/Users/Chat/Commands/User/Fun and save it as CutCommand.cs</strong></p><p>[code]</p><p>using System;</p><p>using System.Linq;</p><p>using System.Text;</p><p>using System.Collections.Generic;</p><p></p><p>using Plus.HabboHotel.Rooms;</p><p>using Plus.HabboHotel.Pathfinding;</p><p>using Plus.HabboHotel.GameClients;</p><p>using Plus.Communication.Packets.Outgoing.Rooms.Chat;</p><p></p><p>namespace Plus.HabboHotel.Rooms.Chat.Commands.User.Fun</p><p>{</p><p> class CutCommand : IChatCommand</p><p> {</p><p> public string PermissionRequired</p><p> {</p><p> get { return "command_cut"; }</p><p> }</p><p></p><p> public string Parameters</p><p> {</p><p> get { return "%target%"; }</p><p> }</p><p></p><p> public string Description</p><p> {</p><p> get { return "Chop off another users head off!"; }</p><p> }</p><p></p><p> public void Execute(GameClients.GameClient Session, Rooms.Room Room, string[] Params)</p><p> {</p><p> if (Params.Length == 1)</p><p> {</p><p> Session.SendWhisper("Please enter the username of the user that you wish to chop the head off.");</p><p> return;</p><p> }</p><p></p><p> GameClient TargetClient = PlusEnvironment.GetGame().GetClientManager().GetClientByUsername(Params[1]);</p><p> if (TargetClient == null)</p><p> {</p><p> Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online.");</p><p> return;</p><p> }</p><p></p><p> RoomUser TargetUser = Room.GetRoomUserManager().GetRoomUserByHabbo(TargetClient.GetHabbo().Id);</p><p> if (TargetUser == null)</p><p> {</p><p> Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online or in this room.");</p><p> return;</p><p> }</p><p></p><p> if (TargetClient.GetHabbo().Username == Session.GetHabbo().Username)</p><p> {</p><p> Session.SendWhisper("Come on, you don't want to do that!");</p><p> return;</p><p> }</p><p></p><p> RoomUser ThisUser = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id);</p><p> if (ThisUser == null)</p><p> return;</p><p></p><p> if (!((Math.Abs(TargetUser.X - ThisUser.X) >= 2) || (Math.Abs(TargetUser.Y - ThisUser.Y) >= 2)))</p><p> {</p><p> Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "*Chops off " + Params[1] + "'s head*", 0, ThisUser.LastBubble));</p><p> TargetClient.GetHabbo().Effects().ApplyEffect(93);</p><p> Session.GetHabbo().Effects().ApplyEffect(117);</p><p> System.Threading.Thread.Sleep(1500);</p><p> Session.GetHabbo().Effects().ApplyEffect(0);</p><p> }</p><p> else</p><p> {</p><p> Session.SendWhisper("Oops, " + Params[1] + " is not close enough!");</p><p> return;</p><p> }</p><p> }</p><p> }</p><p>}[/code]</p><p>[/spoiler]</p><p>Now that you have your commands made now it's time to register them as actual commands.</p><p>[spoiler=Registering the commands]</p><p><strong>Go into HabboHotel/Rooms/Chat/Commands/CommandManager.cs and open up that file.</strong></p><p><strong>Scroll through the file until you find;</strong></p><p>[code]</p><p> private void RegisterUser()</p><p> {</p><p> this.Register("about", new InfoCommand());</p><p> this.Register("pickall", new PickAllCommand());</p><p> this.Register("ejectall", new EjectAllCommand());</p><p> this.Register("lay", new LayCommand());</p><p> this.Register("sit", new SitCommand());</p><p> this.Register("stand", new StandCommand());</p><p> this.Register("mutepets", new MutePetsCommand());</p><p> this.Register("mutebots", new MuteBotsCommand());</p><p></p><p> this.Register("mimic", new MimicCommand());</p><p> this.Register("dance", new DanceCommand());</p><p> this.Register("push", new PushCommand());</p><p> this.Register("pull", new PullCommand());</p><p> this.Register("enable", new EnableCommand());</p><p> this.Register("follow", new FollowCommand());</p><p> this.Register("faceless", new FacelessCommand());</p><p> this.Register("moonwalk", new MoonwalkCommand());</p><p></p><p> this.Register("unload", new UnloadCommand());</p><p> this.Register("regenmaps", new RegenMaps());</p><p> this.Register("emptyitems", new EmptyItems());</p><p> this.Register("setmax", new SetMaxCommand());</p><p> this.Register("setspeed", new SetSpeedCommand());</p><p> this.Register("disablediagonal", new DisableDiagonalCommand());</p><p> this.Register("flagme", new FlagMeCommand());</p><p></p><p> this.Register("stats", new StatsCommand());</p><p> this.Register("kickpets", new KickPetsCommand());</p><p> this.Register("kickbots", new KickBotsCommand());</p><p></p><p> this.Register("room", new RoomCommand());</p><p> this.Register("dnd", new DNDCommand());</p><p> this.Register("disablegifts", new DisableGiftsCommand());</p><p> this.Register("convertcredits", new ConvertCreditsCommand());</p><p> this.Register("disablewhispers", new DisableWhispersCommand());</p><p> this.Register("disablemimic", new DisableMimicCommand()); ;</p><p></p><p> this.Register("pet", new PetCommand());</p><p> this.Register("spush", new SuperPushCommand());</p><p> this.Register("superpush", new SuperPushCommand());</p><p> }[/code]</p><p><strong>Insert the following somewhere in the void RegisterUser;</strong></p><p>[code]</p><p> this.Register("kiss", new KissCommand());</p><p> this.Register("sex", new SexCommand());</p><p> this.Register("cut", new CutCommand());</p><p>[/code]</p><p><strong>Where it says </strong><em>"kiss"</em>, <em>"sex"</em>, <em>"cut" </em><strong>that is what the user will type into the client to use the command so for example you could have;</strong></p><p>[code]</p><p> this.Register("cut", new CutCommand());</p><p> this.Register("behead", new CutCommand());</p><p>[/code]</p><p><strong>Which allows the user to use either </strong><em>":cut x"</em>, <em>:behead x"</em> <strong>to use the command</strong></p><p>[/spoiler]</p><p>Now all that is left is to give the users permissions to use the commands</p><p>[spoiler=Creating the permissions]</p><p><strong>Open your database and run the query below</strong> <em>You may edit it to your liking</em></p><p>[code]</p><p>INSERT INTO `permissions_commands` (`command`, `group_id`, `subscription_id`) VALUES ('command_cut', '1', '0');</p><p>INSERT INTO `permissions_commands` (`command`, `group_id`, `subscription_id`) VALUES ('command_kiss', '1', '0');</p><p>INSERT INTO `permissions_commands` (`command`, `group_id`, `subscription_id`) VALUES ('command_sex', '1', '0');</p><p>[/code]<strong>This is assuming you want all users to be able to use those commands</strong> <em>If they are VIP commands change the 0 to either Silver VIP - 1, Gold VIP - 2, Event Staff - 3</em>[/spoiler]Now debug then restart your emulator and the commands should be working.</p><p></p><p>PM me if you get any other issues concerning the commands.</p><p>As for your ModTools I have no idea how to fix that, sorry.</p></blockquote><p></p>
[QUOTE="Kods, post: 367978, member: 62226"] I'm unsure if you know exactly how to implement the commands if not just follow the spoilers. First you need to create and save your commands into the emulator. [spoiler=Creating the commands] [B]Create a new file in HabboHotel/Rooms/Users/Chat/Commands/User/Fun and save it as KissCommand.cs[/B] [code] using System; using System.Linq; using System.Text; using System.Collections.Generic; using Plus.HabboHotel.Rooms; using Plus.HabboHotel.Pathfinding; using Plus.HabboHotel.GameClients; using Plus.Communication.Packets.Outgoing.Rooms.Chat; namespace Plus.HabboHotel.Rooms.Chat.Commands.User.Fun { class KissCommand : IChatCommand { public string PermissionRequired { get { return "command_kiss"; } } public string Parameters { get { return "%target%"; } } public string Description { get { return "Give another user a kiss."; } } public void Execute(GameClients.GameClient Session, Rooms.Room Room, string[] Params) { if (Params.Length == 1) { Session.SendWhisper("Please enter the username of the user you wish to kiss."); return; } GameClient TargetClient = PlusEnvironment.GetGame().GetClientManager().GetClientByUsername(Params[1]); if (TargetClient == null) { Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online."); return; } RoomUser TargetUser = Room.GetRoomUserManager().GetRoomUserByHabbo(TargetClient.GetHabbo().Id); if (TargetUser == null) { Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online or in this room."); return; } if (TargetClient.GetHabbo().Username == Session.GetHabbo().Username) { Session.SendWhisper("Come on, you can't kiss yourself!"); return; } RoomUser ThisUser = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id); if (ThisUser == null) return; if (!((Math.Abs(TargetUser.X - ThisUser.X) >= 2) || (Math.Abs(TargetUser.Y - ThisUser.Y) >= 2))) { Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "*Kisses " + Params[1] + "*", 0, ThisUser.LastBubble)); Session.GetHabbo().Effects().ApplyEffect(9); TargetClient.GetHabbo().Effects().ApplyEffect(9); } else { Session.SendWhisper("Oops, " + Params[1] + " is not close enough!"); return; } } } }[/code] [B]Create a new file in HabboHotel/Rooms/Users/Chat/Commands/User/Fun and save it as SexCommand.cs[/B] [I]Credits to [USER=59038]@Altercationz[/USER] [/I] [code] using System; using System.Linq; using System.Text; using System.Collections.Generic; using Plus.HabboHotel.Rooms; using Plus.HabboHotel.Pathfinding; using Plus.HabboHotel.GameClients; using Plus.Communication.Packets.Outgoing.Rooms.Chat; namespace Plus.HabboHotel.Rooms.Chat.Commands.User.Fun { class SexCommand : IChatCommand { public string PermissionRequired { get { return "command_sex"; } } public string Parameters { get { return "%username%"; } } public string Description { get { return "Have sex with 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 have sex with."); return; } GameClient TargetClient = PlusEnvironment.GetGame().GetClientManager().GetClientByUsername(Params[1]); if (TargetClient == null) { Session.SendWhisper("The user was not found in the room, maybe they're offline."); 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 have sex with yourself!"); return; } RoomUser ThisUser = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id); if (ThisUser == null) return; if (!((Math.Abs(TargetUser.X - ThisUser.X) >= 2) || (Math.Abs(TargetUser.Y - ThisUser.Y) >= 2))) { Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "*Bends " + Params[1] + " over and starts to have sex with them*", 0, ThisUser.LastBubble)); System.Threading.Thread.Sleep(1000); Room.SendMessage(new ChatComposer(TargetUser.VirtualId, "Gets bent over and starts to have sex with " + Session.GetHabbo().Username + "*", 0, ThisUser.LastBubble)); System.Threading.Thread.Sleep(1000); Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "Slap's " + Params[1] + "'s ass and pulls their hair*", 0, ThisUser.LastBubble)); System.Threading.Thread.Sleep(1000); Room.SendMessage(new ChatComposer(TargetUser.VirtualId, "Climaxes and sprays juice all over the place", 0, ThisUser.LastBubble)); System.Threading.Thread.Sleep(1000); Room.SendMessage(new ChatComposer(TargetUser.VirtualId, "Collapses onto the floor, tired and worn out.", 0, ThisUser.LastBubble)); TargetUser.Statusses.Add("lay", "0.1"); TargetUser.isLying = true; TargetUser.UpdateNeeded = true; } else { Session.SendWhisper("Oops, " + Params[1] + " is not close enough!"); return; } } } }[/code] [B]Create a new file in HabboHotel/Rooms/Users/Chat/Commands/User/Fun and save it as CutCommand.cs[/B] [code] using System; using System.Linq; using System.Text; using System.Collections.Generic; using Plus.HabboHotel.Rooms; using Plus.HabboHotel.Pathfinding; using Plus.HabboHotel.GameClients; using Plus.Communication.Packets.Outgoing.Rooms.Chat; namespace Plus.HabboHotel.Rooms.Chat.Commands.User.Fun { class CutCommand : IChatCommand { public string PermissionRequired { get { return "command_cut"; } } public string Parameters { get { return "%target%"; } } public string Description { get { return "Chop off another users head off!"; } } public void Execute(GameClients.GameClient Session, Rooms.Room Room, string[] Params) { if (Params.Length == 1) { Session.SendWhisper("Please enter the username of the user that you wish to chop the head off."); return; } GameClient TargetClient = PlusEnvironment.GetGame().GetClientManager().GetClientByUsername(Params[1]); if (TargetClient == null) { Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online."); return; } RoomUser TargetUser = Room.GetRoomUserManager().GetRoomUserByHabbo(TargetClient.GetHabbo().Id); if (TargetUser == null) { Session.SendWhisper("An error occoured whilst finding that user, maybe they're not online or in this room."); return; } if (TargetClient.GetHabbo().Username == Session.GetHabbo().Username) { Session.SendWhisper("Come on, you don't want to do that!"); return; } RoomUser ThisUser = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id); if (ThisUser == null) return; if (!((Math.Abs(TargetUser.X - ThisUser.X) >= 2) || (Math.Abs(TargetUser.Y - ThisUser.Y) >= 2))) { Room.SendMessage(new ChatComposer(ThisUser.VirtualId, "*Chops off " + Params[1] + "'s head*", 0, ThisUser.LastBubble)); TargetClient.GetHabbo().Effects().ApplyEffect(93); Session.GetHabbo().Effects().ApplyEffect(117); System.Threading.Thread.Sleep(1500); Session.GetHabbo().Effects().ApplyEffect(0); } else { Session.SendWhisper("Oops, " + Params[1] + " is not close enough!"); return; } } } }[/code] [/spoiler] Now that you have your commands made now it's time to register them as actual commands. [spoiler=Registering the commands] [B]Go into HabboHotel/Rooms/Chat/Commands/CommandManager.cs and open up that file. Scroll through the file until you find;[/B] [code] private void RegisterUser() { this.Register("about", new InfoCommand()); this.Register("pickall", new PickAllCommand()); this.Register("ejectall", new EjectAllCommand()); this.Register("lay", new LayCommand()); this.Register("sit", new SitCommand()); this.Register("stand", new StandCommand()); this.Register("mutepets", new MutePetsCommand()); this.Register("mutebots", new MuteBotsCommand()); this.Register("mimic", new MimicCommand()); this.Register("dance", new DanceCommand()); this.Register("push", new PushCommand()); this.Register("pull", new PullCommand()); this.Register("enable", new EnableCommand()); this.Register("follow", new FollowCommand()); this.Register("faceless", new FacelessCommand()); this.Register("moonwalk", new MoonwalkCommand()); this.Register("unload", new UnloadCommand()); this.Register("regenmaps", new RegenMaps()); this.Register("emptyitems", new EmptyItems()); this.Register("setmax", new SetMaxCommand()); this.Register("setspeed", new SetSpeedCommand()); this.Register("disablediagonal", new DisableDiagonalCommand()); this.Register("flagme", new FlagMeCommand()); this.Register("stats", new StatsCommand()); this.Register("kickpets", new KickPetsCommand()); this.Register("kickbots", new KickBotsCommand()); this.Register("room", new RoomCommand()); this.Register("dnd", new DNDCommand()); this.Register("disablegifts", new DisableGiftsCommand()); this.Register("convertcredits", new ConvertCreditsCommand()); this.Register("disablewhispers", new DisableWhispersCommand()); this.Register("disablemimic", new DisableMimicCommand()); ; this.Register("pet", new PetCommand()); this.Register("spush", new SuperPushCommand()); this.Register("superpush", new SuperPushCommand()); }[/code] [B]Insert the following somewhere in the void RegisterUser;[/B] [code] this.Register("kiss", new KissCommand()); this.Register("sex", new SexCommand()); this.Register("cut", new CutCommand()); [/code] [B]Where it says [/B][I]"kiss"[/I], [I]"sex"[/I], [I]"cut" [/I][B]that is what the user will type into the client to use the command so for example you could have;[/B] [code] this.Register("cut", new CutCommand()); this.Register("behead", new CutCommand()); [/code] [B]Which allows the user to use either [/B][I]":cut x"[/I], [I]:behead x"[/I] [B]to use the command[/B] [/spoiler] Now all that is left is to give the users permissions to use the commands [spoiler=Creating the permissions] [B]Open your database and run the query below[/B] [I]You may edit it to your liking[/I] [code] INSERT INTO `permissions_commands` (`command`, `group_id`, `subscription_id`) VALUES ('command_cut', '1', '0'); INSERT INTO `permissions_commands` (`command`, `group_id`, `subscription_id`) VALUES ('command_kiss', '1', '0'); INSERT INTO `permissions_commands` (`command`, `group_id`, `subscription_id`) VALUES ('command_sex', '1', '0'); [/code][B]This is assuming you want all users to be able to use those commands[/B] [I]If they are VIP commands change the 0 to either Silver VIP - 1, Gold VIP - 2, Event Staff - 3[/I][/spoiler]Now debug then restart your emulator and the commands should be working. PM me if you get any other issues concerning the commands. As for your ModTools I have no idea how to fix that, sorry. [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Q&A
Boon Emulator Issues! + Custom Commands
Top