mirror of
https://git.krews.org/morningstar/Arcturus-Community.git
synced 2024-11-27 08:50:51 +01:00
Fix reference counting and repeated composer() calls.
This commit is contained in:
parent
95fab253d8
commit
f9d81ea198
@ -19,7 +19,7 @@ public class RoomUserPetComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.RoomUsersComposer);
|
this.response.init(Outgoing.RoomUsersComposer);
|
||||||
this.response.appendInt(1);
|
this.response.appendInt(1);
|
||||||
this.response.appendInt(this.habbo.getHabboInfo().getId());
|
this.response.appendInt(this.habbo.getHabboInfo().getId());
|
||||||
|
@ -6,7 +6,6 @@ import com.eu.habbo.habbohotel.permissions.Permission;
|
|||||||
import com.eu.habbo.habbohotel.rooms.*;
|
import com.eu.habbo.habbohotel.rooms.*;
|
||||||
import com.eu.habbo.habbohotel.users.Habbo;
|
import com.eu.habbo.habbohotel.users.Habbo;
|
||||||
import com.eu.habbo.habbohotel.users.HabboItem;
|
import com.eu.habbo.habbohotel.users.HabboItem;
|
||||||
import com.eu.habbo.habbohotel.users.cache.HabboOfferPurchase;
|
|
||||||
import com.eu.habbo.messages.outgoing.generic.alerts.BotErrorComposer;
|
import com.eu.habbo.messages.outgoing.generic.alerts.BotErrorComposer;
|
||||||
import com.eu.habbo.messages.outgoing.generic.alerts.BubbleAlertComposer;
|
import com.eu.habbo.messages.outgoing.generic.alerts.BubbleAlertComposer;
|
||||||
import com.eu.habbo.messages.outgoing.generic.alerts.BubbleAlertKeys;
|
import com.eu.habbo.messages.outgoing.generic.alerts.BubbleAlertKeys;
|
||||||
|
@ -87,14 +87,7 @@ public class GameClient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void sendResponse(MessageComposer composer) {
|
public void sendResponse(MessageComposer composer) {
|
||||||
if (this.channel.isOpen()) {
|
this.sendResponse(composer.compose());
|
||||||
try {
|
|
||||||
this.channel.write(composer.compose().retain(), this.channel.voidPromise());
|
|
||||||
this.channel.flush();
|
|
||||||
} catch (Exception e) {
|
|
||||||
LOGGER.error("Caught exception", e);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void sendResponse(ServerMessage response) {
|
public void sendResponse(ServerMessage response) {
|
||||||
|
@ -5,7 +5,6 @@ import com.eu.habbo.messages.ServerMessage;
|
|||||||
import com.eu.habbo.messages.outgoing.MessageComposer;
|
import com.eu.habbo.messages.outgoing.MessageComposer;
|
||||||
import com.eu.habbo.networking.gameserver.GameServerAttributes;
|
import com.eu.habbo.networking.gameserver.GameServerAttributes;
|
||||||
import io.netty.channel.*;
|
import io.netty.channel.*;
|
||||||
import io.netty.util.AttributeKey;
|
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -7,7 +7,6 @@ import com.eu.habbo.habbohotel.rooms.Room;
|
|||||||
import com.eu.habbo.habbohotel.users.HabboGender;
|
import com.eu.habbo.habbohotel.users.HabboGender;
|
||||||
import com.eu.habbo.habbohotel.users.HabboItem;
|
import com.eu.habbo.habbohotel.users.HabboItem;
|
||||||
import com.eu.habbo.habbohotel.users.inventory.EffectsComponent;
|
import com.eu.habbo.habbohotel.users.inventory.EffectsComponent;
|
||||||
import com.eu.habbo.messages.outgoing.inventory.UserEffectsListComposer;
|
|
||||||
import com.eu.habbo.messages.outgoing.rooms.items.RemoveFloorItemComposer;
|
import com.eu.habbo.messages.outgoing.rooms.items.RemoveFloorItemComposer;
|
||||||
import com.eu.habbo.threading.runnables.QueryDeleteHabboItem;
|
import com.eu.habbo.threading.runnables.QueryDeleteHabboItem;
|
||||||
|
|
||||||
|
@ -11,7 +11,6 @@ import com.eu.habbo.habbohotel.wired.WiredEffectType;
|
|||||||
import com.eu.habbo.messages.ServerMessage;
|
import com.eu.habbo.messages.ServerMessage;
|
||||||
import com.eu.habbo.messages.outgoing.rooms.users.RoomUserStatusComposer;
|
import com.eu.habbo.messages.outgoing.rooms.users.RoomUserStatusComposer;
|
||||||
import gnu.trove.set.hash.THashSet;
|
import gnu.trove.set.hash.THashSet;
|
||||||
import org.apache.commons.math3.util.Pair;
|
|
||||||
|
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
|
@ -9,9 +9,6 @@ import com.eu.habbo.messages.outgoing.rooms.items.FloorItemOnRollerComposer;
|
|||||||
|
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
import java.util.Arrays;
|
|
||||||
import java.util.Comparator;
|
|
||||||
import java.util.Optional;
|
|
||||||
|
|
||||||
public class InteractionPuzzleBox extends HabboItem {
|
public class InteractionPuzzleBox extends HabboItem {
|
||||||
public InteractionPuzzleBox(ResultSet set, Item baseItem) throws SQLException {
|
public InteractionPuzzleBox(ResultSet set, Item baseItem) throws SQLException {
|
||||||
|
@ -16,8 +16,6 @@ import com.eu.habbo.util.pathfinding.Rotation;
|
|||||||
|
|
||||||
import java.sql.ResultSet;
|
import java.sql.ResultSet;
|
||||||
import java.sql.SQLException;
|
import java.sql.SQLException;
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.concurrent.ExecutionException;
|
import java.util.concurrent.ExecutionException;
|
||||||
|
|
||||||
public class InteractionVendingMachine extends HabboItem {
|
public class InteractionVendingMachine extends HabboItem {
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
package com.eu.habbo.habbohotel.modtool;
|
package com.eu.habbo.habbohotel.modtool;
|
||||||
|
|
||||||
import com.eu.habbo.Emulator;
|
import com.eu.habbo.Emulator;
|
||||||
import com.eu.habbo.habbohotel.bots.BotManager;
|
|
||||||
import com.eu.habbo.habbohotel.gameclients.GameClient;
|
import com.eu.habbo.habbohotel.gameclients.GameClient;
|
||||||
import com.eu.habbo.habbohotel.permissions.Permission;
|
import com.eu.habbo.habbohotel.permissions.Permission;
|
||||||
import com.eu.habbo.habbohotel.rooms.Room;
|
import com.eu.habbo.habbohotel.rooms.Room;
|
||||||
|
@ -1,42 +1,43 @@
|
|||||||
package com.eu.habbo.messages;
|
package com.eu.habbo.messages;
|
||||||
|
|
||||||
|
import com.eu.habbo.util.DebugUtils;
|
||||||
import com.eu.habbo.util.PacketUtils;
|
import com.eu.habbo.util.PacketUtils;
|
||||||
import io.netty.buffer.ByteBuf;
|
import io.netty.buffer.ByteBuf;
|
||||||
import io.netty.buffer.ByteBufOutputStream;
|
import io.netty.buffer.ByteBufOutputStream;
|
||||||
import io.netty.buffer.Unpooled;
|
import io.netty.buffer.Unpooled;
|
||||||
|
import io.netty.util.IllegalReferenceCountException;
|
||||||
import io.netty.util.ReferenceCounted;
|
import io.netty.util.ReferenceCounted;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
|
|
||||||
public class ServerMessage implements ReferenceCounted {
|
public class ServerMessage implements ReferenceCounted {
|
||||||
|
|
||||||
private static final Logger LOGGER = LoggerFactory.getLogger(ServerMessage.class);
|
private static final Logger LOGGER = LoggerFactory.getLogger(ServerMessage.class);
|
||||||
|
private boolean initialized;
|
||||||
|
|
||||||
private int header;
|
private int header;
|
||||||
|
private AtomicInteger refs;
|
||||||
private ByteBufOutputStream stream;
|
private ByteBufOutputStream stream;
|
||||||
private ByteBuf channelBuffer;
|
private ByteBuf channelBuffer;
|
||||||
|
|
||||||
public ServerMessage() {
|
public ServerMessage() {
|
||||||
this.channelBuffer = Unpooled.buffer();
|
|
||||||
this.stream = new ByteBufOutputStream(this.channelBuffer);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public ServerMessage(int header) {
|
public ServerMessage(int header) {
|
||||||
this.header = header;
|
this.init(header);
|
||||||
this.channelBuffer = Unpooled.buffer();
|
|
||||||
this.stream = new ByteBufOutputStream(this.channelBuffer);
|
|
||||||
try {
|
|
||||||
this.stream.writeInt(0);
|
|
||||||
this.stream.writeShort(header);
|
|
||||||
} catch (Exception e) {
|
|
||||||
LOGGER.error("ServerMessage exception", e);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public ServerMessage init(int id) {
|
public ServerMessage init(int id) {
|
||||||
|
if (this.initialized) {
|
||||||
|
throw new ServerMessageException("ServerMessage was already initialized.");
|
||||||
|
}
|
||||||
|
|
||||||
this.header = id;
|
this.header = id;
|
||||||
|
this.refs = new AtomicInteger(0);
|
||||||
this.channelBuffer = Unpooled.buffer();
|
this.channelBuffer = Unpooled.buffer();
|
||||||
this.stream = new ByteBufOutputStream(this.channelBuffer);
|
this.stream = new ByteBufOutputStream(this.channelBuffer);
|
||||||
|
|
||||||
@ -44,8 +45,9 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
this.stream.writeInt(0);
|
this.stream.writeInt(0);
|
||||||
this.stream.writeShort(id);
|
this.stream.writeShort(id);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -53,7 +55,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.write(bytes);
|
this.stream.write(bytes);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -68,7 +70,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
this.stream.writeShort(data.length);
|
this.stream.writeShort(data.length);
|
||||||
this.stream.write(data);
|
this.stream.write(data);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -76,7 +78,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeChar(obj);
|
this.stream.writeChar(obj);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -84,7 +86,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeChars(obj.toString());
|
this.stream.writeChars(obj.toString());
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -92,7 +94,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeInt(obj);
|
this.stream.writeInt(obj);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -105,7 +107,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeInt((int) obj);
|
this.stream.writeInt((int) obj);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -113,7 +115,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeInt(obj ? 1 : 0);
|
this.stream.writeInt(obj ? 1 : 0);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -121,7 +123,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeShort((short) obj);
|
this.stream.writeShort((short) obj);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -129,7 +131,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeByte(b);
|
this.stream.writeByte(b);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -137,7 +139,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeBoolean(obj);
|
this.stream.writeBoolean(obj);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -145,7 +147,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeDouble(d);
|
this.stream.writeDouble(d);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -153,7 +155,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.writeDouble(obj);
|
this.stream.writeDouble(obj);
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -161,7 +163,7 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
try {
|
try {
|
||||||
this.stream.write(obj.get().array());
|
this.stream.write(obj.get().array());
|
||||||
} catch (IOException e) {
|
} catch (IOException e) {
|
||||||
LOGGER.error("ServerMessage exception", e);
|
throw new ServerMessageException(e);
|
||||||
}
|
}
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
@ -187,40 +189,64 @@ public class ServerMessage implements ReferenceCounted {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public int refCnt() {
|
public int refCnt() {
|
||||||
return this.channelBuffer.refCnt();
|
return this.refs.get();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ReferenceCounted retain() {
|
public ReferenceCounted retain() {
|
||||||
this.channelBuffer.retain();
|
int result = this.refs.incrementAndGet();
|
||||||
|
|
||||||
|
if (this.header == 1167 || this.header == 2024 || this.header == 2505) {
|
||||||
|
System.out.printf("retain Packet: %d Count: %d From: %s%n", this.header, result, DebugUtils.getCallerCallerStacktrace());
|
||||||
|
}
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ReferenceCounted retain(int i) {
|
public ReferenceCounted retain(int i) {
|
||||||
this.channelBuffer.retain(i);
|
int result = this.refs.addAndGet(i);
|
||||||
|
|
||||||
|
if (this.header == 1167 || this.header == 2024 || this.header == 2505) {
|
||||||
|
System.out.printf("retain Packet: %d Count: %d From: %s%n", this.header, result, DebugUtils.getCallerCallerStacktrace());
|
||||||
|
}
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ReferenceCounted touch() {
|
public ReferenceCounted touch() {
|
||||||
this.channelBuffer.touch();
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ReferenceCounted touch(Object o) {
|
public ReferenceCounted touch(Object o) {
|
||||||
this.channelBuffer.touch(o);
|
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
public boolean release() {
|
public boolean release() {
|
||||||
return this.channelBuffer.release();
|
return this.release(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean release(int i) {
|
public boolean release(int i) {
|
||||||
return this.channelBuffer.release(i);
|
int value = this.refs.addAndGet(-i);
|
||||||
|
|
||||||
|
if (this.header == 1167 || this.header == 2024 || this.header == 2505) {
|
||||||
|
System.out.printf("release Packet: %d Count: %d From: %s%n", this.header, value, DebugUtils.getCallerCallerStacktrace());
|
||||||
|
}
|
||||||
|
|
||||||
|
if (value < 0) {
|
||||||
|
throw new IllegalReferenceCountException("Decremented below 0 (packet " + this.header + " value " + value + ").");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (value == 0) {
|
||||||
|
this.channelBuffer.release();
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -0,0 +1,20 @@
|
|||||||
|
package com.eu.habbo.messages;
|
||||||
|
|
||||||
|
public class ServerMessageException extends RuntimeException {
|
||||||
|
|
||||||
|
public ServerMessageException() {
|
||||||
|
}
|
||||||
|
|
||||||
|
public ServerMessageException(String message) {
|
||||||
|
super(message);
|
||||||
|
}
|
||||||
|
|
||||||
|
public ServerMessageException(String message, Throwable cause) {
|
||||||
|
super(message, cause);
|
||||||
|
}
|
||||||
|
|
||||||
|
public ServerMessageException(Throwable cause) {
|
||||||
|
super(cause);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -4,7 +4,6 @@ import com.eu.habbo.Emulator;
|
|||||||
import com.eu.habbo.habbohotel.guilds.Guild;
|
import com.eu.habbo.habbohotel.guilds.Guild;
|
||||||
import com.eu.habbo.messages.incoming.MessageHandler;
|
import com.eu.habbo.messages.incoming.MessageHandler;
|
||||||
import com.eu.habbo.messages.outgoing.guilds.GuildFavoriteRoomUserUpdateComposer;
|
import com.eu.habbo.messages.outgoing.guilds.GuildFavoriteRoomUserUpdateComposer;
|
||||||
import com.eu.habbo.messages.outgoing.rooms.users.RoomUsersAddGuildBadgeComposer;
|
|
||||||
import com.eu.habbo.messages.outgoing.users.UserProfileComposer;
|
import com.eu.habbo.messages.outgoing.users.UserProfileComposer;
|
||||||
import com.eu.habbo.plugin.events.guilds.GuildRemovedFavoriteEvent;
|
import com.eu.habbo.plugin.events.guilds.GuildRemovedFavoriteEvent;
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ public class IsFirstLoginOfDayComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.IsFirstLoginOfDayComposer);
|
this.response.init(Outgoing.IsFirstLoginOfDayComposer);
|
||||||
this.response.appendBoolean(this.isFirstLoginOfDay);
|
this.response.appendBoolean(this.isFirstLoginOfDay);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class UnknownComposer5 extends MessageComposer {
|
public class UnknownComposer5 extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.UnknownComposer5);
|
this.response.init(Outgoing.UnknownComposer5);
|
||||||
this.response.appendString(""); //Box color
|
this.response.appendString(""); //Box color
|
||||||
this.response.appendString(""); //Key color
|
this.response.appendString(""); //Key color
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
package com.eu.habbo.messages.incoming.rooms.items.youtube;
|
package com.eu.habbo.messages.incoming.rooms.items.youtube;
|
||||||
|
|
||||||
import com.eu.habbo.Emulator;
|
import com.eu.habbo.Emulator;
|
||||||
import com.eu.habbo.habbohotel.items.YoutubeManager;
|
|
||||||
import com.eu.habbo.habbohotel.items.interactions.InteractionYoutubeTV;
|
import com.eu.habbo.habbohotel.items.interactions.InteractionYoutubeTV;
|
||||||
import com.eu.habbo.habbohotel.permissions.Permission;
|
import com.eu.habbo.habbohotel.permissions.Permission;
|
||||||
import com.eu.habbo.habbohotel.rooms.Room;
|
import com.eu.habbo.habbohotel.rooms.Room;
|
||||||
|
@ -1,6 +1,5 @@
|
|||||||
package com.eu.habbo.messages.incoming.rooms.users;
|
package com.eu.habbo.messages.incoming.rooms.users;
|
||||||
|
|
||||||
import com.eu.habbo.Emulator;
|
|
||||||
import com.eu.habbo.habbohotel.rooms.Room;
|
import com.eu.habbo.habbohotel.rooms.Room;
|
||||||
import com.eu.habbo.habbohotel.rooms.RoomTile;
|
import com.eu.habbo.habbohotel.rooms.RoomTile;
|
||||||
import com.eu.habbo.habbohotel.rooms.RoomUnit;
|
import com.eu.habbo.habbohotel.rooms.RoomUnit;
|
||||||
@ -8,7 +7,6 @@ import com.eu.habbo.habbohotel.rooms.RoomUnitStatus;
|
|||||||
import com.eu.habbo.habbohotel.users.Habbo;
|
import com.eu.habbo.habbohotel.users.Habbo;
|
||||||
import com.eu.habbo.messages.incoming.MessageHandler;
|
import com.eu.habbo.messages.incoming.MessageHandler;
|
||||||
import com.eu.habbo.messages.outgoing.rooms.users.RoomUserStatusComposer;
|
import com.eu.habbo.messages.outgoing.rooms.users.RoomUserStatusComposer;
|
||||||
import com.eu.habbo.plugin.events.users.UserIdleEvent;
|
|
||||||
|
|
||||||
public class RoomUserLookAtPoint extends MessageHandler {
|
public class RoomUserLookAtPoint extends MessageHandler {
|
||||||
@Override
|
@Override
|
||||||
|
@ -3,11 +3,23 @@ package com.eu.habbo.messages.outgoing;
|
|||||||
import com.eu.habbo.messages.ServerMessage;
|
import com.eu.habbo.messages.ServerMessage;
|
||||||
|
|
||||||
public abstract class MessageComposer {
|
public abstract class MessageComposer {
|
||||||
|
|
||||||
|
private ServerMessage composed;
|
||||||
protected final ServerMessage response;
|
protected final ServerMessage response;
|
||||||
|
|
||||||
protected MessageComposer() {
|
protected MessageComposer() {
|
||||||
|
this.composed = null;
|
||||||
this.response = new ServerMessage();
|
this.response = new ServerMessage();
|
||||||
}
|
}
|
||||||
|
|
||||||
public abstract ServerMessage compose();
|
protected abstract ServerMessage composeInternal();
|
||||||
|
|
||||||
|
public ServerMessage compose() {
|
||||||
|
if (this.composed == null) {
|
||||||
|
this.composed = this.composeInternal();
|
||||||
|
}
|
||||||
|
|
||||||
|
return this.composed;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
@ -21,7 +21,7 @@ public class AchievementListComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AchievementListComposer);
|
this.response.init(Outgoing.AchievementListComposer);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -18,7 +18,7 @@ public class AchievementProgressComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AchievementProgressComposer);
|
this.response.init(Outgoing.AchievementProgressComposer);
|
||||||
|
|
||||||
int achievementProgress;
|
int achievementProgress;
|
||||||
|
@ -17,7 +17,7 @@ public class AchievementUnlockedComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AchievementUnlockedComposer);
|
this.response.init(Outgoing.AchievementUnlockedComposer);
|
||||||
|
|
||||||
AchievementLevel level = this.achievement.getLevelForProgress(this.habbo.getHabboStats().getAchievementProgress(this.achievement));
|
AchievementLevel level = this.achievement.getLevelForProgress(this.habbo.getHabboStats().getAchievementProgress(this.achievement));
|
||||||
|
@ -17,7 +17,7 @@ public class TalentLevelUpdateComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.TalentLevelUpdateComposer);
|
this.response.init(Outgoing.TalentLevelUpdateComposer);
|
||||||
this.response.appendString(this.talentTrackType.name());
|
this.response.appendString(this.talentTrackType.name());
|
||||||
this.response.appendInt(this.talentTrackLevel.level);
|
this.response.appendInt(this.talentTrackLevel.level);
|
||||||
|
@ -23,7 +23,7 @@ public class TalentTrackComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.TalentTrackComposer);
|
this.response.init(Outgoing.TalentTrackComposer);
|
||||||
this.response.appendString(this.type.name().toLowerCase());
|
this.response.appendString(this.type.name().toLowerCase());
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ public class CameraCompetitionStatusComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CameraCompetitionStatusComposer);
|
this.response.init(Outgoing.CameraCompetitionStatusComposer);
|
||||||
this.response.appendBoolean(this.unknownBoolean);
|
this.response.appendBoolean(this.unknownBoolean);
|
||||||
this.response.appendString(this.unknownString);
|
this.response.appendString(this.unknownString);
|
||||||
|
@ -16,7 +16,7 @@ public class CameraPriceComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CameraPriceComposer);
|
this.response.init(Outgoing.CameraPriceComposer);
|
||||||
this.response.appendInt(this.credits);
|
this.response.appendInt(this.credits);
|
||||||
this.response.appendInt(this.points);
|
this.response.appendInt(this.points);
|
||||||
|
@ -16,7 +16,7 @@ public class CameraPublishWaitMessageComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CameraPublishWaitMessageComposer);
|
this.response.init(Outgoing.CameraPublishWaitMessageComposer);
|
||||||
|
|
||||||
this.response.appendBoolean(this.isOk);
|
this.response.appendBoolean(this.isOk);
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class CameraPurchaseSuccesfullComposer extends MessageComposer {
|
public class CameraPurchaseSuccesfullComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CameraPurchaseSuccesfullComposer);
|
this.response.init(Outgoing.CameraPurchaseSuccesfullComposer);
|
||||||
return this.response;
|
return this.response;
|
||||||
}
|
}
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class CameraRoomThumbnailSavedComposer extends MessageComposer {
|
public class CameraRoomThumbnailSavedComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CameraRoomThumbnailSavedComposer);
|
this.response.init(Outgoing.CameraRoomThumbnailSavedComposer);
|
||||||
return this.response;
|
return this.response;
|
||||||
}
|
}
|
||||||
|
@ -12,7 +12,7 @@ public class CameraURLComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CameraURLComposer);
|
this.response.init(Outgoing.CameraURLComposer);
|
||||||
this.response.appendString(this.URL);
|
this.response.appendString(this.URL);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class AlertLimitedSoldOutComposer extends MessageComposer {
|
public class AlertLimitedSoldOutComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AlertLimitedSoldOutComposer);
|
this.response.init(Outgoing.AlertLimitedSoldOutComposer);
|
||||||
return this.response;
|
return this.response;
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ public class AlertPurchaseFailedComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AlertPurchaseFailedComposer);
|
this.response.init(Outgoing.AlertPurchaseFailedComposer);
|
||||||
this.response.appendInt(this.error);
|
this.response.appendInt(this.error);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -15,7 +15,7 @@ public class AlertPurchaseUnavailableComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AlertPurchaseUnavailableComposer);
|
this.response.init(Outgoing.AlertPurchaseUnavailableComposer);
|
||||||
this.response.appendInt(this.code);
|
this.response.appendInt(this.code);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -12,7 +12,7 @@ public class CatalogModeComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CatalogModeComposer);
|
this.response.init(Outgoing.CatalogModeComposer);
|
||||||
this.response.appendInt(this.mode);
|
this.response.appendInt(this.mode);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -29,7 +29,7 @@ public class CatalogPageComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CatalogPageComposer);
|
this.response.init(Outgoing.CatalogPageComposer);
|
||||||
this.response.appendInt(this.page.getId());
|
this.response.appendInt(this.page.getId());
|
||||||
this.response.appendString(this.mode);
|
this.response.appendString(this.mode);
|
||||||
|
@ -25,7 +25,7 @@ public class CatalogPagesListComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
try {
|
try {
|
||||||
List<CatalogPage> pages = Emulator.getGameEnvironment().getCatalogManager().getCatalogPages(-1, this.habbo);
|
List<CatalogPage> pages = Emulator.getGameEnvironment().getCatalogManager().getCatalogPages(-1, this.habbo);
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ public class CatalogSearchResultComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CatalogSearchResultComposer);
|
this.response.init(Outgoing.CatalogSearchResultComposer);
|
||||||
this.item.serialize(this.response);
|
this.item.serialize(this.response);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class CatalogUpdatedComposer extends MessageComposer {
|
public class CatalogUpdatedComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CatalogUpdatedComposer);
|
this.response.init(Outgoing.CatalogUpdatedComposer);
|
||||||
this.response.appendBoolean(false);
|
this.response.appendBoolean(false);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -24,7 +24,7 @@ public class ClubCenterDataComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.ClubCenterDataComposer);
|
this.response.init(Outgoing.ClubCenterDataComposer);
|
||||||
this.response.appendInt(this.streakDuration); //streakduration in days
|
this.response.appendInt(this.streakDuration); //streakduration in days
|
||||||
this.response.appendString(this.joinDate); //joindate
|
this.response.appendString(this.joinDate); //joindate
|
||||||
|
@ -20,7 +20,7 @@ public class ClubDataComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.ClubDataComposer);
|
this.response.init(Outgoing.ClubDataComposer);
|
||||||
|
|
||||||
List<ClubOffer> offers = Emulator.getGameEnvironment().getCatalogManager().getClubOffers();
|
List<ClubOffer> offers = Emulator.getGameEnvironment().getCatalogManager().getClubOffers();
|
||||||
|
@ -12,7 +12,7 @@ import java.util.NoSuchElementException;
|
|||||||
|
|
||||||
public class ClubGiftsComposer extends MessageComposer {
|
public class ClubGiftsComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.ClubGiftsComposer);
|
this.response.init(Outgoing.ClubGiftsComposer);
|
||||||
|
|
||||||
this.response.appendInt(0); //Days Until Next Gift
|
this.response.appendInt(0); //Days Until Next Gift
|
||||||
|
@ -12,7 +12,7 @@ public class DiscountComposer extends MessageComposer {
|
|||||||
public static int[] ADDITIONAL_DISCOUNT_THRESHOLDS = new int[]{40, 99};
|
public static int[] ADDITIONAL_DISCOUNT_THRESHOLDS = new int[]{40, 99};
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.DiscountComposer);
|
this.response.init(Outgoing.DiscountComposer);
|
||||||
|
|
||||||
this.response.appendInt(MAXIMUM_ALLOWED_ITEMS);
|
this.response.appendInt(MAXIMUM_ALLOWED_ITEMS);
|
||||||
|
@ -9,7 +9,7 @@ import java.util.Map;
|
|||||||
|
|
||||||
public class GiftConfigurationComposer extends MessageComposer {
|
public class GiftConfigurationComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.GiftConfigurationComposer);
|
this.response.init(Outgoing.GiftConfigurationComposer);
|
||||||
this.response.appendBoolean(true);
|
this.response.appendBoolean(true);
|
||||||
this.response.appendInt(Emulator.getConfig().getInt("hotel.gifts.special.price", 2));
|
this.response.appendInt(Emulator.getConfig().getInt("hotel.gifts.special.price", 2));
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class GiftReceiverNotFoundComposer extends MessageComposer {
|
public class GiftReceiverNotFoundComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.GiftReceiverNotFoundComposer);
|
this.response.init(Outgoing.GiftReceiverNotFoundComposer);
|
||||||
return this.response;
|
return this.response;
|
||||||
}
|
}
|
||||||
|
@ -16,7 +16,7 @@ public class NotEnoughPointsTypeComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.NotEnoughPointsTypeComposer);
|
this.response.init(Outgoing.NotEnoughPointsTypeComposer);
|
||||||
this.response.appendBoolean(this.isCredits);
|
this.response.appendBoolean(this.isCredits);
|
||||||
this.response.appendBoolean(this.isPixels);
|
this.response.appendBoolean(this.isPixels);
|
||||||
|
@ -15,7 +15,7 @@ public class PetBoughtNotificationComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.PetBoughtNotificationComposer);
|
this.response.init(Outgoing.PetBoughtNotificationComposer);
|
||||||
this.response.appendBoolean(this.gift);
|
this.response.appendBoolean(this.gift);
|
||||||
this.pet.serialize(this.response);
|
this.pet.serialize(this.response);
|
||||||
|
@ -16,7 +16,7 @@ public class PetBreedsComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
if (this.petRaces == null)
|
if (this.petRaces == null)
|
||||||
return null;
|
return null;
|
||||||
this.response.init(Outgoing.PetBreedsComposer);
|
this.response.init(Outgoing.PetBreedsComposer);
|
||||||
|
@ -20,7 +20,7 @@ public class PetNameErrorComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.PetNameErrorComposer);
|
this.response.init(Outgoing.PetNameErrorComposer);
|
||||||
this.response.appendInt(this.type);
|
this.response.appendInt(this.type);
|
||||||
this.response.appendString(this.value);
|
this.response.appendString(this.value);
|
||||||
|
@ -17,7 +17,7 @@ public class PurchaseOKComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.PurchaseOKComposer);
|
this.response.init(Outgoing.PurchaseOKComposer);
|
||||||
if (this.catalogItem != null) {
|
if (this.catalogItem != null) {
|
||||||
this.catalogItem.serialize(this.response);
|
this.catalogItem.serialize(this.response);
|
||||||
|
@ -15,7 +15,7 @@ public class RecyclerCompleteComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.RecyclerCompleteComposer);
|
this.response.init(Outgoing.RecyclerCompleteComposer);
|
||||||
this.response.appendInt(this.code);
|
this.response.appendInt(this.code);
|
||||||
this.response.appendInt(0); //prize ID.
|
this.response.appendInt(0); //prize ID.
|
||||||
|
@ -11,7 +11,7 @@ import java.util.Map;
|
|||||||
|
|
||||||
public class RecyclerLogicComposer extends MessageComposer {
|
public class RecyclerLogicComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.RecyclerLogicComposer);
|
this.response.init(Outgoing.RecyclerLogicComposer);
|
||||||
this.response.appendInt(Emulator.getGameEnvironment().getCatalogManager().prizes.size());
|
this.response.appendInt(Emulator.getGameEnvironment().getCatalogManager().prizes.size());
|
||||||
for (Map.Entry<Integer, THashSet<Item>> map : Emulator.getGameEnvironment().getCatalogManager().prizes.entrySet()) {
|
for (Map.Entry<Integer, THashSet<Item>> map : Emulator.getGameEnvironment().getCatalogManager().prizes.entrySet()) {
|
||||||
|
@ -15,7 +15,7 @@ public class RedeemVoucherErrorComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.RedeemVoucherErrorComposer);
|
this.response.init(Outgoing.RedeemVoucherErrorComposer);
|
||||||
this.response.appendString(this.code + "");
|
this.response.appendString(this.code + "");
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class RedeemVoucherOKComposer extends MessageComposer {
|
public class RedeemVoucherOKComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.RedeemVoucherOKComposer);
|
this.response.init(Outgoing.RedeemVoucherOKComposer);
|
||||||
this.response.appendString("");
|
this.response.appendString("");
|
||||||
this.response.appendString("");
|
this.response.appendString("");
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class ReloadRecyclerComposer extends MessageComposer {
|
public class ReloadRecyclerComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.ReloadRecyclerComposer);
|
this.response.init(Outgoing.ReloadRecyclerComposer);
|
||||||
this.response.appendInt(1);
|
this.response.appendInt(1);
|
||||||
this.response.appendInt(0);
|
this.response.appendInt(0);
|
||||||
|
@ -17,7 +17,7 @@ public class TargetedOfferComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.TargetedOfferComposer);
|
this.response.init(Outgoing.TargetedOfferComposer);
|
||||||
HabboOfferPurchase purchase = HabboOfferPurchase.getOrCreate(this.habbo, this.offer.getId());
|
HabboOfferPurchase purchase = HabboOfferPurchase.getOrCreate(this.habbo, this.offer.getId());
|
||||||
this.offer.serialize(this.response, purchase);
|
this.offer.serialize(this.response, purchase);
|
||||||
|
@ -23,7 +23,7 @@ public class MarketplaceBuyErrorComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceBuyErrorComposer);
|
this.response.init(Outgoing.MarketplaceBuyErrorComposer);
|
||||||
this.response.appendInt(this.errorCode); //result
|
this.response.appendInt(this.errorCode); //result
|
||||||
this.response.appendInt(this.unknown); //newOfferId
|
this.response.appendInt(this.unknown); //newOfferId
|
||||||
|
@ -15,7 +15,7 @@ public class MarketplaceCancelSaleComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceCancelSaleComposer);
|
this.response.init(Outgoing.MarketplaceCancelSaleComposer);
|
||||||
this.response.appendInt(this.offer.getOfferId());
|
this.response.appendInt(this.offer.getOfferId());
|
||||||
this.response.appendBoolean(this.success);
|
this.response.appendBoolean(this.success);
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class MarketplaceConfigComposer extends MessageComposer {
|
public class MarketplaceConfigComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceConfigComposer);
|
this.response.init(Outgoing.MarketplaceConfigComposer);
|
||||||
this.response.appendBoolean(true);
|
this.response.appendBoolean(true);
|
||||||
this.response.appendInt(1); //Commision Percentage.
|
this.response.appendInt(1); //Commision Percentage.
|
||||||
|
@ -13,7 +13,7 @@ public class MarketplaceItemInfoComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceItemInfoComposer);
|
this.response.init(Outgoing.MarketplaceItemInfoComposer);
|
||||||
MarketPlace.serializeItemInfo(this.itemId, this.response);
|
MarketPlace.serializeItemInfo(this.itemId, this.response);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -17,7 +17,7 @@ public class MarketplaceItemPostedComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceItemPostedComposer);
|
this.response.init(Outgoing.MarketplaceItemPostedComposer);
|
||||||
this.response.appendInt(this.code);
|
this.response.appendInt(this.code);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -16,7 +16,7 @@ public class MarketplaceOffersComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceOffersComposer);
|
this.response.init(Outgoing.MarketplaceOffersComposer);
|
||||||
int total = 0;
|
int total = 0;
|
||||||
this.response.appendInt(this.offers.size());
|
this.response.appendInt(this.offers.size());
|
||||||
|
@ -20,7 +20,7 @@ public class MarketplaceOwnItemsComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceOwnItemsComposer);
|
this.response.init(Outgoing.MarketplaceOwnItemsComposer);
|
||||||
this.response.appendInt(this.habbo.getInventory().getSoldPriceTotal());
|
this.response.appendInt(this.habbo.getInventory().getSoldPriceTotal());
|
||||||
this.response.appendInt(this.habbo.getInventory().getMarketplaceItems().size());
|
this.response.appendInt(this.habbo.getInventory().getMarketplaceItems().size());
|
||||||
|
@ -20,7 +20,7 @@ public class MarketplaceSellItemComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MarketplaceSellItemComposer);
|
this.response.init(Outgoing.MarketplaceSellItemComposer);
|
||||||
this.response.appendInt(this.errorCode);
|
this.response.appendInt(this.errorCode);
|
||||||
this.response.appendInt(this.valueA);
|
this.response.appendInt(this.valueA);
|
||||||
|
@ -19,7 +19,7 @@ public class CraftableProductsComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CraftableProductsComposer);
|
this.response.init(Outgoing.CraftableProductsComposer);
|
||||||
|
|
||||||
this.response.appendInt(this.recipes.size());
|
this.response.appendInt(this.recipes.size());
|
||||||
|
@ -16,7 +16,7 @@ public class CraftingRecipeComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CraftingRecipeComposer);
|
this.response.init(Outgoing.CraftingRecipeComposer);
|
||||||
this.response.appendInt(this.recipe.getIngredients().size());
|
this.response.appendInt(this.recipe.getIngredients().size());
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ public class CraftingRecipesAvailableComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CraftingComposerFour);
|
this.response.init(Outgoing.CraftingComposerFour);
|
||||||
this.response.appendInt((this.found ? -1 : 0) + this.count);
|
this.response.appendInt((this.found ? -1 : 0) + this.count);
|
||||||
this.response.appendBoolean(this.found);
|
this.response.appendBoolean(this.found);
|
||||||
|
@ -20,7 +20,7 @@ public class CraftingResultComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.CraftingResultComposer);
|
this.response.init(Outgoing.CraftingResultComposer);
|
||||||
|
|
||||||
this.response.appendBoolean(this.succes); //succes
|
this.response.appendBoolean(this.succes); //succes
|
||||||
|
@ -22,7 +22,7 @@ public class AdventCalendarDataComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AdventCalendarDataComposer);
|
this.response.init(Outgoing.AdventCalendarDataComposer);
|
||||||
this.response.appendString(this.eventName);
|
this.response.appendString(this.eventName);
|
||||||
this.response.appendString("");
|
this.response.appendString("");
|
||||||
|
@ -16,7 +16,7 @@ public class AdventCalendarProductComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.AdventCalendarProductComposer);
|
this.response.init(Outgoing.AdventCalendarProductComposer);
|
||||||
this.response.appendBoolean(this.visible);
|
this.response.appendBoolean(this.visible);
|
||||||
this.response.appendString(this.rewardObject.getItem().getName());
|
this.response.appendString(this.rewardObject.getItem().getName());
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class MysticBoxCloseComposer extends MessageComposer {
|
public class MysticBoxCloseComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MysticBoxCloseComposer);
|
this.response.init(Outgoing.MysticBoxCloseComposer);
|
||||||
return this.response;
|
return this.response;
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,7 @@ public class MysticBoxPrizeComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MysticBoxPrizeComposer);
|
this.response.init(Outgoing.MysticBoxPrizeComposer);
|
||||||
this.response.appendString(this.type);
|
this.response.appendString(this.type);
|
||||||
this.response.appendInt(this.itemId);
|
this.response.appendInt(this.itemId);
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class MysticBoxStartOpenComposer extends MessageComposer {
|
public class MysticBoxStartOpenComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MysticBoxStartOpenComposer);
|
this.response.init(Outgoing.MysticBoxStartOpenComposer);
|
||||||
return this.response;
|
return this.response;
|
||||||
}
|
}
|
||||||
|
@ -12,7 +12,7 @@ public class NewYearResolutionCompletedComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.NewYearResolutionCompletedComposer);
|
this.response.init(Outgoing.NewYearResolutionCompletedComposer);
|
||||||
this.response.appendString(this.badge);
|
this.response.appendString(this.badge);
|
||||||
this.response.appendString(this.badge);
|
this.response.appendString(this.badge);
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class NewYearResolutionComposer extends MessageComposer {
|
public class NewYearResolutionComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
//:test 817 i:230 i:1 i:1 i:1 s:NY2013RES i:3 i:0 i:60000000
|
//:test 817 i:230 i:1 i:1 i:1 s:NY2013RES i:3 i:0 i:60000000
|
||||||
this.response.init(Outgoing.NewYearResolutionComposer);
|
this.response.init(Outgoing.NewYearResolutionComposer);
|
||||||
|
|
||||||
|
@ -22,7 +22,7 @@ public class NewYearResolutionProgressComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.NewYearResolutionProgressComposer);
|
this.response.init(Outgoing.NewYearResolutionProgressComposer);
|
||||||
this.response.appendInt(this.stuffId);
|
this.response.appendInt(this.stuffId);
|
||||||
this.response.appendInt(this.achievementId);
|
this.response.appendInt(this.achievementId);
|
||||||
|
@ -15,7 +15,7 @@ public class FloorPlanEditorBlockedTilesComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.FloorPlanEditorBlockedTilesComposer);
|
this.response.init(Outgoing.FloorPlanEditorBlockedTilesComposer);
|
||||||
|
|
||||||
THashSet<RoomTile> tileList = this.room.getLockedTiles();
|
THashSet<RoomTile> tileList = this.room.getLockedTiles();
|
||||||
|
@ -13,7 +13,7 @@ public class FloorPlanEditorDoorSettingsComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.FloorPlanEditorDoorSettingsComposer);
|
this.response.init(Outgoing.FloorPlanEditorDoorSettingsComposer);
|
||||||
this.response.appendInt(this.room.getLayout().getDoorX());
|
this.response.appendInt(this.room.getLayout().getDoorX());
|
||||||
this.response.appendInt(this.room.getLayout().getDoorY());
|
this.response.appendInt(this.room.getLayout().getDoorY());
|
||||||
|
@ -25,7 +25,7 @@ public class FriendChatMessageComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.FriendChatMessageComposer);
|
this.response.init(Outgoing.FriendChatMessageComposer);
|
||||||
this.response.appendInt(this.toId);
|
this.response.appendInt(this.toId);
|
||||||
this.response.appendString(this.message.getMessage());
|
this.response.appendString(this.message.getMessage());
|
||||||
|
@ -15,7 +15,7 @@ public class FriendFindingRoomComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.FriendFindingRoomComposer);
|
this.response.init(Outgoing.FriendFindingRoomComposer);
|
||||||
this.response.appendInt(this.errorCode);
|
this.response.appendInt(this.errorCode);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -24,7 +24,7 @@ public class FriendNotificationComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.FriendToolbarNotificationComposer);
|
this.response.init(Outgoing.FriendToolbarNotificationComposer);
|
||||||
this.response.appendString(this.userId + "");
|
this.response.appendString(this.userId + "");
|
||||||
this.response.appendInt(this.type);
|
this.response.appendInt(this.type);
|
||||||
|
@ -13,7 +13,7 @@ public class FriendRequestComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.FriendRequestComposer);
|
this.response.init(Outgoing.FriendRequestComposer);
|
||||||
|
|
||||||
this.response.appendInt(this.habbo.getHabboInfo().getId());
|
this.response.appendInt(this.habbo.getHabboInfo().getId());
|
||||||
|
@ -16,7 +16,7 @@ public class FriendRequestErrorComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.FriendRequestErrorComposer);
|
this.response.init(Outgoing.FriendRequestErrorComposer);
|
||||||
this.response.appendInt(0);
|
this.response.appendInt(0);
|
||||||
this.response.appendInt(this.errorCode);
|
this.response.appendInt(this.errorCode);
|
||||||
|
@ -22,7 +22,7 @@ public class FriendsComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
try {
|
try {
|
||||||
this.response.init(Outgoing.FriendsComposer);
|
this.response.init(Outgoing.FriendsComposer);
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ public class LoadFriendRequestsComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.LoadFriendRequestsComposer);
|
this.response.init(Outgoing.LoadFriendRequestsComposer);
|
||||||
|
|
||||||
synchronized (this.habbo.getMessenger().getFriendRequests()) {
|
synchronized (this.habbo.getMessenger().getFriendRequests()) {
|
||||||
|
@ -14,7 +14,7 @@ public class MessengerInitComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MessengerInitComposer);
|
this.response.init(Outgoing.MessengerInitComposer);
|
||||||
if (this.habbo.hasPermission("acc_infinite_friends")) {
|
if (this.habbo.hasPermission("acc_infinite_friends")) {
|
||||||
this.response.appendInt(Integer.MAX_VALUE);
|
this.response.appendInt(Integer.MAX_VALUE);
|
||||||
|
@ -18,7 +18,7 @@ public class RemoveFriendComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.UpdateFriendComposer);
|
this.response.init(Outgoing.UpdateFriendComposer);
|
||||||
|
|
||||||
this.response.appendInt(0);
|
this.response.appendInt(0);
|
||||||
|
@ -14,7 +14,7 @@ public class RoomInviteComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.RoomInviteComposer);
|
this.response.init(Outgoing.RoomInviteComposer);
|
||||||
this.response.appendInt(this.userId);
|
this.response.appendInt(this.userId);
|
||||||
this.response.appendString(this.message);
|
this.response.appendString(this.message);
|
||||||
|
@ -17,7 +17,7 @@ public class RoomInviteErrorComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.RoomInviteErrorComposer);
|
this.response.init(Outgoing.RoomInviteErrorComposer);
|
||||||
this.response.appendInt(this.errorCode);
|
this.response.appendInt(this.errorCode);
|
||||||
this.response.appendInt(this.buddies.size());
|
this.response.appendInt(this.buddies.size());
|
||||||
|
@ -17,7 +17,7 @@ public class StalkErrorComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.StalkErrorComposer);
|
this.response.init(Outgoing.StalkErrorComposer);
|
||||||
this.response.appendInt(this.errorCode);
|
this.response.appendInt(this.errorCode);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -22,7 +22,7 @@ public class UpdateFriendComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
|
|
||||||
this.response.init(Outgoing.UpdateFriendComposer);
|
this.response.init(Outgoing.UpdateFriendComposer);
|
||||||
if (this.buddy != null) {
|
if (this.buddy != null) {
|
||||||
|
@ -25,7 +25,7 @@ public class UserSearchResultComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.UserSearchResultComposer);
|
this.response.init(Outgoing.UserSearchResultComposer);
|
||||||
List<MessengerBuddy> u = new ArrayList<>();
|
List<MessengerBuddy> u = new ArrayList<>();
|
||||||
|
|
||||||
|
@ -14,7 +14,7 @@ public class GameCenterAccountInfoComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.GameCenterAccountInfoComposer);
|
this.response.init(Outgoing.GameCenterAccountInfoComposer);
|
||||||
this.response.appendInt(this.gameId);
|
this.response.appendInt(this.gameId);
|
||||||
this.response.appendInt(this.gamesLeft);
|
this.response.appendInt(this.gamesLeft);
|
||||||
|
@ -5,7 +5,7 @@ import com.eu.habbo.messages.outgoing.MessageComposer;
|
|||||||
|
|
||||||
public class GameCenterAchievementsConfigurationComposer extends MessageComposer {
|
public class GameCenterAchievementsConfigurationComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(2265);
|
this.response.init(2265);
|
||||||
this.response.appendInt(0);
|
this.response.appendInt(0);
|
||||||
this.response.appendInt(0);
|
this.response.appendInt(0);
|
||||||
|
@ -17,7 +17,7 @@ public class GameCenterGameComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.GameCenterGameComposer);
|
this.response.init(Outgoing.GameCenterGameComposer);
|
||||||
this.response.appendInt(this.gameId);
|
this.response.appendInt(this.gameId);
|
||||||
this.response.appendInt(this.status);
|
this.response.appendInt(this.status);
|
||||||
|
@ -7,7 +7,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class GameCenterGameListComposer extends MessageComposer {
|
public class GameCenterGameListComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.GameCenterGameListComposer);
|
this.response.init(Outgoing.GameCenterGameListComposer);
|
||||||
this.response.appendInt(2);//Count
|
this.response.appendInt(2);//Count
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ public class BaseJumpJoinQueueComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.BaseJumpJoinQueueComposer);
|
this.response.init(Outgoing.BaseJumpJoinQueueComposer);
|
||||||
this.response.appendInt(this.gameId);
|
this.response.appendInt(this.gameId);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class BaseJumpLeaveQueueComposer extends MessageComposer {
|
public class BaseJumpLeaveQueueComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.BaseJumpLeaveQueueComposer);
|
this.response.init(Outgoing.BaseJumpLeaveQueueComposer);
|
||||||
this.response.appendInt(3);
|
this.response.appendInt(3);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -18,7 +18,7 @@ public class BaseJumpLoadGameComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.BaseJumpLoadGameComposer);
|
this.response.init(Outgoing.BaseJumpLoadGameComposer);
|
||||||
|
|
||||||
if (this.game == 3) {
|
if (this.game == 3) {
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class BaseJumpLoadGameURLComposer extends MessageComposer {
|
public class BaseJumpLoadGameURLComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.BaseJumpLoadGameURLComposer);
|
this.response.init(Outgoing.BaseJumpLoadGameURLComposer);
|
||||||
this.response.appendInt(4);
|
this.response.appendInt(4);
|
||||||
this.response.appendString("1351418858673");
|
this.response.appendString("1351418858673");
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class BaseJumpUnloadGameComposer extends MessageComposer {
|
public class BaseJumpUnloadGameComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.BaseJumpUnloadGameComposer);
|
this.response.init(Outgoing.BaseJumpUnloadGameComposer);
|
||||||
this.response.appendInt(3);
|
this.response.appendInt(3);
|
||||||
this.response.appendString("basejump");
|
this.response.appendString("basejump");
|
||||||
|
@ -6,7 +6,7 @@ import com.eu.habbo.messages.outgoing.Outgoing;
|
|||||||
|
|
||||||
public class MinimailCountComposer extends MessageComposer {
|
public class MinimailCountComposer extends MessageComposer {
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.MinimailCountComposer);
|
this.response.init(Outgoing.MinimailCountComposer);
|
||||||
this.response.appendInt(0);
|
this.response.appendInt(0);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
@ -12,7 +12,7 @@ public class PickMonthlyClubGiftNotificationComposer extends MessageComposer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ServerMessage compose() {
|
protected ServerMessage composeInternal() {
|
||||||
this.response.init(Outgoing.PickMonthlyClubGiftNotificationComposer);
|
this.response.init(Outgoing.PickMonthlyClubGiftNotificationComposer);
|
||||||
this.response.appendInt(this.count);
|
this.response.appendInt(this.count);
|
||||||
return this.response;
|
return this.response;
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user