2018-07-06 15:30:00 +02:00
|
|
|
package com.eu.habbo.habbohotel.items.interactions;
|
|
|
|
|
2019-05-12 12:48:56 +02:00
|
|
|
import com.eu.habbo.habbohotel.gameclients.GameClient;
|
2018-07-06 15:30:00 +02:00
|
|
|
import com.eu.habbo.habbohotel.items.Item;
|
|
|
|
import com.eu.habbo.habbohotel.rooms.Room;
|
2019-05-25 00:11:18 +02:00
|
|
|
import com.eu.habbo.habbohotel.rooms.RoomUnit;
|
|
|
|
import com.eu.habbo.habbohotel.users.Habbo;
|
2019-05-12 12:48:56 +02:00
|
|
|
import com.eu.habbo.messages.outgoing.habboway.nux.NuxAlertComposer;
|
2018-07-06 15:30:00 +02:00
|
|
|
import gnu.trove.map.hash.THashMap;
|
|
|
|
|
|
|
|
import java.sql.ResultSet;
|
|
|
|
import java.sql.SQLException;
|
|
|
|
|
|
|
|
public class InteractionInformationTerminal extends InteractionCustomValues
|
|
|
|
{
|
2019-03-18 02:22:00 +01:00
|
|
|
public static final THashMap<String, String> defaultValues = new THashMap<String, String>()
|
2018-07-06 15:30:00 +02:00
|
|
|
{
|
2019-03-18 02:22:00 +01:00
|
|
|
{
|
2019-05-12 12:48:56 +02:00
|
|
|
this.put("internalLink", "habbopages/chat/commands");
|
|
|
|
}
|
2018-07-06 15:30:00 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
public InteractionInformationTerminal(ResultSet set, Item baseItem) throws SQLException
|
|
|
|
{
|
|
|
|
super(set, baseItem, defaultValues);
|
|
|
|
}
|
|
|
|
|
|
|
|
public InteractionInformationTerminal(int id, int userId, Item item, String extradata, int limitedStack, int limitedSells)
|
|
|
|
{
|
|
|
|
super(id, userId, item, extradata, limitedStack, limitedSells, defaultValues);
|
|
|
|
}
|
|
|
|
|
2019-05-25 00:11:18 +02:00
|
|
|
@Override
|
|
|
|
public void onWalk(RoomUnit roomUnit, Room room, Object[] objects) throws Exception {
|
|
|
|
super.onWalk(roomUnit, room, objects);
|
|
|
|
|
|
|
|
Habbo habbo = room.getHabbo(roomUnit);
|
|
|
|
if(habbo != null && this.values.containsKey("internalLink")) {
|
|
|
|
habbo.getClient().sendResponse(new NuxAlertComposer(this.values.get("internalLink")));
|
|
|
|
}
|
|
|
|
}
|
2018-07-06 15:30:00 +02:00
|
|
|
}
|