public override void HandleMessage(Yupi.Model.Domain.Habbo session, Yupi.Protocol.Buffers.ClientMessage message,
                                           Yupi.Protocol.IRouter router)
        {
            if (!session.Info.HasPermission("fuse_mod"))
            {
                return;
            }

            message.GetInteger(); // TODO Unused
            int ticketId = message.GetInteger();

            SupportTicket ticket = TicketRepository.Find(ticketId);

            if (ticket == null || ticket.Status != TicketStatus.Closed)
            {
                return;
            }

            ticket.Pick(session.Info);

            TicketRepository.Save(ticket);

            foreach (Habbo staff in ClientManager.GetByPermission("handle_cfh"))
            {
                staff.Router.GetComposer <ModerationToolIssueMessageComposer>().Compose(staff, ticket);
            }
        }
Ejemplo n.º 2
0
        public void Handle(GameClient session, ClientMessage message)
        {
            int amount = message.PopWiredInt32(); //amount

            for (int i = 0; i < amount; i++)
            {
                uint          ticketId = message.PopWiredUInt(); //ticket id
                SupportTicket ticket   = Skylight.GetGame().GetModerationToolManager().TryGetSupportTicket(ticketId);
                if (ticket != null && ticket.Status == SupportTicketStatus.Open)
                {
                    ticket.Pick(session, true);
                    Skylight.GetGame().GetModerationToolManager().SerializeSupportTicketToMods(ticket);
                }
            }

            //message.PopWiredBoolean(); //retry enabled
            //message.PopWiredInt32(); //retry count
        }