Package net.sf.l2j.gameserver.model

Examples of net.sf.l2j.gameserver.model.L2Character.sendPacket()


            double cp = skill.getPower();
            //int cLev = activeChar.getLevel();
            //hp += skill.getPower()/*+(Math.sqrt(cLev)*cLev)+cLev*/;
            SystemMessage sm = new SystemMessage(SystemMessageId.S1_CP_WILL_BE_RESTORED);
            sm.addNumber((int)cp);
            target.sendPacket(sm);
            target.setCurrentCp(cp+target.getCurrentCp());
            StatusUpdate sump = new StatusUpdate(target.getObjectId());
            sump.addAttribute(StatusUpdate.CUR_CP, (int)target.getCurrentCp());
            target.sendPacket(sump);
        }
View Full Code Here


            sm.addNumber((int)cp);
            target.sendPacket(sm);
            target.setCurrentCp(cp+target.getCurrentCp());
            StatusUpdate sump = new StatusUpdate(target.getObjectId());
            sump.addAttribute(StatusUpdate.CUR_CP, (int)target.getCurrentCp());
            target.sendPacket(sump);
        }
    }


    @Override
View Full Code Here

                        {
                            skill.getEffects(activeChar, target);

                            SystemMessage sm = new SystemMessage(SystemMessageId.YOU_FEEL_S1_EFFECT);
                            sm.addSkillName(skill.getId());
                            target.sendPacket(sm);
                        }
                        else
                        {
                            SystemMessage sm = new SystemMessage(SystemMessageId.S1_WAS_UNAFFECTED_BY_S2);
                            sm.addString(target.getName());
View Full Code Here


    //send the ExCursedWeaponLocation
    if (!list.isEmpty())
    {
      activeChar.sendPacket(new ExCursedWeaponLocation(list));
    }
  }
 
  @Override
  public String getType()
View Full Code Here

            player.startAbnormalEffect(0x0400);
          else
            player.startAbnormalEffect(0x0800);
          player.setIsParalyzed(true);
          StopMove sm = new StopMove(player);
          player.sendPacket(sm);
          player.broadcastPacket(sm);
        }
      }
      catch (Exception e)
      {
View Full Code Here

          if (!player.isGM())
          {
            player.startAbnormalEffect(0x0400);
            player.setIsParalyzed(true);
            StopMove sm = new StopMove(player);
            player.sendPacket(sm);
            player.broadcastPacket(sm);
          }
        }
      }
      catch (Exception e)
View Full Code Here

          if (player instanceof L2PcInstance)
          {
            CharInfo info1 = new CharInfo((L2PcInstance)player);
            player.broadcastPacket(info1);
            UserInfo info2 = new UserInfo((L2PcInstance)player);
            player.sendPacket(info2);
          }
          else if(player instanceof L2NpcInstance)
          {
            NpcInfo info1 = new NpcInfo((L2NpcInstance)player, null);
            player.broadcastPacket(info1);
View Full Code Here

            player.setTeam(0);
            if (teamVal != 0)
            {
              SystemMessage sm = new SystemMessage(SystemMessageId.S1_S2);
              sm.addString("You have joined team " + teamVal);
              player.sendPacket(sm);
            }
            player.broadcastUserInfo();
          }
        }
      }
View Full Code Here

      player.setTeam(teamVal);
      if (teamVal != 0)
      {
        SystemMessage sm = new SystemMessage(SystemMessageId.S1_S2);
        sm.addString("You have joined team " + teamVal);
        player.sendPacket(sm);
      }
      player.broadcastUserInfo();
    }
    else if (command.startsWith("admin_social"))
    {
View Full Code Here

    if (pet == null)
      return;

    if (pet.getName() != null)
    {
      activeChar.sendPacket(new SystemMessage(SystemMessageId.NAMING_YOU_CANNOT_SET_NAME_OF_THE_PET));
      return;
    }
    else if (PetNameTable.getInstance().doesPetNameExist(_name, pet.getTemplate().npcId))
    {
      activeChar.sendPacket(new SystemMessage(SystemMessageId.NAMING_ALREADY_IN_USE_BY_ANOTHER_PET));
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.