Package lineage2.gameserver.model.instances

Examples of lineage2.gameserver.model.instances.NpcInstance


   * @param damage int
   */
  @Override
  protected void onEvtAttacked(Creature attacker, int damage)
  {
    final NpcInstance actor = getActor();
    if (!_firstAttack)
    {
      actor.broadcastPacket(new MagicSkillUse(actor, actor, 5980, 1, 0, 0));
      _firstAttack = true;
    }
  }
View Full Code Here


  {
    if ((System.currentTimeMillis() - _lastTeleport) < TELEPORT_PERIOD)
    {
      return false;
    }
    final NpcInstance _thisActor = getActor();
    final Location loc = _points[Rnd.get(_points.length)];
    if (_thisActor.getLoc().equals(loc))
    {
      return false;
    }
    _thisActor.broadcastPacketToOthers(new MagicSkillUse(_thisActor, _thisActor, 4671, 1, 1000, 0));
    ThreadPoolManager.getInstance().schedule(new Teleport(loc), 1000);
    _lastTeleport = System.currentTimeMillis();
    return true;
  }
View Full Code Here

        spawn_captain = true;
      }
    }
    if (spawn_captain && Rnd.chance(50))
    {
      NpcInstance captain = addSpawnToInstance(KechisCaptain3, new Location(npc.getX() - 60, npc.getY(), npc.getZ(), 32116), 0, world.instanceId);
      captain.addStatFunc(new FuncMul(Stats.POWER_ATTACK, 0x30, this, 5));
      captain.addStatFunc(new FuncMul(Stats.MAGIC_ATTACK, 0x30, this, 5));
      captain.addStatFunc(new FuncMul(Stats.POWER_DEFENCE, 0x30, this, 5));
      captain.addStatFunc(new FuncMul(Stats.MAGIC_DEFENCE, 0x30, this, 5));
      captain.getAI().notifyEvent(CtrlEvent.EVT_AGGRESSION, player, Rnd.get(1, 100));
    }
    if (teleto != null)
    {
      Party party = player.getParty();
      if (party != null)
View Full Code Here

   * @param damage int
   */
  @Override
  protected void onEvtAttacked(Creature attacker, int damage)
  {
    final NpcInstance actor = getActor();
    if (_firstTimeAttacked)
    {
      _firstTimeAttacked = false;
      if (Rnd.chance(25))
      {
View Full Code Here

    runSecretRoom2(world);
    runSecretRoom3(world);
    runSecretRoom4(world);
    world.emeraldRoom = new Room();
    world.emeraldRoom.npclist = new HashMap<>();
    NpcInstance newNpc;
    newNpc = addSpawnToInstance(Spinel, new Location(144158, 143424, -11957, 29058), 0, world.instanceId);
    world.emeraldRoom.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(ReefGolem, new Location(144044, 143448, -11949, 27778), 0, world.instanceId);
    world.emeraldRoom.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(ReefGolem, new Location(142580, 143091, -11872, 7458), 0, world.instanceId);
View Full Code Here

 
  private void runSecretRoom1(World world)
  {
    world.SecretRoom1 = new Room();
    world.SecretRoom1.npclist = new HashMap<>();
    NpcInstance newNpc;
    newNpc = addSpawnToInstance(EmeraldBoar, new Location(143114, 140027, -11888, 15025), 0, world.instanceId);
    world.SecretRoom1.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(EmeraldBoar, new Location(142173, 140973, -11888, 55698), 0, world.instanceId);
    world.SecretRoom1.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(PlazaHelm, new Location(143210, 140577, -11888, 17164), 0, world.instanceId);
View Full Code Here

 
  private void runSecretRoom2(World world)
  {
    world.SecretRoom2 = new Room();
    world.SecretRoom2.npclist = new HashMap<>();
    NpcInstance newNpc;
    newNpc = addSpawnToInstance(GUARDIAN, new Location(146272, 141484, -11888, 15025), 0, world.instanceId);
    world.SecretRoom2.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(PlazaHelm, new Location(146870, 140906, -11888, 23832), 0, world.instanceId);
    world.SecretRoom2.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(PlazaHelm, new Location(146833, 141741, -11888, 37869), 0, world.instanceId);
View Full Code Here

 
  private void runSecretRoom3(World world)
  {
    world.SecretRoom3 = new Room();
    world.SecretRoom3.npclist = new HashMap<>();
    NpcInstance newNpc;
    newNpc = addSpawnToInstance(Spinel, new Location(144868, 143439, -12816, 5588), 0, world.instanceId);
    world.SecretRoom3.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(Spinel, new Location(145369, 144040, -12816, 42939), 0, world.instanceId);
    world.SecretRoom3.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(22294, new Location(145315, 143436, -12813, 27523), 0, world.instanceId);
View Full Code Here

 
  private void runSecretRoom4(World world)
  {
    world.SecretRoom4 = new Room();
    world.SecretRoom4.npclist = new HashMap<>();
    NpcInstance newNpc;
    newNpc = addSpawnToInstance(ChromaticDetainee1, new Location(150930, 141920, -12116, 21592), 0, world.instanceId);
    world.SecretRoom4.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(ChromaticDetainee1, new Location(150212, 141905, -12116, 7201), 0, world.instanceId);
    world.SecretRoom4.npclist.put(newNpc, false);
    newNpc = addSpawnToInstance(PlazaGaviel, new Location(150661, 141859, -12116, 15452), 0, world.instanceId);
View Full Code Here

      ThreadPoolManager.getInstance().schedule(new Runnable(){
        @Override
        public void run()
        {
          NpcInstance octavisFirstStage = addSpawnWithoutRespawn(Octavis1, new Location(207192, 120568, -10032, 49151), 0);
          octavisFirstStage.addListener(_currentHpListenerFistsStage);
          octavisFirstStage.setLockedTarget(true);
          octavisMassive = octavisFirstStage;

          NpcInstance octavisRider = addSpawnWithoutRespawn(OctavisRider, new Location(207192, 120588, -10032, 49151), 0);
          octavisRider.addListener(_currentHpListenerOctavisRide);
        }
      }, 26700);
    }
View Full Code Here

TOP

Related Classes of lineage2.gameserver.model.instances.NpcInstance

Copyright © 2018 www.massapicom. 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.