Hi I'm trying to make so that the user can get users to get notifited when they have used a dice but when I do it shows me not the number directly but the number before and when It's closed and I use the dice and open it up it gives me 0.
Here is the code:
Pictures:
So what is it im trying to get it to?: I'm trying to make it so that it shows me the number they rolled and not the number before. And also that it doesn't show the number 0 when I roll open the dice.
Here is the code:
using System;
using System.Linq;
using System.Text;
using System.Collections.Generic;
using Plus.HabboHotel.Rooms;
using Plus.HabboHotel.Items;
namespace Plus.Communication.Packets.Incoming.Rooms.Furni
{
class ThrowDiceEvent : IPacketEvent
{
public void Parse(HabboHotel.GameClients.GameClient Session, ClientPacket Packet)
{
Room Room = Session.GetHabbo().CurrentRoom;
if (Room == null)
return;
Session.SendWhisper(Session.GetHabbo().Username + " has rolled number " + Convert.ToString(Item.ExtraData));
Item Item = Room.GetRoomItemHandler().GetItem(Packet.PopInt());
if (Item == null)
return;
Boolean hasRights = false;
if (Room.CheckRights(Session, false, true))
hasRights = true;
int request = Packet.PopInt();
Item.Interactor.OnTrigger(Session, Item, request, hasRights);
}
}
}
Pictures:
You must be registered for see images attach
You must be registered for see images attach
So what is it im trying to get it to?: I'm trying to make it so that it shows me the number they rolled and not the number before. And also that it doesn't show the number 0 when I roll open the dice.