Jump to content

luckies

Members
  • Posts

    15
  • Credits

  • Joined

  • Last visited

  • Feedback

    0%

About luckies

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

luckies's Achievements

Newbie

Newbie (1/16)

0

Reputation

  1. anyone can help ? code below /** The _shadow item. */ private final L2ItemInstance _shadowItem; /** * Instantiates a new schedule consume mana task. * @param item the item */ public ScheduleConsumeManaTask(final L2ItemInstance item) { _shadowItem = item; } /* * (non-Javadoc) * @see java.lang.Runnable#run() */ @Override public void run() { try { // decrease mana if (_shadowItem != null) { _shadowItem.decreaseMana(true); } } catch (final Throwable t) { if (Config.ENABLE_ALL_EXCEPTIONS) t.printStackTrace(); } } } /** * Returns true if this item is a shadow item Shadow items have a limited life-time. * @return true, if is shadow item */ public boolean isShadowItem() { return _mana >= 0; } /** * Sets the mana for this shadow item <b>NOTE</b>: does not send an inventory update packet. * @param mana the new mana */ public void setMana(final int mana) { _mana = mana; } /** * Returns the remaining mana of this shadow item. * @return lifeTime */ public int getMana() { return _mana; } /** * Decreases the mana of this shadow item, sends a inventory update schedules a new consumption task if non is running optionally one could force a new task. * @param resetConsumingMana the reset consuming mana */ public void decreaseMana(final boolean resetConsumingMana) { if (!isShadowItem()) return; if (_mana > 0) _mana--; if (_storedInDb) _storedInDb = false; if (resetConsumingMana) _consumingMana = false; L2PcInstance player = (L2PcInstance) L2World.getInstance().findObject(getOwnerId()); if (player != null) { SystemMessage sm; switch (_mana) { case 10: sm = new SystemMessage(SystemMessageId.S1S_REMAINING_MANA_IS_NOW_10); sm.addString(getItemName()); player.sendPacket(sm); break; case 5: sm = new SystemMessage(SystemMessageId.S1S_REMAINING_MANA_IS_NOW_5); sm.addString(getItemName()); player.sendPacket(sm); break; case 1: sm = new SystemMessage(SystemMessageId.S1S_REMAINING_MANA_IS_NOW_1); sm.addString(getItemName()); player.sendPacket(sm); break; } if (_mana == 0) // The life time has expired { sm = new SystemMessage(SystemMessageId.S1S_REMAINING_MANA_IS_NOW_0); sm.addString(getItemName()); player.sendPacket(sm); // unequip if (isEquipped()) { L2ItemInstance[] unequiped = player.getInventory().unEquipItemInSlotAndRecord(getEquipSlot()); InventoryUpdate iu = new InventoryUpdate(); for (final L2ItemInstance element : unequiped) { player.checkSSMatch(null, element); iu.addModifiedItem(element); } player.sendPacket(iu); unequiped = null; iu = null; } if (getLocation() != ItemLocation.WAREHOUSE) { // destroy player.getInventory().destroyItem("L2ItemInstance", this, player, null); // send update InventoryUpdate iu = new InventoryUpdate(); iu.addRemovedItem(this); player.sendPacket(iu); iu = null; StatusUpdate su = new StatusUpdate(player.getObjectId()); su.addAttribute(StatusUpdate.CUR_LOAD, player.getCurrentLoad()); player.sendPacket(su); su = null; } else { player.getWarehouse().destroyItem("L2ItemInstance", this, player, null); } // delete from world L2World.getInstance().removeObject(this); } else { // Reschedule if still equipped if (!_consumingMana && isEquipped()) scheduleConsumeManaTask(); if (getLocation() != ItemLocation.WAREHOUSE) { InventoryUpdate iu = new InventoryUpdate(); iu.addModifiedItem(this); player.sendPacket(iu); iu = null; } } sm = null; } player = null; } /** * Schedule consume mana task. */ private void scheduleConsumeManaTask() { _consumingMana = true; ThreadPoolManager.getInstance().scheduleGeneral(new ScheduleConsumeManaTask(this), MANA_CONSUMPTION_RATE); } /** * Returns false cause item can't be attacked. * @param attacker the attacker * @return boolean false */ @Override public boolean isAutoAttackable(final L2Character attacker) { return false; }
  2. Hello everyone, I find that its already disuss about this on this forum, but for aCis project, I just want to know how to edit code for Frozen Pack to make: Shadow items taking mana also in inventory not only equiped. I am newbie in this, and trying to find how the think conected / working. I am find this code, I am supposed that should be changed somehow. I will be glad for any help. Thank you (sorry for my bad english)
  3. luckies

    muhehe

    Enter the Gracia™ Final Player Guide and Tutorial Contest Dust off your creative writing hat, warm up your video editing skills, and jump into your favorite Gracia Final area to show everyone what the content from Gracia Final is all about! We are eager to see what clever, comprehensive, and useful guides and tutorials our players can create for the latest addition to Lineage® II, Gracia Final. We are accepting submissions for our Lineage II: Gracia Final Guide and Tutorial Contest in any form of media, including video, text, images, or any combination thereof. Entrants must create their own guides or tutorials for any new content introduced with Gracia Final and submit the guide or tutorial to the Lineage II team for review. All submitted entries must be your own, appropriate to the Lineage II world, and adhere to the Lineage II end user license agreement (EULA). The winner of the chosen guide or tutorial will be published with credit on the Lineage II website, receive 30 days of free game time and twenty Revita Pops! Three Runners Up will receive five Revita Pops. Prizes * Four prizes will be awarded. * NCsoft will publish the chosen guide(s) or tutorial(s) on the Lineage II website with credit given to the original creator of the guide or tutorial. * The creator of the first place chosen guide or tutorial will receive 30 days of free game time for use on any new or existing Lineage II account in good standing and twenty Revita Pops granted to one character of their choice. * Three Runners Up will receive 5 Revita Pops granted to one character of their choice and NCsoft may publish their submission on the Lineage II website with credit given to the creator. How to Enter 1. Send an e-mail to l2submissions@ncsoft.com with the subject heading "Lineage II: Gracia Final Player Guide/Tutorial Submission." Deadline to enter: 11:59 p.m. CST, Friday, July 31, 2009. 2. Include the following information in English in the body of the e-mail: * Your registered message board display name (if you are a member of the forum). * Your Lineage II game account name (the name you use to log in to the game). * Your main character name and server. * Your first and last name. * Your age. * Your location, including city, state/province, and country. * A contact phone number. (The phone number will not be shared with anyone. We only use it if we need a second method of contacting you regarding this contest.) 3. Attach your entry to the e-mail. You must follow the submission guidelines (see below). If you have multiple files as part of your submission (such as text and several images), please compress them into one file archive (zip format). Submission Guidelines * NCsoft will accept only one Lineage II tutorial or guide entry per person. * Acceptable file formats (other file formats will not be accepted): o Images: RGB jpg or bmp o Text: doc o Video: mov or avi * All entries must be less than 20MB size in total (before they are compressed into a zip file, if you do so to enter). * By submitting your guide or tutorial, you agree to all of the terms and conditions in the Lineage II: Gracia Final Player Guide and Tutorial Official Rules and Conditions, so read them carefully. Evaluation Criteria * The tutorial or guide may be about any new feature or content listed in the Patch Notes for the Gracia Final expansion. * All submissions will be judged on creativity, originality, and overall presentation. Eligibility To enter the contest: * As of Wednesday, July 1, 2009, you must be 13 years of age or older to participate and a legal resident of the United States (excluding the State of Rhode Island, and excluding Guam, Puerto Rico, U.S. territories, military installations and commonwealths), or Canada (excluding Quebec) (Canadian residents will be required to answer an additional mathematical question in order to claim their prize). * As of Wednesday, July 1, 2009, you must have a current Lineage II account with Internet access, an e-mail account, and access to a personal computer. Copyrighted Materials * You can use Lineage II images that NCsoft® owns in your submission. * You may not use in your submission any materials that you (or NCsoft®) do not own the rights to. * Taking an image from something that you (or NCsoft) do not own and altering it slightly and then presenting it as your own work is strictly prohibited. * You (or NCsoft) must have ownership rights to every element included in the entry you submit. * You must make sure your entry doesn't infringe on any patent, copyright, trademark, or other intellectual property right, or any privacy, publicity, or publishing rights of any third party, or is not libelous, obscene, or otherwise contrary to law.
  4. luckies

    a mistake

    i dont uderstund xD
×
×
  • Create New...