2018-07-06 15:30:00 +02:00
|
|
|
package com.eu.habbo.messages.incoming.modtool;
|
|
|
|
|
|
|
|
import com.eu.habbo.Emulator;
|
|
|
|
import com.eu.habbo.habbohotel.modtool.ModToolIssue;
|
2018-09-12 18:45:00 +02:00
|
|
|
import com.eu.habbo.habbohotel.permissions.Permission;
|
2018-07-06 15:30:00 +02:00
|
|
|
import com.eu.habbo.messages.incoming.MessageHandler;
|
|
|
|
import com.eu.habbo.threading.runnables.UpdateModToolIssue;
|
|
|
|
|
2019-05-26 20:14:53 +02:00
|
|
|
public class ModToolIssueChangeTopicEvent extends MessageHandler {
|
2018-07-06 15:30:00 +02:00
|
|
|
@Override
|
2019-05-26 20:14:53 +02:00
|
|
|
public void handle() throws Exception {
|
|
|
|
if (this.client.getHabbo().hasPermission(Permission.ACC_SUPPORTTOOL)) {
|
2018-07-06 15:30:00 +02:00
|
|
|
int ticketId = this.packet.readInt();
|
|
|
|
int unknownInt = this.packet.readInt();
|
|
|
|
int categoryId = this.packet.readInt();
|
|
|
|
|
|
|
|
ModToolIssue issue = Emulator.getGameEnvironment().getModToolManager().getTicket(ticketId);
|
|
|
|
|
2019-05-26 20:14:53 +02:00
|
|
|
if (issue != null) {
|
2018-07-06 15:30:00 +02:00
|
|
|
issue.category = categoryId;
|
|
|
|
new UpdateModToolIssue(issue).run();
|
|
|
|
Emulator.getGameEnvironment().getModToolManager().updateTicketToMods(issue);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|