From 29311052753a682a89638596267d227267ca9014 Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Sun, 30 Jul 2017 10:13:11 +0000 Subject: [PATCH] Olympiad changes to match retail. --- .../others/OlyBuffer/OlyBuffer-afterBuff.html | 22 ++-- .../ai/others/OlyBuffer/OlyBuffer-index.html | 19 ++-- .../ai/others/OlyBuffer/OlyBuffer.java | 48 ++++---- .../others/OlyManager/OlyManager-awaken.html | 11 -- .../ai/others/OlyManager/OlyManager-info.html | 18 ++- .../OlyManager/OlyManager-infoHistory.html | 15 ++- .../OlyManager/OlyManager-infoPoints.html | 8 +- .../OlyManager/OlyManager-infoPointsCalc.html | 42 +++---- .../OlyManager/OlyManager-infoRules.html | 22 ++-- .../others/OlyManager/OlyManager-noNoble.html | 32 +++--- .../ai/others/OlyManager/OlyManager-rank.html | 97 +++++++++++------ .../ai/others/OlyManager/OlyManager.java | 103 +++++++++++------- 12 files changed, 225 insertions(+), 212 deletions(-) delete mode 100644 L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-awaken.html diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-afterBuff.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-afterBuff.html index 62d1700053..6dadbb7915 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-afterBuff.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-afterBuff.html @@ -1,20 +1,20 @@ - + diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-index.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-index.html index 8e3b99fe41..780e11c39f 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-index.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer-index.html @@ -7,15 +7,16 @@ diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer.java b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer.java index 313c234057..4d353489a0 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer.java +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyBuffer/OlyBuffer.java @@ -16,11 +16,9 @@ */ package ai.others.OlyBuffer; -import com.l2jmobius.commons.util.CommonUtil; -import com.l2jmobius.gameserver.data.xml.impl.SkillData; import com.l2jmobius.gameserver.model.actor.L2Npc; import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance; -import com.l2jmobius.gameserver.model.skills.Skill; +import com.l2jmobius.gameserver.model.holders.SkillHolder; import ai.AbstractNpcAI; @@ -33,17 +31,18 @@ public final class OlyBuffer extends AbstractNpcAI // NPC private static final int OLYMPIAD_BUFFER = 36402; // Skills - private static final int[] ALLOWED_BUFFS = + private static final SkillHolder[] ALLOWED_BUFFS = { - 14738, // Olympiad - Horn Melody - 14739, // Olympiad - Drum Melody - 14740, // Olympiad - Pipe Organ Melody - 14741, // Olympiad - Guitar Melody - 14742, // Olympiad - Harp Melody - 14743, // Olympiad - Lute Melody - 14744, // Olympiad - Knight's Harmony - 14745, // Olympiad - Warrior's Harmony - 14746, // Olympiad - Wizard's Harmony + new SkillHolder(4357, 2), // Haste Lv2 + new SkillHolder(4342, 2), // Wind Walk Lv2 + new SkillHolder(4356, 3), // Empower Lv3 + new SkillHolder(4355, 3), // Acumen Lv3 + new SkillHolder(4351, 6), // Concentration Lv6 + new SkillHolder(4345, 3), // Might Lv3 + new SkillHolder(4358, 3), // Guidance Lv3 + new SkillHolder(4359, 3), // Focus Lv3 + new SkillHolder(4360, 3), // Death Whisper Lv3 + new SkillHolder(4352, 2), // Berserker Spirit Lv2 }; private OlyBuffer() @@ -71,21 +70,16 @@ public final class OlyBuffer extends AbstractNpcAI if (event.startsWith("giveBuff;") && (npc.getScriptValue() < 5)) { final int buffId = Integer.parseInt(event.replace("giveBuff;", "")); - if (CommonUtil.contains(ALLOWED_BUFFS, buffId)) + if (ALLOWED_BUFFS[buffId] != null) { - final Skill buff = SkillData.getInstance().getSkill(buffId, 1); - if (buff != null) - { - npc.setScriptValue(npc.getScriptValue() + 1); - addSkillCastDesire(npc, player, buff, 23); - htmltext = "OlyBuffer-afterBuff.html"; - } - - if (npc.getScriptValue() >= 5) - { - htmltext = "OlyBuffer-noMore.html"; - getTimers().addTimer("DELETE_ME", 5000, evnt -> npc.deleteMe()); - } + npc.setScriptValue(npc.getScriptValue() + 1); + addSkillCastDesire(npc, player, ALLOWED_BUFFS[buffId], 23); + htmltext = "OlyBuffer-afterBuff.html"; + } + if (npc.getScriptValue() >= 5) + { + htmltext = "OlyBuffer-noMore.html"; + getTimers().addTimer("DELETE_ME", 5000, evnt -> npc.deleteMe()); } } return htmltext; diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-awaken.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-awaken.html deleted file mode 100644 index fea7f684f7..0000000000 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-awaken.html +++ /dev/null @@ -1,11 +0,0 @@ - -
Please choose buff skills from below.
- (Harmony buffs are not stackable.)
Please choose buff skills from below.

- - - - - - - - - + + + + + + + + + +

- - - - - - - - - + + + + + + + + + +
- - - - - - - -
(Only level 85 or higher Noblesse characters of an Awakened class
can participate in the Olympiad games.)
- \ No newline at end of file diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-info.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-info.html index 1f4147b1f1..3b393cc54e 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-info.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-info.html @@ -1,11 +1,9 @@ -Grand Olympiad Manager:
-Before partaking in the Olympiad, -why don't you learn about some of its history, rules, and point system?
- - - - - - - +Olympiad Manager:
+Here you can get familiar with the rules of the Olympiad.
+Learn about the Olympiad Points and then proceed to the competitions.

+ + + + + \ No newline at end of file diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoHistory.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoHistory.html index 02f5688e20..5a46ed2fe0 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoHistory.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoHistory.html @@ -1,9 +1,8 @@ -Grand Olympiad Manager:

+Olympiad Manager:

-This is the Grand Olympiad.
-Do you know much about its history?
-No?
-Well, during the mythical era of giants, the arena was created to foster peace and understanding among the races.

- -
- \ No newline at end of file +The Olympiad is famous for its ancient hystory.
+In the legendary times of Giants,
+there was a competition held in order to establish peace and harmony between the tribes.
+This was what we know as the Grand Olympiad.

+ + diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPoints.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPoints.html index 182e410347..daca0e88b6 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPoints.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPoints.html @@ -1,6 +1,4 @@ -Grand Olympiad Manager:
-In order to become a hero, you must earn more Grand Olympiad Points in the time period than any other contestant. If you participate in a certain number of games, you can also exchange Grand Olympiad Points for Olympiad Tokens.
-
- -
+Olympiad Manager:
+Grand Olympiad Points are required to become a hero. A Character who collects the largest amount of points among his or her class representatives becomes a hero of the current period. If you participate in the competitions more times than allowed, then you can receive Grand Olympiad Points as Marks of Battle.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPointsCalc.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPointsCalc.html index fa6211fc7c..fa7f449eb6 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPointsCalc.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoPointsCalc.html @@ -1,30 +1,14 @@ -Grand Olympiad Manager:
-Once the Olympiad cycle ends, participating Noblesse are ranked by their Olympiad Points and given new points according to rank. You must participate in 10 or more matches within one Olympiad cycle in order to earn points. You can exchange 1 Olympiad Point for 20 Marks of Battle. For example, 45 Points are worth 900 Marks of Battle.
-Heroes, and those qualified to become one, receive additional Olympiad Tokens equivalent to 30 Marks of Battle. Those who win at least once in one cycle receive 10 bonus points.

-
- - - - - - - - - - - - - - - - - - - -
RankCriteriaPoints
1st PlaceTop 1%60 pts
2nd PlaceTop 10%50 points
3rd PlaceTop 25% 45 pts
4th PlaceTop 50%40 points
5th PlaceBottom 50%30 pts
1 or more wins in one cycleBonus10 pts
No wins in one cycleBonus 5 pts
-
-

-
- -
+Olympiad Manager:
+After the Olympiad is over, Points of all participants are compared, and ranks are assigned, according to which the reward is allocated as points. To receive the Olympiad Points, you have to participate in 10 or more competitions in 1 month. The Olympiad Points you receive can be exchanged for Battle Marks. 20 Marks of Battle are issued per each Olympiad Point. For example, a participant earned Rank 3 and 50 Olympiad Points. If he or she receives the reward as Battle Marks, it will be 1,000 Battle Marks.
Heroes and the characters who obtained the right to become a hero are given an additional reward as Battle Marks which is equal to 300 Points. And those who gained at least one victory receive 10 Bonus Points.

+ + + + + + + + + +
RankingLv.Points
Rank 11% higher200 Points
Rank 210% higher80 Points
Rank 325% higher50 Points
Rank 450% higher30 Points
Rank 550% higher15 Points
More than 1 victoryCombination Bonus10 Points
Complete DefeatCombination Bonus0 Points


+ \ No newline at end of file diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoRules.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoRules.html index a252caa665..5709f61664 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoRules.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-infoRules.html @@ -1,13 +1,9 @@ -Grand Olympiad Manager:
-The Grand Olympiad has the following rules:
-The Olympiad is only available from 20:00 to 23:40 every Friday and Saturday.
-There are two types of Olympiad matches: class-specific, and free-for-all.
-To become a hero of the Grand Olympiad, you must win the highest number of matches. The person or team who inflicts the most damage on their opponent -- not on the opponent's servitor, golem, or pet -- will be declared the winner.
-The winner of a match takes Olympiad Points from the loser, amounting to 1/5th of the total points belonging to whoever had less at the beginning. -For example, if one participant has 60 points and the other has 40, the winner of the match would receive 8 points (1/5th of 40), while the loser would lose 8 points. In a draw, each would lose 1/5 of their own points.
-The maximum number of points at stake is capped at 10.
-At the beginning of the Olympiad, and at regular intervals throughout the contest, all participants will be awarded a small amount of points. Contestants must have at least 1 point in order to compete in a match.
-
- -
- \ No newline at end of file +Olympiad Manager:
+Every participant of the Grand Olympiad must know its rules.
+The Olympiad is held every week, on Fridays and Saturdays from 8:00 p.m. till 11:40 p.m.
+In order to become a hero at the Grand Olympiad, you must gain numerous victories. The winner is determined by the amount of damage dealt. Damage inflicted on a pet has no effect upon the victory.
+The winner takes a certain amount of Olympiad Points from the loser. The number of points transferred from the loser to the winner is determined as follows: the number of points of the winner and loser is compared, and then the winner receives 1/5 of points of the smaller amount. The same amount is subtracted from the loser's score. If the result is a draw, both parties lose 1/5 of their points.
+The maximum number of added/subtracted points for winning/losing is 10.
+Olympiad Points are earned during the Olympiad season and allocated at certain intervals. At least one Olympiad Point is required to participate in the fights.
+ + \ No newline at end of file diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-noNoble.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-noNoble.html index 193ca6daf4..546f544da1 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-noNoble.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-noNoble.html @@ -1,19 +1,23 @@
- - - -
- - - - - - - - - -
Welcome to the Olympiad.
(Only level 85 or higher Noblesse characters of an Awakened class
can participate in the games.)
+ + + +
+ + + + + + + + + +
Welcome to the Olympiad!
(You have to reach Lv. 55 and complete
the 2nd Class Transfer to participate.)
+
+
\ No newline at end of file diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-rank.html b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-rank.html index fcfec5065e..343fcb5843 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-rank.html +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager-rank.html @@ -1,42 +1,67 @@


Olympiad Ranking - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
diff --git a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager.java b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager.java index d22a8b9b16..5de61263fd 100644 --- a/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager.java +++ b/L2J_Mobius_Classic/dist/game/data/scripts/ai/others/OlyManager/OlyManager.java @@ -144,9 +144,9 @@ public final class OlyManager extends AbstractNpcAI implements IBypassHandler { htmltext = "OlyManager-subclass.html"; } - else if (!player.isInCategory(CategoryType.AWAKEN_GROUP)) + else if ((!player.isInCategory(CategoryType.THIRD_CLASS_GROUP) && !player.isInCategory(CategoryType.FOURTH_CLASS_GROUP)) || (player.getLevel() < 55)) // avoid exploits { - htmltext = "OlyManager-awaken.html"; + htmltext = "OlyManager-noNoble.html"; } else if (Olympiad.getInstance().getNoblePoints(player) <= 0) { @@ -241,42 +241,67 @@ public final class OlyManager extends AbstractNpcAI implements IBypassHandler } break; } - case "rank_148": // Sigel Phoenix Knight - case "rank_149": // Sigel Hell Knight - case "rank_150": // Sigel Eva's Templar - case "rank_151": // Sigel Shillien Templar - case "rank_152": // Tyrr Duelist - case "rank_153": // Tyrr Dreadnought - case "rank_154": // Tyrr Titan - case "rank_155": // Tyrr Grand Khavatari - case "rank_156": // Tyrr Maestro - case "rank_157": // Tyrr Doombringer - case "rank_158": // Othell Adventurer - case "rank_159": // Othell Wind Rider - case "rank_160": // Othell Ghost Hunter - case "rank_161": // Othell Fortune Seeker - case "rank_162": // Yul Sagittarius - case "rank_163": // Yul Moonlight Sentinel - case "rank_164": // Yul Ghost Sentinel - case "rank_165": // Yul Trickster - case "rank_166": // Feoh Archmage - case "rank_167": // Feoh Soultaker - case "rank_168": // Feoh Mystic Muse - case "rank_169": // Feoh Storm Screamer - case "rank_170": // Feoh Soul Hound - case "rank_171": // Iss Hierophant - case "rank_172": // Iss Sword Muse - case "rank_173": // Iss Spectral Dancer - case "rank_174": // Iss Dominator - case "rank_175": // Iss Doomcryer - case "rank_176": // Wynn Arcana Lord - case "rank_177": // Wynn Elemental Master - case "rank_178": // Wynn Spectral Master - case "rank_179": // Aeore Cardinal - case "rank_180": // Aeore Eva's Saint - case "rank_181": // Aeore Shillien Saint - case "rank_188": // Eviscerator - case "rank_189": // Sayha's Seer + case "rank_2": // Gladiator + case "rank_3": // Warlord + case "rank_5": // Paladin + case "rank_6": // Dark Avenger + case "rank_8": // Treasure Hunter + case "rank_9": // Hawkeye + case "rank_12": // Sorcerer + case "rank_13": // Necromancer + case "rank_14": // Warlock + case "rank_16": // Bishop + case "rank_17": // Prophet + case "rank_20": // Temple Knight + case "rank_21": // Sword Singer + case "rank_23": // Plains Walker + case "rank_24": // Silver Ranger + case "rank_27": // Spellsinger + case "rank_28": // Elemental Summoner + case "rank_30": // Elven Elder + case "rank_33": // Shillien Knight + case "rank_34": // Bladedancer + case "rank_36": // Abyss Walker + case "rank_37": // Phantom Ranger + case "rank_40": // Spellhowler + case "rank_41": // Phantom Summoner + case "rank_43": // Shillien Elder + case "rank_46": // Destroyer + case "rank_48": // Tyrant + case "rank_51": // Overlord + case "rank_52": // Warcryer + case "rank_55": // Bounty Hunter + case "rank_88": // Duelist + case "rank_89": // Dreadnought + case "rank_90": // Phoenix Knight + case "rank_91": // Hell Knight + case "rank_92": // Sagittarius + case "rank_93": // Adventurer + case "rank_94": // Archmage + case "rank_95": // Soultaker + case "rank_96": // Arcana Lord + case "rank_97": // Cardinal + case "rank_98": // Hierophant + case "rank_99": // Eva's Templar + case "rank_100": // Sword Muse + case "rank_101": // Wind Rider + case "rank_102": // Moonlight Sentinel + case "rank_103": // Mystic Muse + case "rank_104": // Elemental Master + case "rank_105": // Eva's Saint + case "rank_106": // Shillien Templar + case "rank_107": // Spectral Dancer + case "rank_108": // Ghost Hunter + case "rank_109": // Ghost Sentinel + case "rank_110": // Storm Screamer + case "rank_111": // Spectral Master + case "rank_112": // Shillien Saint + case "rank_113": // Titan + case "rank_114": // Grand Khavatari + case "rank_115": // Dominator + case "rank_116": // Doom Cryer + case "rank_117": // Fortune Seeker + case "rank_118": // Maestro { final int classId = Integer.parseInt(event.replace("rank_", "")); final List names = Olympiad.getInstance().getClassLeaderBoard(classId); @@ -311,7 +336,7 @@ public final class OlyManager extends AbstractNpcAI implements IBypassHandler if (!player.isCursedWeaponEquipped()) { - htmltext = player.isNoble() ? "OlyManager-noble.html" : "OlyManager-noNoble.html"; + htmltext = (!player.isInCategory(CategoryType.THIRD_CLASS_GROUP) && !player.isInCategory(CategoryType.FOURTH_CLASS_GROUP)) || (player.getLevel() < 55) ? "OlyManager-noNoble.html" : "OlyManager-noble.html"; } else {