Example #1
0
 /**
  * Departure interface.
  *
  * @param player the player to send interface
  */
 private void sendInterfaces() {
   player.getPackets().sendIComponentText(407, 3, "");
   player.getPackets().sendIComponentText(407, 14, "" + waitingPlayers.size());
   player.getPackets().sendIComponentText(407, 16, "" + Integer.toString(player.getPestPoints()));
   player
       .getInterfaceManager()
       .sendTab(player.getInterfaceManager().hasRezizableScreen() ? 10 : 19, 407);
 }
Example #2
0
 public static void openPartyChest(final Player player) {
   player.getTemporaryAttributtes().put("PartyRoomInventory", Boolean.TRUE);
   player.getInterfaceManager().sendInterface(PARTY_CHEST_INTERFACE);
   player.getInterfaceManager().sendInventoryInterface(INVENTORY_INTERFACE);
   sendOptions(player);
   player.setCloseInterfacesEvent(
       new Runnable() {
         @Override
         public void run() {
           player.getTemporaryAttributtes().remove("PartyRoomInventory");
         }
       });
 }
Example #3
0
 private static void useHomeTele(Player player) {
   player.stopAll();
   player.getInterfaceManager().sendInterface(1092);
 }
Example #4
0
 public static final void processNormalSpell(Player player, int spellId, int packetId) {
   player.stopAll(false);
   switch (spellId) {
     case 25: // air strike
     case 28: // water strike
     case 30: // earth strike
     case 32: // fire strike
     case 34: // air bolt
     case 39: // water bolt
     case 42: // earth bolt
     case 45: // fire bolt
     case 49: // air blast
     case 52: // water blast
     case 58: // earth blast
     case 63: // fire blast
     case 70: // air wave
     case 73: // water wave
     case 77: // earth wave
     case 80: // fire wave
     case 99:
     case 84:
     case 87:
     case 89:
     case 91:
     case 36:
     case 55:
     case 81:
     case 66:
     case 67:
     case 68:
       setCombatSpell(player, spellId);
       break;
     case 27: // crossbow bolt enchant
       if (player.getSkills().getLevel(Skills.MAGIC) < 4) {
         player
             .getPackets()
             .sendGameMessage("Your Magic level is not high enough for this spell.");
         return;
       }
       player.stopAll();
       player.getInterfaceManager().sendInterface(432);
       break;
     case 24:
       useHomeTele(player);
       break;
     case 37: // mobi
       sendNormalTeleportSpell(
           player, 10, 19, new WorldTile(2413, 2848, 0), LAW_RUNE, 1, WATER_RUNE, 1, AIR_RUNE, 1);
       break;
     case 40: // varrock
       sendNormalTeleportSpell(
           player, 25, 19, new WorldTile(3212, 3424, 0), FIRE_RUNE, 1, AIR_RUNE, 3, LAW_RUNE, 1);
       break;
     case 43: // lumby
       sendNormalTeleportSpell(
           player, 31, 41, new WorldTile(3222, 3218, 0), EARTH_RUNE, 1, AIR_RUNE, 3, LAW_RUNE, 1);
       break;
     case 46: // fally
       sendNormalTeleportSpell(
           player, 37, 48, new WorldTile(2964, 3379, 0), WATER_RUNE, 1, AIR_RUNE, 3, LAW_RUNE, 1);
       break;
     case 51: // camelot
       sendNormalTeleportSpell(
           player, 45, 55.5, new WorldTile(2757, 3478, 0), AIR_RUNE, 5, LAW_RUNE, 1);
       break;
     case 57: // ardy
       sendNormalTeleportSpell(
           player, 51, 61, new WorldTile(2664, 3305, 0), WATER_RUNE, 2, LAW_RUNE, 2);
       break;
     case 62: // watch
       sendNormalTeleportSpell(
           player, 58, 68, new WorldTile(2547, 3113, 2), EARTH_RUNE, 2, LAW_RUNE, 2);
       break;
     case 69: // troll
       sendNormalTeleportSpell(
           player, 61, 68, new WorldTile(2888, 3674, 0), FIRE_RUNE, 2, LAW_RUNE, 2);
       break;
     case 72: // ape
       sendNormalTeleportSpell(
           player,
           64,
           76,
           new WorldTile(2776, 9103, 0),
           FIRE_RUNE,
           2,
           WATER_RUNE,
           2,
           LAW_RUNE,
           2,
           1963,
           1);
       break;
   }
 }