Jump to content

Recommended Posts

Posted

I added that in last update before you did it lol xD

 

I dint see it ... btw now is more complete .... :) This event will have.... much fun .. in game xD

 

p.s: My method are more simple ;P

Posted

good job Vago! btw about the admin to change the war town its more simple to create a HTML and add it on //admin panel so admin will choose right away what town will be a pvp zone! i am gona do it tomorrow and let you know what i am talking about;)

Posted

Nice..

But on Infinityskils when you win the event you got encheant.. Exe:On erica if you win you got +50 on weapon... Auto.

 

Go to the L2PcInstance and under the townwar pvp reward add something like that:

if (activeChar.consecutiveKillCount > 20)
{
// set enchant value
player.getInventory().unEquipItemInSlotAndRecord(armorType);
itemInstance.setEnchantLevel(ench);
player.getInventory().equipItemAndRecord(itemInstance);

// send packets
InventoryUpdate iu = new InventoryUpdate();
iu.addModifiedItem(itemInstance);
player.sendPacket(iu);
player.broadcastPacket(new CharInfo(player));
player.sendPacket(new UserInfo(player));
}

To make the consecutiveKillCount look at the hero shine on pvp kill by Vago:)

 

The armor type need to be changed only i think.The armor types:

PAPERDOLL_HEAD

PAPERDOLL_CHEST

PAPERDOLL_GLOVES

PAPERDOLL_FEET

PAPERDOLL_LEGS

PAPERDOLL_RHAND

PAPERDOLL_LHAND

PAPERDOLL_LEAR

PAPERDOLL_REAR

PAPERDOLL_LFINGER

PAPERDOLL_RFINGER

PAPERDOLL_NECK

PAPERDOLL_UNDER

PAPERDOLL_BACK

FOR BOW CROSSBOW AND 2HANDED WEAPONS ONLY:

PAPERDOLL_LRHAND

 

Posted

Patch updated:

 

- Not that huge patch anymore

- Now startTW and endTW got their own methods so can be recalled on startup etc...

 

good job Vago! btw about the admin to change the war town its more simple to create a HTML and add it on //admin panel so admin will choose right away what town will be a pvp zone! i am gona do it tomorrow and let you know what i am talking about;)

 

I will later today...At the moment I gotta go

Posted

nice vago ima test this later on today..anyway

heres a cuuki for ya XD

 

cookie-bite-web.jpg

 

]and sry about the bite...it was looking nice XD

Posted

another idea is , when the event is starting , it would be cool if there were 5-6 announcements saying : 1. LETS , 2. START , 3. THE , 4. EVENT!!!! ,5. EVENT STARTED IN "x" TOWN!! , one after the other after 1 second for example

Posted

I have troubles compiling

compile:
    [javac] Compiling 1371 source files to C:\Documents and Settings\Friso\workspace\L2J_GameServer\build\classes
    [javac] C:\Documents and Settings\Friso\workspace\L2J_GameServer\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:5176: cannot find symbol
    [javac] symbol  : method isinTownWar()
    [javac] location: class net.sf.l2j.gameserver.model.actor.instance.L2PcInstance
    [javac]     	    	if (isinTownWar())
    [javac]     	    	    ^
    [javac] C:\Documents and Settings\Friso\workspace\L2J_GameServer\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:5234: cannot find symbol
    [javac] symbol  : method isinTownWar()
    [javac] location: class net.sf.l2j.gameserver.model.actor.instance.L2PcInstance
    [javac]        if (!isinTownWar())
    [javac]             ^
    [javac] C:\Documents and Settings\Friso\workspace\L2J_GameServer\java\net\sf\l2j\gameserver\model\actor\instance\L2PcInstance.java:5238: cannot find symbol
    [javac] symbol  : method isinTownWar()
    [javac] location: class net.sf.l2j.gameserver.model.actor.instance.L2PcInstance
    [javac]               	if (isinTownWar())
    [javac]               	    ^
    [javac] C:\Documents and Settings\Friso\workspace\L2J_GameServer\java\net\sf\l2j\gameserver\handler\admincommandhandlers\AdminTownWar.java:96: cannot find symbol
    [javac] symbol  : method setInTownWar(boolean)
    [javac] location: class net.sf.l2j.gameserver.model.actor.instance.L2PcInstance
    [javac] 					onlinePlayer.setInTownWar(true);
    [javac] 					            ^
    [javac] C:\Documents and Settings\Friso\workspace\L2J_GameServer\java\net\sf\l2j\gameserver\handler\admincommandhandlers\AdminTownWar.java:152: cannot find symbol
    [javac] symbol  : method setInTownWar(boolean)
    [javac] location: class net.sf.l2j.gameserver.model.actor.instance.L2PcInstance
    [javac] 					onlinePlayer.setInTownWar(false);
    [javac] 					            ^
    [javac] Note: C:\Documents and Settings\Friso\workspace\L2J_GameServer\java\net\sf\l2j\gameserver\handler\admincommandhandlers\AdminTownWar.java uses or overrides a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.
    [javac] 5 errors

BUILD FAILED

Your help would be appreciated ^^

Posted

try to insert it manually first because the diff files are not correct for all packs and all revisions

 

Ps.:Reported on l2j forum

 

What i found:

1. Event starts and ends normally

2. you can set use of GK or not.

3. announces events as described.

 

Bugs:

 

Does not set peace zone to PvP or arena zone, on the console it states that it reloaded zones, and on exit states reloaded zone, but in game there is no change, and when you select ALL TOWNS it gives bad request error on console and does nothing at all ingame. havene't been able to test Reward since event wont start.

Posted

Sry for double post but i need that i try to fix this event to make it work but i cant test it right now:S

So if somebody can test that for me post the results here plz.

 

in the admintownwar.java added boolean to handle the true false of peace zone:

   /**
* @return
*/
private final boolean isPeaceZone()
{
boolean _isPeaceZone = true;
return _isPeaceZone;
}

 

I change that:

TownManager.getTown(Config.TW_TOWN_ID).setParameter("isPeaceZone", "false");

to that that means if the town is peace zone the peace zone set to false:

    	  TownManager.getTown(9);
   	  if(isPeaceZone())
   	  {
   		  boolean _isPeaceZone = false;
   	  }

 

And i changed that:

TownManager.getTown(Config.TW_TOWN_ID).setParameter("isPeaceZone", "true");

to that that means the town is peace zone again:

TownManager.getTown(9);
   	  if(!isPeaceZone())
   	  {
   		  boolean _isPeaceZone = true;
   	  }

 

Its compiled for me just need some test.

Posted

wont work simply because your boolean isPeaceZone is used only inside AdminTownWar and has nothing to do with players location, position, L2TownZone or ZoneManager...

Posted

The problem is when you change the zone of peace in general, there is no need to recharge areas with ZoneManager.load ();.

 

First remove static. Then try the following:

 

TownManager.getInstance().getTown(CodTown).setParameter("isPeaceZone", "false");

   

    Collection<L2PcInstance> pls = L2World.getInstance().getAllPlayers().values();

   

    int xx,yy,zz;

    L2TownZone Town;

    byte zonaPaz = 1;

   

    for (L2PcInstance onlinePlayer : pls)

    if (onlinePlayer.isOnline() == 1 )

    {

    onlinePlayer.setInTownWar(true);

    xx = onlinePlayer.getX();

    yy = onlinePlayer.getY();

    zz = onlinePlayer.getZ();

   

    Town = TownManager.getInstance().getTown(xx,yy,zz);

   

    if(Town.getTownId() == CodTown)

    {

   

    onlinePlayer.setInsideZone(zonaPaz, false);

   

    }

   

    onlinePlayer.revalidateZone(true);

    }

 

 

 

when the event ends, it is the same, only changes

 

onlinePlayer.setInsideZone(zonaPaz, true);

;)

Guest
This topic is now closed to further replies.



  • Posts

    • Where I can buy a cheap domain .com? cheapest I found was on Godaddy for 12 euro and Hostinger for 10 euro.
    • Hello everyone, here's a simple and useful idea for any type of server.   This code applies a discount when a player makes a purchase inside a clan’s castle or clan hall, offering a benefit to clan members who own a castle or clan hall. Important: Merchant transactions must be handled through multisell, not buylist. The discount is directly applied within the multisell, so the price shown is already reduced.   "For example, if a scroll costs 1000 Adena and you set a 20% discount in the config, the final price when purchasing inside a castle or clan hall will be 800 Adena."   This code is developed on the public aCis 401 revision.   public static int CLAN_BASE_OWNERSHIP_MERCHANT_DISCOUNT; CLAN_BASE_OWNERSHIP_MERCHANT_DISCOUNT = clans.getProperty("ClanBaseOwnershipMechantDiscount", 20); # If clan owns a clan hall or castle, all members have a discount of X% at merchant transactions (multisell). # Discount applies only inside the base (castle or clan hall). ClanBaseOwnershipMechantDiscount = 20   /** diff --git a/aCis_gameserver/java/net/sf/l2j/gameserver/data/xml/MultisellData.java b/aCis_gameserver/java/net/sf/l2j/gameserver/data/xml/MultisellData.java index 556e111..bbf8e69 100644 --- a/aCis_gameserver/java/net/sf/l2j/gameserver/data/xml/MultisellData.java +++ b/aCis_gameserver/java/net/sf/l2j/gameserver/data/xml/MultisellData.java @@ -101,7 +101,7 @@ do { // send list at least once even if size = 0 - player.sendPacket(new MultiSellList(list, index)); + player.sendPacket(new MultiSellList(list, index, player)); index += PAGE_SIZE; } while (index < list.getEntries().size()); diff --git a/aCis_gameserver/java/net/sf/l2j/gameserver/network/clientpackets/MultiSellChoose.java b/aCis_gameserver/java/net/sf/l2j/gameserver/network/clientpackets/MultiSellChoose.java index 7c82c5b..1654abc 100644 --- a/aCis_gameserver/java/net/sf/l2j/gameserver/network/clientpackets/MultiSellChoose.java +++ b/aCis_gameserver/java/net/sf/l2j/gameserver/network/clientpackets/MultiSellChoose.java @@ -6,6 +6,7 @@ import net.sf.l2j.Config; import net.sf.l2j.gameserver.enums.FloodProtector; import net.sf.l2j.gameserver.enums.StatusType; +import net.sf.l2j.gameserver.enums.ZoneId; import net.sf.l2j.gameserver.enums.items.CrystalType; import net.sf.l2j.gameserver.model.Augmentation; import net.sf.l2j.gameserver.model.actor.Player; @@ -225,6 +226,20 @@ return; } + if (player.isInsideZone(ZoneId.CLAN_HALL) && player.getClan() != null && player.getClan().hasClanHall()) + { + e.setItemCount(e.getItemCount() * (100 - Config.CLAN_BASE_OWNERSHIP_MERCHANT_DISCOUNT) / 100); + if (e.getItemCount() == 0) + e.setItemCount(1); + } + + if (player.isInsideZone(ZoneId.CASTLE) && player.getClan() != null && player.getClan().hasCastle()) + { + e.setItemCount(e.getItemCount() * (100 - Config.CLAN_BASE_OWNERSHIP_MERCHANT_DISCOUNT) / 100); + if (e.getItemCount() == 0) + e.setItemCount(1); + } + if (Config.BLACKSMITH_USE_RECIPES || !e.getMaintainIngredient()) { // if it's a stackable item, just reduce the amount from the first (only) instance that is found in the inventory diff --git a/aCis_gameserver/java/net/sf/l2j/gameserver/network/serverpackets/MultiSellList.java b/aCis_gameserver/java/net/sf/l2j/gameserver/network/serverpackets/MultiSellList.java index 9269b06..c6102a0 100644 --- a/aCis_gameserver/java/net/sf/l2j/gameserver/network/serverpackets/MultiSellList.java +++ b/aCis_gameserver/java/net/sf/l2j/gameserver/network/serverpackets/MultiSellList.java @@ -2,6 +2,9 @@ import static net.sf.l2j.gameserver.data.xml.MultisellData.PAGE_SIZE; +import net.sf.l2j.Config; +import net.sf.l2j.gameserver.enums.ZoneId; +import net.sf.l2j.gameserver.model.actor.Player; import net.sf.l2j.gameserver.model.multisell.Entry; import net.sf.l2j.gameserver.model.multisell.Ingredient; import net.sf.l2j.gameserver.model.multisell.ListContainer; @@ -15,7 +18,9 @@ private boolean _finished; - public MultiSellList(ListContainer list, int index) + private Player _player; + + public MultiSellList(ListContainer list, int index, Player player) { _list = list; _index = index; @@ -28,6 +33,8 @@ } else _finished = true; + + _player = player; } @Override @@ -74,7 +81,14 @@ { writeH(ing.getItemId()); writeH(ing.getTemplate() != null ? ing.getTemplate().getType2() : 65535); - writeD(ing.getItemCount()); + + if (_player.isInsideZone(ZoneId.CLAN_HALL) && _player.getClan() != null && _player.getClan().hasClanHall()) + writeD((ing.getItemCount() * (100 - Config.CLAN_BASE_OWNERSHIP_MERCHANT_DISCOUNT) / 100) < 1 ? 1 : ing.getItemCount() * 80 / 100); + else if (_player.isInsideZone(ZoneId.CASTLE) && _player.getClan() != null && _player.getClan().hasCastle()) + writeD((ing.getItemCount() * (100 - Config.CLAN_BASE_OWNERSHIP_MERCHANT_DISCOUNT) / 100) < 1 ? 1 : ing.getItemCount() * 80 / 100); + else + writeD(ing.getItemCount()); + writeH(ing.getEnchantLevel()); writeD(0x00); // TODO: i.getAugmentId() writeD(0x00); // TODO: i.getManaLeft()  
    • DISCORD : utchiha_market telegram : https://t.me/utchiha_market SELLIX STORE : https://utchihamkt.mysellix.io/ Join our server for more products : https://discord.gg/uthciha-services https://campsite.bio/utchihaamkt
    • WTB EXP ETERNAL 10x new dm.
    • This project is based on the latest public aCis sources (revision 401) and supports a multi-client system (C4 & IL), making it suitable for custom usage but not for retail.   You can configure the SelectedClient option in server.properties and loginserver.properties to switch between C4 and IL.  Both clients are fully synchronized, including login, server selection, packets, and geodata.   Notable Features: - Completed the login and server selection phase for both clients. - Synchronized all packets to support both clients (including some specific features). - Reworked the datapack and SQL files (excluding HTML files) to work seamlessly with both clients. - Added geodata support for both clients. - Adapted nearly all AI, scripts, bosses, HTML, and MULTISELL files to match C4 functionality. - Reduced the maximum clan level from 8 to 5 (C4 feature). - Rewrote clan HTML to remove C5-C6 features.   Disabled the following C5 and C6 features: - Divine Inspiration (C6 feature). - Clan skills and clan reputation points (C5 feature). - Pledge class (C5 feature). - Hero skills (C5 feature). - Dueling system (C6 feature). - Augmentations (C6 feature). - Cursed weapons (C5-C6 feature).   General Improvements: - Performed a general HTML cleanup and optimized features based on the client version. - Added an option to display the remaining time of disabled skills. - Skill timestamps now update when using the skill list.   This flexibility allows you to create a unique progression system tailored to your needs. The price for the diff patch, which can be applied to aCis public sources, is €150. For inquiries, please contact me via PM or Discord (ID: @Luminous).
  • Topics

×
×
  • Create New...