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 Releases
Server Releases
Command :rob [Plus aka. Bios Emulator]
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="onepoint" data-source="post: 435314" data-attributes="member: 46428"><p>I have create a roleplay command with this you can rob a user.</p><p></p><p>[CODE]</p><p>/*</p><p>* CommandManager.cs</p><p>*/</p><p>this.Register("raub", new RaubCommand()); // Coded by Nightmare[/CODE]</p><p></p><p>[CODE]/*</p><p>Create a RaubCommand.cs and insert this</p><p>*/</p><p>using System;</p><p>using Bios.HabboHotel.GameClients;</p><p>using Bios.Communication.Packets.Outgoing.Rooms.Chat;</p><p>using Bios.Communication.Packets.Outgoing.Inventory.Purse;</p><p>using Bios.Communication.Packets.Outgoing.Rooms.Avatar;</p><p> </p><p> </p><p>namespace Bios.HabboHotel.Rooms.Chat.Commands.User.Fun</p><p>{</p><p> class RaubCommand : IChatCommand</p><p> {</p><p> public string PermissionRequired => "command_raub";</p><p> public string Parameters => "[USARIO]";</p><p> public string Description => "Beklaue ein User";</p><p> </p><p> public void Execute(GameClient Session, Room Room, string[] Params)</p><p> {</p><p> if (Params.Length == 1)</p><p> {</p><p> Session.SendWhisper("Bitte geben Sie den Usernamen ein!");</p><p> return;</p><p> }</p><p> GameClient Target = BiosEmuThiago.GetGame().GetClientManager().GetClientByUsername(Params[1]);</p><p> if (Target == null)</p><p> {</p><p> Session.SendWhisper("Entschuldigung, wir haben diesen Benutzer nicht gefunden!");</p><p> return;</p><p> }</p><p> else</p><p> {</p><p> RoomUser TargetID = Room.GetRoomUserManager().GetRoomUserByHabbo(Target.GetHabbo().Id);</p><p> RoomUser User = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id);</p><p> if (TargetID == null)</p><p> {</p><p> Session.LogsNotif("Entschuldigung, der Benutzer ist nicht im Raum!", "command_notification");</p><p> return;</p><p> }</p><p> else if (Target.GetHabbo().Username == Session.GetHabbo().Username)</p><p> {</p><p> Session.SendWhisper("Du kannst dich nicht selber beklauen.");</p><p> Room.SendMessage(new ChatComposer(User.VirtualId, "Helft dieser verwirrten Maus, sie möchte sich selbst beklauen!", 0, 34));</p><p> return;</p><p> }</p><p>RoomUser Habbo = Room.GetRoomUserManager().GetRoomUserByHabbo(Target.GetHabbo().Id);</p><p> else if (Habbo.IsAsleep != true) {</p><p> Session.LogsNotif("Der Benutzer hat den Schutz aktiviert!", "command_notification");</p><p> return;</p><p> }</p><p> else</p><p> {</p><p> if (User != null)</p><p> {</p><p> if ((Math.Abs((int)(TargetID.X - User.X)) < 2) && (Math.Abs((int)(TargetID.Y - User.Y)) < 2))</p><p> {</p><p> RoomUser Habbo = Room.GetRoomUserManager().GetRoomUserByHabbo(Target.GetHabbo().Id);</p><p> if (Habbo.IsAsleep == false) {</p><p> if (Target.GetHabbo().Credits >= 4000)</p><p> {</p><p> </p><p> Random rnd = new Random();</p><p> int random = rnd.Next(300, 3000);</p><p> </p><p> int Amount = random;</p><p> </p><p> Target.GetHabbo().Credits = Target.GetHabbo().Credits -= Amount;</p><p> Target.SendMessage(new CreditBalanceComposer(Target.GetHabbo().Credits));</p><p> </p><p> Session.GetHabbo().Credits = Session.GetHabbo().Credits += Amount;</p><p> Session.SendMessage(new CreditBalanceComposer(Session.GetHabbo().Credits));</p><p> </p><p> </p><p> Room.SendMessage(new ChatComposer(User.VirtualId, " Du hast ihm " + Amount + " Taler geklaut ", 0, 16));</p><p> Room.SendMessage(new ChatComposer(TargetID.VirtualId, "Dir wurden " + Amount + " Taler geklaut ", 0, 16));</p><p> }</p><p> else</p><p> {</p><p> Session.SendWhisper("Der User ist pleite.");</p><p> }</p><p> }</p><p> else</p><p> {</p><p> Session.SendWhisper("Der User ist im AFK Modus du kannst ihn nicht beklauen.");</p><p> }</p><p> }</p><p> else</p><p> {</p><p> Session.SendWhisper("Hoppla!Der Benutzer ist nicht in Ihrer Nähe.!");</p><p> return;</p><p> }</p><p> }</p><p> }</p><p> }</p><p> }</p><p> </p><p> }</p><p> </p><p>}[/CODE]</p><p></p><p>SQL QUERY: INSERT INTO permissions_commands VALUES ('command_raub', '1', '0');</p><p></p><p>This command works together with the afk command.</p><p>Sorry for my english, I'm from germany ^^.</p><p>Best regards</p><p>- Nightmare</p></blockquote><p></p>
[QUOTE="onepoint, post: 435314, member: 46428"] I have create a roleplay command with this you can rob a user. [CODE] /* * CommandManager.cs */ this.Register("raub", new RaubCommand()); // Coded by Nightmare[/CODE] [CODE]/* Create a RaubCommand.cs and insert this */ using System; using Bios.HabboHotel.GameClients; using Bios.Communication.Packets.Outgoing.Rooms.Chat; using Bios.Communication.Packets.Outgoing.Inventory.Purse; using Bios.Communication.Packets.Outgoing.Rooms.Avatar; namespace Bios.HabboHotel.Rooms.Chat.Commands.User.Fun { class RaubCommand : IChatCommand { public string PermissionRequired => "command_raub"; public string Parameters => "[USARIO]"; public string Description => "Beklaue ein User"; public void Execute(GameClient Session, Room Room, string[] Params) { if (Params.Length == 1) { Session.SendWhisper("Bitte geben Sie den Usernamen ein!"); return; } GameClient Target = BiosEmuThiago.GetGame().GetClientManager().GetClientByUsername(Params[1]); if (Target == null) { Session.SendWhisper("Entschuldigung, wir haben diesen Benutzer nicht gefunden!"); return; } else { RoomUser TargetID = Room.GetRoomUserManager().GetRoomUserByHabbo(Target.GetHabbo().Id); RoomUser User = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id); if (TargetID == null) { Session.LogsNotif("Entschuldigung, der Benutzer ist nicht im Raum!", "command_notification"); return; } else if (Target.GetHabbo().Username == Session.GetHabbo().Username) { Session.SendWhisper("Du kannst dich nicht selber beklauen."); Room.SendMessage(new ChatComposer(User.VirtualId, "Helft dieser verwirrten Maus, sie möchte sich selbst beklauen!", 0, 34)); return; } RoomUser Habbo = Room.GetRoomUserManager().GetRoomUserByHabbo(Target.GetHabbo().Id); else if (Habbo.IsAsleep != true) { Session.LogsNotif("Der Benutzer hat den Schutz aktiviert!", "command_notification"); return; } else { if (User != null) { if ((Math.Abs((int)(TargetID.X - User.X)) < 2) && (Math.Abs((int)(TargetID.Y - User.Y)) < 2)) { RoomUser Habbo = Room.GetRoomUserManager().GetRoomUserByHabbo(Target.GetHabbo().Id); if (Habbo.IsAsleep == false) { if (Target.GetHabbo().Credits >= 4000) { Random rnd = new Random(); int random = rnd.Next(300, 3000); int Amount = random; Target.GetHabbo().Credits = Target.GetHabbo().Credits -= Amount; Target.SendMessage(new CreditBalanceComposer(Target.GetHabbo().Credits)); Session.GetHabbo().Credits = Session.GetHabbo().Credits += Amount; Session.SendMessage(new CreditBalanceComposer(Session.GetHabbo().Credits)); Room.SendMessage(new ChatComposer(User.VirtualId, " Du hast ihm " + Amount + " Taler geklaut ", 0, 16)); Room.SendMessage(new ChatComposer(TargetID.VirtualId, "Dir wurden " + Amount + " Taler geklaut ", 0, 16)); } else { Session.SendWhisper("Der User ist pleite."); } } else { Session.SendWhisper("Der User ist im AFK Modus du kannst ihn nicht beklauen."); } } else { Session.SendWhisper("Hoppla!Der Benutzer ist nicht in Ihrer Nähe.!"); return; } } } } } } }[/CODE] SQL QUERY: INSERT INTO permissions_commands VALUES ('command_raub', '1', '0'); This command works together with the afk command. Sorry for my english, I'm from germany ^^. Best regards - Nightmare [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
Server Development
Habbo Retros
Habbo Releases
Server Releases
Command :rob [Plus aka. Bios Emulator]
Top