Package lineage2.gameserver.skills

Examples of lineage2.gameserver.skills.TimeStamp


    {
      return;
    }
    if (!Config.ALT_ALLOW_SHADOW_WEAPONS)
    {
      show(new CustomMessage("common.Disabled", player), player);
      return;
    }
    if ((player.getLevel() > 39) || (player.getClassLevel() > 2))
    {
      show("Your level is too high!", player);
View Full Code Here


      ThreadPoolManager.getInstance().schedule(new RestoreOfflineTraders(), 30000L);
    }
    getListeners().onStart();
    if (Config.IS_TELNET_ENABLED)
    {
      statusServer = new TelnetServer();
    }
    else
    {
      _log.info("Telnet server is currently disabled.");
    }
View Full Code Here

        int item_id = rset.getInt("item_id");
        long endTime = rset.getLong("end_time");
        long reuse = rset.getLong("reuse");
        if ((endTime - curTime) > 500)
        {
          TimeStamp stamp = new TimeStamp(item_id, endTime, reuse);
          player.addSharedGroupReuse(group, stamp);
        }
      }
      DbUtils.close(statement);
      statement = con.prepareStatement(DELETE_SQL_QUERY);
View Full Code Here

      synchronized (player.getSharedGroupReuses())
      {
        for (IntObjectMap.Entry<TimeStamp> entry : player.getSharedGroupReuses())
        {
          int group = entry.getKey();
          TimeStamp timeStamp = entry.getValue();
          if (timeStamp.hasNotPassed())
          {
            StringBuilder sb = new StringBuilder("(");
            sb.append(player.getObjectId()).append(',');
            sb.append(group).append(',');
            sb.append(timeStamp.getId()).append(',');
            sb.append(timeStamp.getEndTime()).append(',');
            sb.append(timeStamp.getReuseBasic()).append(')');
            b.write(sb.toString());
          }
        }
      }
      if (!b.isEmpty())
View Full Code Here

        {
          augmentationId = item.getAugmentationId();
          reuseGroup = item.getTemplate().getDisplayReuseGroup();
          if (item.getTemplate().getReuseDelay() > 0)
          {
            TimeStamp timeStamp = player.getSharedGroupReuse(item.getTemplate().getReuseGroup());
            if (timeStamp != null)
            {
              currentReuse = (int) (timeStamp.getReuseCurrent() / 1000L);
              reuse = (int) (timeStamp.getReuseBasic() / 1000L);
            }
          }
        }
        shortcutInfo = new ItemShortcutInfo(shortCut.getType(), page, shortCut.getId(), reuseGroup, currentReuse, reuse, augmentationId, shortCut.getCharacterType());
        break;
View Full Code Here

   * @param skill Skill
   * @param delay long
   */
  public void disableSkill(Skill skill, long delay)
  {
    _skillReuses.put(skill.hashCode(), new TimeStamp(skill, delay));
  }
View Full Code Here

   * @param skill Skill
   * @return boolean
   */
  public boolean isSkillDisabled(Skill skill)
  {
    TimeStamp sts = _skillReuses.get(skill.hashCode());
    if (sts == null)
    {
      return false;
    }
    if (sts.hasNotPassed())
    {
      return true;
    }
    _skillReuses.remove(skill.hashCode());
    return false;
View Full Code Here

    if (success)
    {
      long nextTimeUse = item.getTemplate().getReuseType().next(item);
      if (nextTimeUse > System.currentTimeMillis())
      {
        TimeStamp timeStamp = new TimeStamp(item.getItemId(), nextTimeUse, item.getTemplate().getReuseDelay());
        activeChar.addSharedGroupReuse(item.getTemplate().getReuseGroup(), timeStamp);
        if (item.getTemplate().getReuseDelay() > 0)
        {
          activeChar.sendPacket(new ExUseSharedGroupItem(item.getTemplate().getDisplayReuseGroup(), timeStamp));
        }
View Full Code Here

  {
    if (isCastingNow())
    {
      return;
    }
    TimeStamp sts = getSkillReuse(skill);
    if ((sts == null) || !sts.hasNotPassed())
    {
      return;
    }
    long timeleft = sts.getReuseCurrent();
    if ((!Config.ALT_SHOW_REUSE_MSG && (timeleft < 10000)) || (timeleft < 500))
    {
      return;
    }
    long hours = timeleft / 3600000;
View Full Code Here

    if (success)
    {
      long nextTimeUse = item.getTemplate().getReuseType().next(item);
      if (nextTimeUse > System.currentTimeMillis())
      {
        TimeStamp timeStamp = new TimeStamp(item.getItemId(), nextTimeUse, item.getTemplate().getReuseDelay());
        addSharedGroupReuse(item.getTemplate().getReuseGroup(), timeStamp);
        if (item.getTemplate().getReuseDelay() > 0)
        {
          this.sendPacket(new ExUseSharedGroupItem(item.getTemplate().getDisplayReuseGroup(), timeStamp));
        }
View Full Code Here

TOP

Related Classes of lineage2.gameserver.skills.TimeStamp

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.