• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

[Basic Interaction] Waterbowl - Plus EMU

Newbie Spellweaver
Joined
Feb 11, 2017
Messages
18
Reaction score
16
Hello,
(Sorry the code is badly displayed but it is good, it is essential)
1. Create InteractorWaterBowl.cs in Interactor Folder (in PlusEMU)

2. Copy/Paste this code (if you have error, adjust code or send me private message)

Code:
using Plus.HabboHotel.GameClients;using Plus.HabboHotel.Rooms;namespace Plus.HabboHotel.Items.Interactor{    public class InteractorWaterBowl : IFurniInteractor    {        public void BeforeRoomLoad(Item Item)        {        }        public void OnPlace(GameClient Session, Item Item)        {            Item.ExtraData = "0";            Item.UpdateNeeded = true;        }        public void OnRemove(GameClient Session, Item Item)        {            Item.ExtraData = "0";        }        public void OnTrigger(GameClient Session, Item Item, int Request, bool HasRights)        {            if (!HasRights)            {                return;            }            RoomUser User = null;            if (Session != null)                User = Item.GetRoom().GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id);            if (User == null)                return;            if (!Gamemap.TilesTouching(Item.GetX, Item.GetY, User.X, User.Y))            {                User.MoveTo(Item.GetX, Item.GetY);            }            Item.ExtraData = "5";            Item.UpdateState(false, true);        }        public void OnWiredTrigger(Item Item)        {            if (Item.ExtraData != "0")            {                Item.ExtraData = "0";                Item.UpdateState(false, true);                Item.RequestUpdate(10, true);            }        }    }}

3. Go to InteractionType.cs and create InteractorWaterBowl....

4. Go to Item.cs and search "case InteractionType.GATE:"

5. Copy/Paste code after
"return new InteractorGate();"

Code:
case InteractionType.WATERBOWL:                        return new InteractorWaterBowl();

---------------------------------------------------------------------------------------------------------

FXBox : Do the same, with this... Create InteractorFxBox.cs

using Plus.HabboHotel.GameClients;using Plus.HabboHotel.Rooms;namespace Plus.HabboHotel.Items.Interactor{ public class InteractorFxBox : IFurniInteractor { public void BeforeRoomLoad(Item Item) { } public void OnPlace(GameClient Session, Item Item) { Item.ExtraData = "0"; Item.UpdateNeeded = true; } public void OnRemove(GameClient Session, Item Item) { Item.ExtraData = "0"; } public void OnTrigger(GameClient Session, Item Item, int Request, bool HasRights) { Room Room = Session.GetHabbo().CurrentRoom; if (!MithServer.GetGame().GetRoomManager().TryGetRoom(Session.GetHabbo().CurrentRoomId, out Room)) return; if (!HasRights) { return; } if (Item == null || Item.GetBaseItem() == null || !Item.GetBaseItem().ItemName.StartsWith("fxbox_fx")) return; if (Item.GetBaseItem().InteractionType != InteractionType.FXBOX) return; RoomUser User = null; if (Session != null) User = Item.GetRoom().GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id); if (User == null) return; int EffectId = int.Parse(Item.GetBaseItem().ItemName.Replace("fxbox_fx", "")); Session.GetHabbo().Effects().ApplyEffect(EffectId); Room.GetRoomItemHandler().RemoveFurniture(null, Item.Id, false); } public void OnWiredTrigger(Item Item) { } }}
Goodbye, VabboH Hotel.

Note: No need to call this a fixed, let's call it an add-on lol instead.
 
Last edited:
Back
Top