Last aCis updates

Started by Tryskell, January 04, 2011, 10:46:15 PM

Tryskell

Changeset 311

Pledge rework, Clans Wars, Misc (ty KaL for the good work)


Pledge rework
   - Unecessary packets removal and packet flood decreased (clan tab doesn't need to completely be refreshed for every update).
   - Correct use of PledgeShowMemberListAll and PledgeReceiveSubPledgeCreated.
   - Fixed a bug where clan members would be shown in main clan - no matter what his pledge type was - after logging out.
   - Sponsor and Apprentice are real-time updated and have their name listed in yellow, except for themselves (client handled).
   - RequestPledgeReorganizeMember updated : you can't send captains out of main clan.
   - A clan member can only be assigned as captain of ONE sub-unit.
   - L2Clan loading: a single query cares about clans loading, instead of one query for IDs + one query per loaded clan.
   - PledgeReceiveWarList better sniffed and documented (now there's a new option of war display. They are: Declared, Under Attack, Declare War (new, so far unused).
   - RequestSurrenderPledgeWar checks for priviledges (avoid packet exploit), although it's not certain that this packet is still used by Interlude client.
   - The "Party" column located in Priviledges panel correctly works. Drop RankPrivs getParty() system (wasn't used).
   - RequestPledgeMemberPowerInfo and RequestPledgeMemberInfo are better documented.
   - Fix ManagePledgePower packet.
   - broadcastToOnlineMembers() supports array of packets (avoid to create a list of clan members on every use).
   - When a player is invited to a clan, he is setted to the correct affiliation rank.
   - Sub-unit creation costs are setted to 5000 for Royal Guards && 10000 for Order of Knights (instead of 2500 for both).
   - Update member's siege state on clan invitation / leave.
   
Clan Wars
   - Clan War request checks :
      - You cannot send war to your own clan anymore.
      - You can send war to clans with less than 15 members, but only if it has declared war on you first.
      - A clan cannot have more than 30 active wars.
      - Check is made on member's privileges instead of clan leader.
      - You cannot send war against a dissolving clan.
   - Clan War stop check :
      - Cannot be stopped if any clan member is in combat.
   - War info tab updated: Under Attack list supports pagination (13 clans/page).
   - Clan War penalty : ending a Clan War brings 5 days penalty to the clan, so it cannot send war to the same clan again until it expires.
   - Drop useless columns in clan_wars table (wantspeace1, wantspeace2).
   - Command handlers 88, 89 && 90 show proper message if there are no wars/attackers.
   - SystemMessage 247 typo ("S1" requiered, because it has parameters).
   - Exp loss calculation considers if there's one-sided war.
   
Misc
   - Fix some Q219 HTMs encoding (was UTF-16 instead of ANSI).
   - /clanpenalty usercommand is reworked :
      - cache the HTM && default String.
      - add Clan War penalty in the possible choices.
      - fix content when numerous penalites are listed.
   - Addition of /siegestatus usercommand, I publically shared my implementation : http://www.l2jserver.com/forum/viewtopic.php?f=69&t=28345
   - Cleanup onKillUpdatePvPKarma( and associated methods.
   - Cleanup quests up to Q270.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

#211
Changeset 312

Quests, Community Board, Misc


Quests
   - Cleanup up to Q280.
   - Fix 2 issues on Q039 (sound and drop rate), ty Ailierynn for report.

Community Board - ty Erlandys
   - Rework Community Board system to allow more inheritance uses (logger, error messages, etc).
   - Polish && cache all HTMs content (and that was fucking long).
   - "Clan" tab
      - Send different clan details following randomer, member, or clan leader status.
      - Implements clan mail panel.
      - Implements clan management panel (with working introduction system).
      - Completed the implementation of clan notices system, merging "clan_notices" table with "clan_data" table which avoids SQL queries.
   - "Region" tab
      - Two panels are added listing castles / CHs owners (custom as not existing on retail, but follow GoD vision).
   - "Friend" tab
      - Implements Blocklist panel.
      - Implements friend mail panel.
   - "Mail" tab :
      - add the "girl voice" (sexy as a robot) when you receive a mail, and add a popup at Enterworld if you got unread waiting messages.
      - Cleanup core side.

Misc
   - addition of missing use of SystemMessage 1761, ty Trance for report.
   
TODO : rework "Top" && "Memo" tabs (didn't touch at all), implement "Clan" forums.

IMPORTANT : need to add 3 columns in clan_data. The whole organization for CB HTMs is also edited.

http://www.youtube.com/watch?v=ZUHPVlaFQZk#
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 313

Quests, Spawnlist, Sieges (part I), Misc


Quests
   - Cleanup up to Q300.
   - Fix an error on Q300 (missed a cond).
   - Add dropMultipleItems() method (used on Q108 && Q293 for the moment), ty Ailierynn.

Spawnlist
   - Add back artifacts spawns.
   - Add back 32030 spawn (Leopard's Dead Carcass).
   - Move 32090 spawn (Garden Sculpture, from Leopard's Dead Carcass location to guessed Broken Labyrinth location).

Sieges
   - SiegeManager
      - Drop the map storing artefacts and associated config (unused).
      - Use Config.java format for sieges configs (public static, no getters, THAT_WRITING_STYLE).
   - L2CastleChamberlain
      - Money for doors / traps is now took from player inventory, not clan warehouse.
      - Proper HTM for adena check on Castle Chamberlain (for doors /traps upgrades).
      - Drop of a double YOU_NOT_ENOUGH_ADENA message (already handled by reduceAdena()).
   - Rework Flame and Control systems (avoid to null/re-create maps, drop old SiegeSpawn class for TowerSpawn).
   - L2SwampZone && L2DamageZone inherits from a new zone, named L2CastleZoneType (inheriting itself from L2ZoneType).
      - L2DamageZone task is cleaned up (notably will cancel if value <= 0 instead of for looping doing nothing like an idiot).
   - Implements castle traps system.
      - You have to pay for activation.
      - Destroying a Flame Tower desactivates trap controlled by that Flame Tower.
      - Traps affect defenders aswell ("Once activated, the flames do not distinguish friend from foe.").
   
Misc
   - Fix AdminCreateItem handler (KaL you're fat), ty meX for report.
   - Rework setTarget(), in order it automatically sends MyTargetSelected (and StatusUpdate if the target can been isAutoAttackable()).
   - Fix splitting damage if you got a shield but are unarmed (should be considered as one handed, not fist), ty raphaelfersan.
   - Add 9 missing skilltypes in L2NpcTemplate addSkill(, meaning monsters will now use their whole skillset, ty xblx.
   - Cleanup almost all getSkillsArray() uses to use proper "skilltypes" maps when possible. Reduce the number of checks needed aswell.
   - Don't reward adenas in party if you're already maxed + slight method cleanup, ty xblx (didn't reuse the whole fix).
   - Fix guards behavior when they're under attack (you're supposed to be able to speak with them while fighting, n/c), ty Kenrix.
   - Fix next intention unlock while using a bow (must occur at 50% gauge). Didn't fix yet the casting intention (probably can be made editing intentions, instead of forcing it via a timed task).
   - Fix ShopPreviewInfo packet, ty Ailierynn.
   - More uses of getAttackType(), which reduces generated code (when only L2WeaponType was required).
   - addition of replace(String, int/long/double) methods in NpcHtmlMessage packet (which avoids a lot of visual long code).
   
PS : new SQL table for traps.
PS2 : zones XMLs are edited as traps zones need dedicated id. 70000 and 71000 ids are used.

IMOPRTANT : Some stuff are still bugged. More to be done / fixed / polished in next rev.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 314

Sieges (part II), Extractable, Misc


Sieges (part II)
   - Doors
      * rework doors upgrade system to introduce castleId column (avoid to generate StringBuilders).
      * broken door/wall SystemMessage is now broadcasted to defenders (and not to the door knownlist).
      * doors upgrades are correctly cleaned on midVictory (objects were holding old properties).
      * drop of _doorUpgrades Map and uses. It can be directly handled looking the door value.
      * spawnDoors method.
         - split content between closeDoors (used at start siege) and spawnDoors (midVictory / end siege). It avoids to send x2 broadcastStatusUpdate
         - drop of spawnDoors() to simply keep and use spawnDoors(boolean).
         - dead doors are supposed to be revived during midVictory.
         - don't process anymore doors upgrades loading during siege start / midvictory / end.
         - starting a siege shouldn't spawn doors, simply close them. If you mess with doors, use //spawn_doors.
   - Traps
      * the traps damage task cleanup is made during its lifetime, not everytime a player leaves the area.
      * add a message when a trap is broken, and another when it's triggered (broadcasted to defenders).
   - fix concurrent issues (fix weird siege behavior on attackers/defenders lists and artifact cast NPE).
   - drop the array on Siege constructor (getCastle() returns a simple Castle object), a Siege object is created with Castle object (created in same time). Avoid null checks/possibilities
   - You don't need 2 artifacts casting to midVictory Goddard / Schuttgart, only 1 is enough.
   - cleanup L2ControlTowerInstance, the list is created with the object (avoids null checks and the synchronized crap).
   
Extractable
   - rework Extractable handler
      - avoid to create dummies L2ItemInstance - without counting those generated by addItem
      - drop the check based on subclass
      - avoid a second for loop.
      - rework the 2 int arrays to be handled by a list of ItemHolder (addition of that holder, and creation of a folder for holders).
   - drop L2ExtractableProduct and associated system from L2EtcItem (postIL stuff).
   
Misc
   - cleanup few methods (uses aswell) - reduceAdena, addItem - which avoids visual issues, cloned sent packets, useless objects creation (dummies L2ItemInstance notably).
   - cleanup L2Observation (avoid to parse 2 times the same String, shorter code).
   - cleanup numerous (150+) String.valueOf( - due to previous revision introducing it directly embedded on NpcHtmlMessage. Probably some are left, but I dropped a good part already.
   - drop of L2EtcItem _isBlessed parameter.
   - revert some reduceHp( changes made on PcStatus, which was buggying falling damages and trap zones system (as attacker was null, it was returning).
   - had to slightly re-position how things are loaded in Gameserver.java (Seven Signs are now loaded before Castles).
   - drop the castle id check on (getCastle() != null && getCastle().getCastleId() > 0) - it is always > to 0... If it's not, you messed.
   - move the castle doors upgrades loading from Gameserver to DoorTable (more legit).
   - heavy cleanup of L2ClanHallManagerInstance.
   
PS : you need to edit castle_doorupgrade.
PS2 : L2ClanHallManagerInstance cleanup is untested.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 315

Quests, Misc


Quests
   - cleanup up to q330.
   - add setItemIds() method to replace questItemsIds = new int {}.
   - add hasQuestItems(int...) to avoid "hasQuestItems(int) && hasQuestItems(int) && hasQuestItems(int) &&..."
   - add hasAtLeastOneQuestItem(int...) to avoid "hasQuestItems(int) || hasQuestItems(int) || hasQuestItems(int) &&..."
   
Misc
   - Castles
      * sieges loading is reverted back (was messing in different points)
      * castles loading is only processed in CastleManager (avoid to split the loading on multiple sections).
   - L2DatabaseFactory is cleaned up, we dropped msSQL support and ConnectionCloser (handled by "try ()" Java 7 system).
   - Update the different libs up to latest (drop the debug message from C3P0).
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 316

Quests, Misc


Quests
   - cleaning up to Q350
   - addition of Q350 (+ dp/core support for crystals leveling). Compared to Hasha version :
      - addition of the itemget sound on a success.
      - change of % luck calculation (was messed).
      - slight edit on DP side (addition of all T. rex IDs, drop of the dummy Antharas ID).
      - slight edit on HTMs.
   
Misc
   - drop getExpertiseLevel() method, hardcoding values directly on the array.
   - add the possibility to script item usage for scripts (one use for Q350, but can be useful for your custom scripts).
   - cleanup double checks on clan leveling.
   - fix a NPE (death penalty, due to attacker being possibly null from last revision).
   - add a missing break on RequestActionUse (cases 61 / 1000 were melted).
   - add a security check on RequestShortCutDel (ty Root).
   - fix an issue with static objects targeting (due to previous setTarget rework).
   - sit stuff
      - cleanup isSitting() check, avoid to send twice CharSit packet to yourself.
      - methods unification for the different uses.
      - delayed action for /sit is now implemented.
      - when a throne is targeted, the player runs to it, and sit on destination if it's too far.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 317

Quests, Misc


Quests
   - cleaning up to Q360.
      - numerous drop rate edits.
      - fix one HTM not correctly shown on Q354 (case where QItems are superior to 100).
      - fix class change quests to be not repeatable, and add the socialAction packet.
      - fix Q357 reward system, and some HTM typos.
   - addition of Q211, Q213 - ty roko91.
   
Misc
   - drop SkillsEngine singleton ; those different methods are now handled directly on concerned sections (ItemTable and SkillTable).
   - split npcs.xml into multiple files, following Pauler (L2JPes) method (it was commited into a single big file because I didn't find a valid splitting method).
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 318

Quests, Skills, Misc


Quests
   - addition of Q225, ty to sharer.

Skills
   - drop TARGET_ITEM && TARGET_CORPSE_CLAN target types.
   - cleanup few target types, in order to avoid to recalculate numerous times the caster<>victim distance (when handled by getKnownTypeInRadius).
   - rework TARGET_CORPSE_MOB in order to drop a ClassCastException (you can't "corpse life steal" summons anymore).
   - fix Mass Resurrection skill, ty sahar.
   
Summons
   - add support for Sin Eater skill (suicide aura skill + few random chat).
   - all "betray" checks got their appropriate user messages.
   - passive summons such as Sin Eater, Big Boom or Wyvern shouldn't be able to use Attack button.
   - fix a ClassCastException when you tried to attack L2StaticObject (thrones, etc) using the Attack button. It's an invalid target from now.
   
Misc
   - enchant boni are now refreshed if +4/+6 from admin panel. Decreasing enchant value also works.
   - cleanup L2ArmorSet methods, allowing less inventory checks (up to 3 times with is6Enchanted method use).
   - fix cellpathfinding geodata option (massive NPEs from javolution drop), ty Hasha.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

#218
Changeset 319

GM commands, Skills / Formulas, Misc - Part I


GM commands
   - addition of //knownlist : allow to check target's knownlist. Eventually, the use of that command would be extended later.
   - from now, //gm schedules the rollback of the previous accesslevel (allow easy testing without manual accessLevel drop/add + character relog). Default 1 minute.

Skills / Formulas
   - rework Func and classes holding such data (notably moving from [] to List).
   - rework Env to match with latest L2J (getters / setters, "div/mul/add/sub"Value methods, getPlayer() addition).
   - drop numerous unused Conditions (9 overall).
   - rework calcHitMiss method (roughly -10% success compared to before), add night and Z+- modifiers, lower behind and side modifiers (from 20/10 to 10/5).
   - fix gladiators charge system. It matches L2OFF IL.
   - matkModifier && levelModifier ratios from skills % landrate are reworked, as it is currently totally breaking formulas.
   
Misc
   - numerous cleanups (complete some javadoc, drop useless methods, reorganize checks in order to avoid to calculate not needed stuff).
   - fix a NPE caused by selecting "show skills" chat option on a skill trainer NPC with no active target.
   - doors getName() is correctly setted, while internal getDoorName() and _name dissapear.
   - revert some sections of rev 239 concerning sieges dates. Drop 7 signs period check aswell (not existing on retail).
   - fix few concurrency weaknesses.

Part I means there's a part II, it's UNSTABLE. Use it at your own risks. There were too much edits to be able to re-read what I edited, I decided to commit it like that.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 320

Sieges, MDT (Part I), Misc


Sieges
   - fix registration date end calculation (cf : Siege participation registration is closed twenty-four hours before the start of the siege.).
   - registration date is now calculated on server startup, and based on siege date (it was missing).
   - move siege logs when a new date is setted, not on server startup (well if your server had old dates and need refresh it will show, but otherwise it won't).
   - rework startAutoTask() in order to avoid to cancel/set twice ScheduleStartSiegeTask (if date is too old and need to be edited).
   
Monster Derby Track - part I
   - announcements aren't broadcasted twice anymore and are based on zone types, not on L2RaceManager knownlists.
   - race informations are now refreshed on player teleport (can see properly monsters).
   - set the default race number to 1 instead of 4.
   - setup race announcements like L2OFF, using a 20min game cycle rather than 10min.
   - move the entire race system logic from L2RaceManagerInstance to MonsterRace. Reduce the number of running tasks from 40 (20 per NPC) to 1.
   - newSpeeds() isn't processed twice anymore (dropped from newRace() end).
   - newRace() logic is rewritten (avoid to get NPC clones, better performance).
   - implements "View Past Results" button (holding past races informations up to 7 races).
   
Misc
   - fix few warnings spotted by new Eclipse version, ty SweeTs.
   - fix previous commit regarding //enchant admincommand (was testing with only me online, so didn't see this coming), ty SweeTs.
   - fix FuncMAtkCritical, ty sahar to point it.
   - add 2 methods to broadcast crap, toAllPlayersInZoneType() and toAllPlayersInRegion(). Each allow numerous packets as parameter.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 321

MDT (part II), Misc


MDT (part II) - a big thanks to roko91 for odd calculation ^^.
   - move MonsterRace in most appropriate section (instancemanager.games)
   - add data persistance :
      - current race state is saved on race end. The current race number is retrieved from history aswell.
      - bets on lanes (from CURRENT race) are saved on ticket obtention. It allows to recalculate odds without errors.
   - fix previous commit regarding "View Past Results" button (records should be shown from newest race to oldest).
   - add odds rate calculation per lane (happens at "tickets sales closed" event).
   - the odd of the first place is now saved on HistoryInfo.
   - drop double message on ticket obtention.
   - implements "Calculate Winnings" button (3 different bypasses, with numerous checks).

Misc
   - add retail HTM when you got too much quests. Ty Root.
   - fix a ConcurrentModificationException ; slight rework of L2SiegeClan. Ty sahar.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 322

Trove drop, Misc


Trove drop
   - drop entirely usage of that library, as there is almost no impact on performance.
   - basically :
      - TIntObjectHashMap : Map<Integer, Object>
      - TIntIntHashMap : Map<Integer, Integer>
      - TShortObjectHashMap : Map<Short, Object>
      - TIntArrayList : List<Integer>

Misc
   - remove/add the SA if a weapon grade penalty occurs/doesn't occur. Ty KaL for the idea.
   - cleanup sortHeroesToBe() method.
   - fix map_regions.xml in order 20_25 and 21_25 teleport to Talking Island (fix Elven Ruins).
   - fix a sit visual bug. Ty Kingzor.
   - fix siege skills on subclass change, and drop a double use of restoreDeathPenaltyBuffLevel(). Ty Kingzor.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 323

Misc

   - numerous cleanups (Javadocs, formatting, methods renaming, organizing classes, etcs).
      - AutoSpawnHandler > AutoSpawnManager (moved to instancemanager)
      - RecipeController > RecipeTable (moved to datatables)
      - SevenSigns / SevenSignsFestival (moved to instancemanager)
      - CursedWeapon (moved to model.entity)
      - model.partymatching folder creation (moved 3 classes inside)
      - numerous "L2" drops on names (L2Item, L2Weapon, L2Armor, etc). More to come.
      - Item renamed NewItem (because of L2Item renamed Item), and internal Item (another one) class dropped for ItemHolder use.
   - rework checkPvpSkill method. Ty Kingzor for the buff/heal fix.
   - recipes lists are on Collection from now (avoids operations from/to arrays).
   - drop _charId, getter/setter. Use of getObjectId() on the few uses.
   - rework SkillDat (renamed for SkillUseHolder), avoiding to create a massive amount of objects (3 final objects per players refreshed on demand, instead of 1 created per casted/queued skill).
   - _currentPetSkill getSkill() is correctly setted to null after a pet skill cast.
   - [L2J 6477] fix a double login issue.
   - [L2J 6488] [L2J 6490] implements MaterialType, CrystalType enums. Cleanup ItemTable. Move and rename classes.
   - addition of missing sounds for boats, ty Root.
   
PS : you have to replace all items/skills XMLs, and few quests/scripts aswell.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

#223
Changeset 324

Scheme Buffer, Misc


Scheme Buffer
   - addition of Dr House scheme buffer, remasterized by me. The big differences are :
      - buffer buffs aren't loaded from a mySQL table, but from a Config line from npcs.properties (String split > register on Map).
      - there is no L2Skill storage anywhere, only Integers (skillId). The skillLevel is generated from SkillTable getMaxLevel().
      - the schemes loading/save is made GLOBALLY (understand, not on player login). Save is still done on server shutdown.
      - the players schemes buffs lists are stored on a single varchar, which is parsed with String split method (before there was one entry on the database per skill).
      - fix all godamn typos and broken english.
      - statified HTMs content when it could be.
      - reworked the "Edit my schemes" button to be more logical : select a scheme, THEN a skill group, THEN a buff. The HTM content also scales with that progression to make it intuitive.
      - added infos everywhere (such as current selected scheme, number of max buffs allowed, number of current buffs per scheme,...)
      - added "Heal" and "Cleanup effects" buttons (affect your current pet aswell).
      - the HTM system uses getHtmlPath(), meaning a different buffer npcId can be linked to different HTMs (unique dialogues for each buffer instance).
      
Misc
   - [L2J 6498] Drop double iterations on pet/player inventories deletion.
   - [L2J 6382] FourSepulchersManager cleanup - drop Map .remove(), use Map.Entry instead of keySet() + .get(), format the class.
   - addition of method broadcastTitleInfo() which uses TitleUpdate packet ; complete RequestGiveNickName clientpacket (adding numerous messages). Ty Root.
   - fix getMaxLevel() method, broken with Trove changeset.
   
PS : the Scheme Buffer is a first shot. If you manage to propose better/easier organization, I would eventually take it.

http://www.youtube.com/watch?v=x_xCXsM8Qpc#
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>

Tryskell

Changeset 325

Misc


Misc
   - Add retail HP/MP/CP calculation for players. Biggest change is the mana pool, which is drastically lower.
   - Add retail breath multiplier (based on race).
   - Add support for player radius / height (based on sex). There isn't yet uses of that system (bored to edit everywhere...) and values would still be rounded for an int anyway.
   - Move actors templates classes, rename them (drop "L2"), private the variable and add getters (PcTemplate). _baseCpMax is dropped, as there isn't base value for players anymore.
   - Slight cleanup (CharStatus, QuestTimer). Drop checks on doRegeneration (useless, handled by setCurrentX()).
   - [L2J 6301] Herbs aren't supposed to be delayed. Drop the task.
   
PS : track eventual errors on Quest, I have to revert the drop of the try/catch otherwise.
<html><body>Triskel:<br>
Triskel does not speak with foolish fellows who do not know their profession!
</body></html>