mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2024-11-27 08:50:51 +01:00
remove hardcoded int GuildMembershipRejectedMessageComposer
This commit is contained in:
parent
16f0a61932
commit
49550f3a76
@ -35,7 +35,7 @@ public class KickMemberEvent extends MessageHandler {
|
|||||||
guild.decreaseMemberCount();
|
guild.decreaseMemberCount();
|
||||||
|
|
||||||
if (userId != this.client.getHabbo().getHabboInfo().getId()) {
|
if (userId != this.client.getHabbo().getHabboInfo().getId()) {
|
||||||
this.client.sendResponse(new GuildMembershipRejectedMessageComposer(guild));
|
this.client.sendResponse(new GuildMembershipRejectedMessageComposer(guild, userId));
|
||||||
}
|
}
|
||||||
|
|
||||||
Room room = Emulator.getGameEnvironment().getRoomManager().loadRoom(guild.getRoomId());
|
Room room = Emulator.getGameEnvironment().getRoomManager().loadRoom(guild.getRoomId());
|
||||||
|
@ -27,7 +27,7 @@ public class RejectMembershipRequestEvent extends MessageHandler {
|
|||||||
guild.decreaseRequestCount();
|
guild.decreaseRequestCount();
|
||||||
Emulator.getGameEnvironment().getGuildManager().removeMember(guild, userId);
|
Emulator.getGameEnvironment().getGuildManager().removeMember(guild, userId);
|
||||||
this.client.sendResponse(new GuildMembersComposer(guild, Emulator.getGameEnvironment().getGuildManager().getGuildMembers(guild, 0, 0, ""), this.client.getHabbo(), 0, 0, "", true, Emulator.getGameEnvironment().getGuildManager().getGuildMembersCount(guild, 0, 0, "")));
|
this.client.sendResponse(new GuildMembersComposer(guild, Emulator.getGameEnvironment().getGuildManager().getGuildMembers(guild, 0, 0, ""), this.client.getHabbo(), 0, 0, "", true, Emulator.getGameEnvironment().getGuildManager().getGuildMembersCount(guild, 0, 0, "")));
|
||||||
this.client.sendResponse(new GuildMembershipRejectedMessageComposer(guild));
|
this.client.sendResponse(new GuildMembershipRejectedMessageComposer(guild, userId));
|
||||||
|
|
||||||
Habbo habbo = Emulator.getGameEnvironment().getHabboManager().getHabbo(userId);
|
Habbo habbo = Emulator.getGameEnvironment().getHabboManager().getHabbo(userId);
|
||||||
Emulator.getPluginManager().fireEvent(new GuildDeclinedMembershipEvent(guild, userId, habbo, this.client.getHabbo()));
|
Emulator.getPluginManager().fireEvent(new GuildDeclinedMembershipEvent(guild, userId, habbo, this.client.getHabbo()));
|
||||||
|
@ -7,16 +7,18 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class GuildMembershipRejectedMessageComposer extends MessageComposer {
|
public class GuildMembershipRejectedMessageComposer extends MessageComposer {
|
||||||
private final Guild guild;
|
private final Guild guild;
|
||||||
|
private final Integer userId;
|
||||||
|
|
||||||
public GuildMembershipRejectedMessageComposer(Guild guild) {
|
public GuildMembershipRejectedMessageComposer(Guild guild, int userId) {
|
||||||
this.guild = guild;
|
this.guild = guild;
|
||||||
|
this.userId = userId;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected ServerMessage composeInternal() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.GuildMembershipRejectedMessageComposer);
|
this.response.init(Outgoing.GuildMembershipRejectedMessageComposer);
|
||||||
this.response.appendInt(this.guild.getId());
|
this.response.appendInt(this.guild.getId());
|
||||||
this.response.appendInt(0);
|
this.response.appendInt(this.userId);
|
||||||
return this.response;
|
return this.response;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user