Kartia rework.

Contributed by flanagan.
This commit is contained in:
MobiusDev
2017-12-27 23:54:11 +00:00
parent d2d2c5862e
commit 0a67610966
110 changed files with 6500 additions and 3295 deletions

View File

@@ -1043,38 +1043,98 @@
<point X="-79988" Y="237012" Z="-3304" delay="0" run="true" />
</route>
<!-- Kartia 85 -->
<route name="kartia_85_route_1" repeat="false" repeatStyle="none">
<route name="kartia_85_route_1_1" repeat="false" repeatStyle="none">
<point X="-110644" Y="22150" Z="-10818" delay="0" run="true" />
<point X="-110289" Y="22470" Z="-10818" delay="0" run="true" />
<point X="-109450" Y="22146" Z="-10818" delay="0" run="true" />
</route>
<route name="kartia_85_route_2" repeat="false" repeatStyle="none">
<point X="-110647" Y="21949" Z="-10818" delay="0" run="true" />
<point X="-110281" Y="21617" Z="-10813" delay="0" run="true" />
<point X="-109451" Y="21951" Z="-10817" delay="0" run="true" />
<route name="kartia_85_route_1_2" repeat="false" repeatStyle="none">
<point X="-110664" Y="22170" Z="-10818" delay="0" run="true" />
<point X="-110269" Y="22450" Z="-10818" delay="0" run="true" />
<point X="-109500" Y="22196" Z="-10818" delay="0" run="true" />
</route>
<route name="kartia_85_route_1_3" repeat="false" repeatStyle="none">
<point X="-110624" Y="22130" Z="-10818" delay="0" run="true" />
<point X="-110309" Y="22490" Z="-10818" delay="0" run="true" />
<point X="-109480" Y="22166" Z="-10818" delay="0" run="true" />
</route>
<route name="kartia_85_route_2_1" repeat="false" repeatStyle="none">
<point X="-110657" Y="21949" Z="-10818" delay="0" run="true" />
<point X="-110301" Y="21657" Z="-10818" delay="0" run="true" />
<point X="-109401" Y="21901" Z="-10818" delay="0" run="true" />
</route>
<route name="kartia_85_route_2_2" repeat="false" repeatStyle="none">
<point X="-110677" Y="21969" Z="-10818" delay="0" run="true" />
<point X="-110281" Y="21617" Z="-10818" delay="0" run="true" />
<point X="-109451" Y="21951" Z="-10818" delay="0" run="true" />
</route>
<route name="kartia_85_route_2_3" repeat="false" repeatStyle="none">
<point X="-110627" Y="21929" Z="-10818" delay="0" run="true" />
<point X="-110241" Y="21597" Z="-10818" delay="0" run="true" />
<point X="-109471" Y="21971" Z="-10818" delay="0" run="true" />
</route>
<!-- Kartia 90 -->
<route name="kartia_90_route_1" repeat="false" repeatStyle="none">
<route name="kartia_90_route_1_1" repeat="false" repeatStyle="none">
<point X="-119916" Y="-10341" Z="-11924" delay="0" run="true" />
<point X="-119534" Y="-10085" Z="-11924" delay="0" run="true" />
<point X="-118696" Y="-10346" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_90_route_2" repeat="false" repeatStyle="none">
<route name="kartia_90_route_1_2" repeat="false" repeatStyle="none">
<point X="-119936" Y="-10361" Z="-11924" delay="0" run="true" />
<point X="-119514" Y="-10065" Z="-11924" delay="0" run="true" />
<point X="-118746" Y="-10396" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_90_route_1_3" repeat="false" repeatStyle="none">
<point X="-119896" Y="-10321" Z="-11924" delay="0" run="true" />
<point X="-119554" Y="-10105" Z="-11924" delay="0" run="true" />
<point X="-118726" Y="-10376" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_90_route_2_1" repeat="false" repeatStyle="none">
<point X="-119917" Y="-10537" Z="-11924" delay="0" run="true" />
<point X="-119525" Y="-10861" Z="-11920" delay="0" run="true" />
<point X="-118701" Y="-10540" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_90_route_2_2" repeat="false" repeatStyle="none">
<point X="-119937" Y="-10567" Z="-11924" delay="0" run="true" />
<point X="-119505" Y="-10841" Z="-11920" delay="0" run="true" />
<point X="-118751" Y="-10590" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_90_route_2_3" repeat="false" repeatStyle="none">
<point X="-119887" Y="-10507" Z="-11924" delay="0" run="true" />
<point X="-119565" Y="-10901" Z="-11920" delay="0" run="true" />
<point X="-118771" Y="-10590" Z="-11924" delay="0" run="true" />
</route>
<!-- Kartia 95 -->
<route name="kartia_95_route_1" repeat="false" repeatStyle="none">
<route name="kartia_95_route_1_1" repeat="false" repeatStyle="none">
<point X="-110346" Y="-10345" Z="-11924" delay="0" run="true" />
<point X="-109964" Y="-10023" Z="-11926" delay="0" run="true" />
<point X="-109129" Y="-10345" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_95_route_2" repeat="false" repeatStyle="none">
<route name="kartia_95_route_1_2" repeat="false" repeatStyle="none">
<point X="-110326" Y="-10325" Z="-11924" delay="0" run="true" />
<point X="-109984" Y="-10043" Z="-11926" delay="0" run="true" />
<point X="-109169" Y="-10385" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_95_route_1_3" repeat="false" repeatStyle="none">
<point X="-110366" Y="-10365" Z="-11924" delay="0" run="true" />
<point X="-109944" Y="-10003" Z="-11926" delay="0" run="true" />
<point X="-109159" Y="-10375" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_95_route_2_1" repeat="false" repeatStyle="none">
<point X="-110345" Y="-10539" Z="-11926" delay="0" run="true" />
<point X="-109971" Y="-10896" Z="-11920" delay="0" run="true" />
<point X="-109131" Y="-10538" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_95_route_2_2" repeat="false" repeatStyle="none">
<point X="-110325" Y="-10519" Z="-11926" delay="0" run="true" />
<point X="-109991" Y="-10916" Z="-11920" delay="0" run="true" />
<point X="-109161" Y="-10568" Z="-11924" delay="0" run="true" />
</route>
<route name="kartia_95_route_2_3" repeat="false" repeatStyle="none">
<point X="-110365" Y="-10559" Z="-11926" delay="0" run="true" />
<point X="-109951" Y="-10876" Z="-11920" delay="0" run="true" />
<point X="-109161" Y="-10568" Z="-11924" delay="0" run="true" />
</route>
<!-- Garden of Genssis -->
<route name="genesis_GC_path1" repeat="true" repeatStyle="back">
<target id="22950" spawnX="209008" spawnY="110944" spawnZ="-2080" />

View File

@@ -12,8 +12,12 @@
<param name="firstDoorId" value="16180031" />
<param name="secondDoorId" value="16180032" />
<param name="thirdDoorId" value="16180033" />
<param name="route1" value="kartia_85_route_1" />
<param name="route2" value="kartia_85_route_2" />
<param name="route1_1" value="kartia_85_route_1_1" />
<param name="route2_1" value="kartia_85_route_2_1" />
<param name="route1_2" value="kartia_85_route_1_2" />
<param name="route2_2" value="kartia_85_route_2_2" />
<param name="route1_3" value="kartia_85_route_1_3" />
<param name="route2_3" value="kartia_85_route_2_3" />
<param name="helperSurvivor" value="33642" />
<location name="prisonerEscapeLoc" x="-109295" y="22038" z="-10815" />
<location name="middlePointRoom1" x="-111550" y="22036" z="-10580" />

View File

@@ -12,45 +12,48 @@
<param name="firstDoorId" value="16180031" />
<param name="secondDoorId" value="16180032" />
<param name="thirdDoorId" value="16180033" />
<param name="helperAdolph" value="33609" />
<param name="helperBarton" value="33611" />
<param name="helperHayuk" value="33613" />
<param name="helperEliyah" value="33615" />
<param name="helperElise" value="33617" />
<param name="helperSurvivor" value="33642" />
<param name="route1" value="kartia_85_route_1" />
<param name="route2" value="kartia_85_route_2" />
<param name="soloEXP" value="480000000" />
<param name="SoloEXP_Rand" value="8055934" />
<param name="SoloSP" value="3800000" />
<param name="SoloSP_Rand" value="73460" />
<skill name="adolphHate" id="15182" level="1" /> <!-- Adolph's Superior Aggression Aura -->
<param name="helperGuardian" value="33618" />
<param name="route1_1" value="kartia_85_route_1_1" />
<param name="route2_1" value="kartia_85_route_2_1" />
<param name="route1_2" value="kartia_85_route_1_2" />
<param name="route2_2" value="kartia_85_route_2_2" />
<param name="route1_3" value="kartia_85_route_1_3" />
<param name="route2_3" value="kartia_85_route_2_3" />
<skill name="adolphHate" id="14840" level="1" /> <!-- Adolph's Superior Aggression Aura -->
<skill name="adolphPunish" id="14846" level="1" /> <!-- Adolph's Justice Punishment -->
<skill name="adolphShield" id="15185" level="1" /> <!-- Adolph's Shield Wave -->
<skill name="adolphShield" id="14849" level="1" /> <!-- Adolph's Shield Wave -->
<skill name="adolphAggression" id="14889" level="1" /> <!-- Adolph's Aggression -->
<skill name="adolphChainHydra" id="14843" level="1" /> <!-- Adolph's Chain Hydra -->
<skill name="adolphUltimate" id="14852" level="1" /> <!-- Adolph's Final Ultimate Defense -->
<skill name="bartonInfinity" id="14858" level="1" /> <!-- Barton's Infinity Strike -->
<skill name="bartonBerserker" id="14867" level="1" /> <!-- Barton's Berserker Rage -->
<skill name="eliseChainHeal" id="15002" level="1" /> <!-- Progressive Heal - NPC -->
<skill name="eliseHeal" id="14899" level="1" /> <!-- Elise' Radiant Heal -->
<skill name="bartonHurricane" id="14855" level="1" /> <!-- Barton's Hurricane Rush -->
<skill name="bartonPowerBomber" id="14864" level="1" /> <!-- Barton's Power Bomber -->
<skill name="bartonSonicStar" id="14861" level="1" /> <!-- Barton's Sonic Star -->
<skill name="eliseProgressiveHeal" id="14898" level="1" /> <!-- Progressive Heal - NPC -->
<skill name="eliseRadiantHeal" id="14899" level="1" /> <!-- Elise' Radiant Heal -->
<skill name="eliseRecharge" id="14905" level="1" /> <!-- Elise' Radiant Recharge -->
<skill name="eliseCrystalRegene" id="14908" level="1" /> <!-- Elise' Crystal Regeneration -->
<skill name="hayukRecoilShot" id="14876" level="1" /> <!-- Hayuk's Recoil Shot -->
<skill name="hayukPinpointShot" id="14879" level="1" /> <!-- Hayuk's Pinpoint Shot -->
<skill name="hayukHeavyArrowRain" id="14873" level="1" /> <!-- Hayuk's Heavy Arrow Rain -->
<skill name="hayukMultipleArrow" id="14870" level="1" /> <!-- Hayuk's Multiple Arrow -->
<skill name="hayukQuickEvasion" id="14882" level="1" /> <!-- Hayuk's Multiple Arrow -->
<skill name="guardianSpiritsBlow" id="14892" level="1" /> <!-- Guardian Spirit's Blow -->
<skill name="guardianSpiritsWrath" id="14895" level="1" /> <!-- Guardian Spirit's Wrath -->
<location name="playerLoc" x="-109294" y="22037" z="-10816" heading="32488" />
<location name="prisonerEscapeLoc" x="-109295" y="22038" z="-10815" />
<location name="middlePointRoom1" x="-111550" y="22036" z="-10580" />
<location name="middlePointRoom3" x="-111616" y="17999" z="-10319" />
<location name="bossEscapeLoc1" x="-111610" y="19295" z="-10456" />
<location name="bossEscapeLoc2" x="-111609" y="18604" z="-10336" />
<location name="teleportZone1_loc" x="-110574" y="22050" z="-10812" />
<location name="teleportZone2_loc" x="-111614" y="20565" z="-10462" />
<location name="teleportZone3_loc" x="-111618" y="18345" z="-10319" />
<location name="adolphTeleportStatus2" x="-111608" y="20444" z="-10456" />
<location name="bartonTeleportStatus2" x="-111608" y="20500" z="-10456" />
<location name="hayukTeleportStatus2" x="-111700" y="20500" z="-10450" />
<location name="eliyahTeleportStatus2" x="-1118000" y="20500" z="-10456" />
<location name="eliseTeleportStatus2" x="-111500" y="20500" z="-10456" />
<location name="adolphTeleportStatus3" x="-111620" y="18260" z="-10312" />
<location name="bartonTeleportStatus3" x="-111620" y="18150" z="-10312" />
<location name="hayukTeleportStatus3" x="-111520" y="18150" z="-10312" />
<location name="eliyahTeleportStatus3" x="-1114200" y="18150" z="-10312" />
<location name="eliseTeleportStatus3" x="-111720" y="18150" z="-10312" />
</parameters>
<conditions>
<condition type="Level" showMessageAndHtml="true">
@@ -95,6 +98,11 @@
<npc id="33615" x="-109296" y="21832" z="-10816" heading="-32704" /> <!-- Eliyah -->
<npc id="33617" x="-109302" y="22241" z="-10816" heading="32552" /> <!-- Elise -->
</group>
<group name="GUARDIANS" spawnByDefault="false">
<npc id="33618" x="-109346" y="21882" z="-10816" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
<npc id="33618" x="-109246" y="21782" z="-10816" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
<npc id="33618" x="-109266" y="21852" z="-10816" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
</group>
<group name="PRISONERS" spawnByDefault="false">
<npc id="33641" x="-110213" y="22011" z="-10576" heading="0" /> <!-- Kartia Prisoner -->
<npc id="33641" x="-110340" y="22132" z="-10576" heading="0" /> <!-- Kartia Prisoner -->
@@ -115,7 +123,6 @@
<npc id="19220" x="-111642" y="21462" z="-10576" heading="33120" /> <!-- Kartia Guard -->
<npc id="19220" x="-111642" y="21462" z="-10576" heading="33120" /> <!-- Kartia Guard -->
<npc id="19220" x="-111642" y="21462" z="-10576" heading="33120" /> <!-- Kartia Guard -->
<npc id="19220" x="-111642" y="21462" z="-10576" heading="33120" /> <!-- Kartia Guard -->
</group>
<group name="ROOM1_STAGE1_WAVE2" spawnByDefault="false">
<npc id="19220" x="-111642" y="21462" z="-10576" heading="33120" /> <!-- Kartia Guard -->

View File

@@ -12,8 +12,12 @@
<param name="firstDoorId" value="16170011" />
<param name="secondDoorId" value="16170012" />
<param name="thirdDoorId" value="16170013" />
<param name="route1" value="kartia_90_route_1" />
<param name="route2" value="kartia_90_route_2" />
<param name="route1_1" value="kartia_90_route_1_1" />
<param name="route2_1" value="kartia_90_route_2_1" />
<param name="route1_2" value="kartia_90_route_1_2" />
<param name="route2_2" value="kartia_90_route_2_2" />
<param name="route1_3" value="kartia_90_route_1_3" />
<param name="route2_3" value="kartia_90_route_2_3" />
<param name="helperSurvivor" value="33644" />
<location name="prisonerEscapeLoc" x="-118505" y="-10461" z="-11924" />
<location name="middlePointRoom1" x="-120848" y="-10452" z="-11685" />

View File

@@ -16,22 +16,37 @@
<param name="helperHayuk" value="33624" />
<param name="helperEliyah" value="33626" />
<param name="helperElise" value="33628" />
<param name="helperSurvivor" value="33644" />
<param name="route1" value="kartia_90_route_1" />
<param name="route2" value="kartia_90_route_2" />
<param name="soloEXP" value="670000000" />
<param name="SoloEXP_Rand" value="6173918" />
<param name="SoloSP" value="5600000" />
<param name="SoloSP_Rand" value="82134" />
<skill name="adolphHate" id="15183" level="1" /> <!-- Adolph's Superior Aggression Aura -->
<skill name="adolphPunish" id="14847" level="1" /> <!-- Adolph's Justice Punishment -->
<skill name="adolphShield" id="15186" level="1" /> <!-- Adolph's Shield Wave -->
<skill name="adolphUltimate" id="14853" level="1" /> <!-- Adolph's Final Ultimate Defense -->
<skill name="bartonInfinity" id="14859" level="1" /> <!-- Barton's Infinity Strike -->
<skill name="bartonBerserker" id="14868" level="1" /> <!-- Barton's Berserker Rage -->
<skill name="eliseChainHeal" id="15002" level="1" /> <!-- Progressive Heal - NPC -->
<skill name="eliseHeal" id="14900" level="1" /> <!-- Elise' Radiant Heal -->
<skill name="eliseRecharge" id="14906" level="1" /> <!-- Elise' Radiant Recharge -->
<param name="helperSurvivor" value="33644" />
<param name="helperAdolph" value="33620" />
<param name="helperGuardian" value="33629" />
<param name="route1_1" value="kartia_90_route_1_1" />
<param name="route2_1" value="kartia_90_route_2_1" />
<param name="route1_2" value="kartia_90_route_1_2" />
<param name="route2_2" value="kartia_90_route_2_2" />
<param name="route1_3" value="kartia_90_route_1_3" />
<param name="route2_3" value="kartia_90_route_2_3" />
<skill name="adolphHate" id="14840" level="1" /> <!-- Adolph's Superior Aggression Aura -->
<skill name="adolphPunish" id="14846" level="1" /> <!-- Adolph's Justice Punishment -->
<skill name="adolphShield" id="14849" level="1" /> <!-- Adolph's Shield Wave -->
<skill name="adolphAggression" id="14889" level="1" /> <!-- Adolph's Aggression -->
<skill name="adolphChainHydra" id="14843" level="1" /> <!-- Adolph's Chain Hydra -->
<skill name="adolphUltimate" id="14852" level="1" /> <!-- Adolph's Final Ultimate Defense -->
<skill name="bartonInfinity" id="14858" level="1" /> <!-- Barton's Infinity Strike -->
<skill name="bartonBerserker" id="14867" level="1" /> <!-- Barton's Berserker Rage -->
<skill name="bartonHurricane" id="14855" level="1" /> <!-- Barton's Hurricane Rush -->
<skill name="bartonPowerBomber" id="14864" level="1" /> <!-- Barton's Power Bomber -->
<skill name="bartonSonicStar" id="14861" level="1" /> <!-- Barton's Sonic Star -->
<skill name="eliseProgressiveHeal" id="14898" level="1" /> <!-- Progressive Heal - NPC -->
<skill name="eliseRadiantHeal" id="14899" level="1" /> <!-- Elise' Radiant Heal -->
<skill name="eliseRecharge" id="14905" level="1" /> <!-- Elise' Radiant Recharge -->
<skill name="eliseCrystalRegene" id="14908" level="1" /> <!-- Elise' Crystal Regeneration -->
<skill name="hayukRecoilShot" id="14876" level="1" /> <!-- Hayuk's Recoil Shot -->
<skill name="hayukPinpointShot" id="14879" level="1" /> <!-- Hayuk's Pinpoint Shot -->
<skill name="hayukHeavyArrowRain" id="14873" level="1" /> <!-- Hayuk's Heavy Arrow Rain -->
<skill name="hayukMultipleArrow" id="14870" level="1" /> <!-- Hayuk's Multiple Arrow -->
<skill name="hayukQuickEvasion" id="14882" level="1" /> <!-- Hayuk's Multiple Arrow -->
<skill name="guardianSpiritsBlow" id="14892" level="1" /> <!-- Guardian Spirit's Blow -->
<skill name="guardianSpiritsWrath" id="14895" level="1" /> <!-- Guardian Spirit's Wrath -->
<location name="playerLoc" x="-118532" y="-10456" z="-11920" heading="32460" />
<location name="prisonerEscapeLoc" x="-118505" y="-10461" z="-11924" />
<location name="middlePointRoom1" x="-120848" y="-10452" z="-11685" />
@@ -41,16 +56,6 @@
<location name="teleportZone1_loc" x="-119852" y="-10445" z="-11924" />
<location name="teleportZone2_loc" x="-120855" y="-11984" z="-11573" />
<location name="teleportZone3_loc" x="-120861" y="-14149" z="-11427" />
<location name="adolphTeleportStatus2" x="-120850" y="-12050" z="-11568" />
<location name="bartonTeleportStatus2" x="-120850" y="-11950" z="-11568" />
<location name="hayukTeleportStatus2" x="-120950" y="-11950" z="-11568" />
<location name="eliyahTeleportStatus2" x="-121050" y="-11950" z="-11568" />
<location name="eliseTeleportStatus2" x="-120750" y="-11950" z="-11568" />
<location name="adolphTeleportStatus3" x="-120865" y="-14230" z="-11424" />
<location name="bartonTeleportStatus3" x="-120865" y="-14145" z="-11424" />
<location name="hayukTeleportStatus3" x="-120965" y="-14145" z="-11424" />
<location name="eliyahTeleportStatus3" x="-121065" y="-14145" z="-11424" />
<location name="eliseTeleportStatus3" x="-120765" y="-14145" z="-11424" />
</parameters>
<conditions>
<condition type="Level" showMessageAndHtml="true">
@@ -95,6 +100,11 @@
<npc id="33626" x="-118546" y="-10750" z="-11920" heading="-32356" /> <!-- Eliyah -->
<npc id="33628" x="-118535" y="-10243" z="-11920" heading="32720" /> <!-- Elise -->
</group>
<group name="GUARDIANS" spawnByDefault="false">
<npc id="33629" x="-118596" y="-10800" z="-11920" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
<npc id="33629" x="-118496" y="-10700" z="-11920" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
<npc id="33629" x="-118576" y="-10780" z="-11920" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
</group>
<group name="PRISONERS" spawnByDefault="false">
<npc id="33643" x="-119439" y="-10479" z="-11688" heading="0" /> <!-- Kartia Prisoner -->
<npc id="33643" x="-119607" y="-10370" z="-11680" heading="0" /> <!-- Kartia Prisoner -->

View File

@@ -12,8 +12,12 @@
<param name="firstDoorId" value="16170001" />
<param name="secondDoorId" value="16170002" />
<param name="thirdDoorId" value="16170003" />
<param name="route1" value="kartia_95_route_1" />
<param name="route2" value="kartia_95_route_2" />
<param name="route1_1" value="kartia_95_route_1_1" />
<param name="route2_1" value="kartia_95_route_2_1" />
<param name="route1_2" value="kartia_95_route_1_2" />
<param name="route2_2" value="kartia_95_route_2_2" />
<param name="route1_3" value="kartia_95_route_1_3" />
<param name="route2_3" value="kartia_95_route_2_3" />
<param name="helperSurvivor" value="33646" />
<location name="prisonerEscapeLoc" x="-108939" y="-10455" z="-11924" />
<location name="middlePointRoom1" x="-111274" y="-10455" z="-11685" />

View File

@@ -17,21 +17,36 @@
<param name="helperEliyah" value="33637" />
<param name="helperElise" value="33639" />
<param name="helperSurvivor" value="33646" />
<param name="route1" value="kartia_95_route_1" />
<param name="route2" value="kartia_95_route_2" />
<param name="soloEXP" value="970000000" />
<param name="SoloEXP_Rand" value="6305195" />
<param name="SoloSP" value="8500000" />
<param name="SoloSP_Rand" value="39112" />
<skill name="adolphHate" id="15184" level="1" /> <!-- Adolph's Superior Aggression Aura -->
<skill name="adolphPunish" id="14848" level="1" /> <!-- Adolph's Justice Punishment -->
<skill name="adolphShield" id="15187" level="1" /> <!-- Adolph's Shield Wave -->
<skill name="adolphUltimate" id="14854" level="1" /> <!-- Adolph's Final Ultimate Defense -->
<skill name="bartonInfinity" id="14860" level="1" /> <!-- Barton's Infinity Strike -->
<skill name="bartonBerserker" id="14869" level="1" /> <!-- Barton's Berserker Rage -->
<skill name="eliseChainHeal" id="15002" level="1" /> <!-- Progressive Heal - NPC -->
<skill name="eliseHeal" id="14901" level="1" /> <!-- Elise' Radiant Heal -->
<skill name="eliseRecharge" id="14907" level="1" /> <!-- Elise' Radiant Recharge -->
<param name="helperAdolph" value="33631" />
<param name="helperGuardian" value="33640" />
<param name="route1_1" value="kartia_95_route_1_1" />
<param name="route2_1" value="kartia_95_route_2_1" />
<param name="route1_2" value="kartia_95_route_1_2" />
<param name="route2_2" value="kartia_95_route_2_2" />
<param name="route1_3" value="kartia_95_route_1_3" />
<param name="route2_3" value="kartia_95_route_2_3" />
<skill name="adolphHate" id="14840" level="1" /> <!-- Adolph's Superior Aggression Aura -->
<skill name="adolphPunish" id="14846" level="1" /> <!-- Adolph's Justice Punishment -->
<skill name="adolphShield" id="14849" level="1" /> <!-- Adolph's Shield Wave -->
<skill name="adolphAggression" id="14889" level="1" /> <!-- Adolph's Aggression -->
<skill name="adolphChainHydra" id="14843" level="1" /> <!-- Adolph's Chain Hydra -->
<skill name="adolphUltimate" id="14852" level="1" /> <!-- Adolph's Final Ultimate Defense -->
<skill name="bartonInfinity" id="14858" level="1" /> <!-- Barton's Infinity Strike -->
<skill name="bartonBerserker" id="14867" level="1" /> <!-- Barton's Berserker Rage -->
<skill name="bartonHurricane" id="14855" level="1" /> <!-- Barton's Hurricane Rush -->
<skill name="bartonPowerBomber" id="14864" level="1" /> <!-- Barton's Power Bomber -->
<skill name="bartonSonicStar" id="14861" level="1" /> <!-- Barton's Sonic Star -->
<skill name="eliseProgressiveHeal" id="14898" level="1" /> <!-- Progressive Heal - NPC -->
<skill name="eliseRadiantHeal" id="14899" level="1" /> <!-- Elise' Radiant Heal -->
<skill name="eliseRecharge" id="14905" level="1" /> <!-- Elise' Radiant Recharge -->
<skill name="eliseCrystalRegene" id="14908" level="1" /> <!-- Elise' Crystal Regeneration -->
<skill name="hayukRecoilShot" id="14876" level="1" /> <!-- Hayuk's Recoil Shot -->
<skill name="hayukPinpointShot" id="14879" level="1" /> <!-- Hayuk's Pinpoint Shot -->
<skill name="hayukHeavyArrowRain" id="14873" level="1" /> <!-- Hayuk's Heavy Arrow Rain -->
<skill name="hayukMultipleArrow" id="14870" level="1" /> <!-- Hayuk's Multiple Arrow -->
<skill name="hayukQuickEvasion" id="14882" level="1" /> <!-- Hayuk's Multiple Arrow -->
<skill name="guardianSpiritsBlow" id="14892" level="1" /> <!-- Guardian Spirit's Blow -->
<skill name="guardianSpiritsWrath" id="14895" level="1" /> <!-- Guardian Spirit's Wrath -->
<location name="playerLoc" x="-108951" y="-10443" z="-11920" heading="32128" />
<location name="prisonerEscapeLoc" x="-108939" y="-10455" z="-11924" />
<location name="middlePointRoom1" x="-111274" y="-10455" z="-11685" />
@@ -41,16 +56,6 @@
<location name="teleportZone1_loc" x="-110285" y="-10447" z="-11924" />
<location name="teleportZone2_loc" x="-111297" y="-11923" z="-11571" />
<location name="teleportZone3_loc" x="-111297" y="-14147" z="-11429" />
<location name="adolphTeleportStatus2" x="-111285" y="-12050" z="-11658" />
<location name="bartonTeleportStatus2" x="-111285" y="-11950" z="-11568" />
<location name="hayukTeleportStatus2" x="-111385" y="-11950" z="-11568" />
<location name="eliyahTeleportStatus2" x="-111485" y="-11950" z="-10456" />
<location name="eliseTeleportStatus2" x="-111185" y="-11950" z="-11568" />
<location name="adolphTeleportStatus3" x="-111290" y="-14318" z="11424" />
<location name="bartonTeleportStatus3" x="-111290" y="-14218" z="-11424" />
<location name="hayukTeleportStatus3" x="-111390" y="-14218" z="-11424" />
<location name="eliyahTeleportStatus3" x="-111490" y="-14218" z="-11424" />
<location name="eliseTeleportStatus3" x="-111190" y="14218" z="-11424" />
</parameters>
<conditions>
<condition type="Level" showMessageAndHtml="true">
@@ -94,6 +99,11 @@
<npc id="33637" x="-109018" y="-10728" z="-11920" heading="32074" /> <!-- Eliyah -->
<npc id="33639" x="-108953" y="-10242" z="-11920" heading="-32464" /> <!-- Elise -->
</group>
<group name="GUARDIANS" spawnByDefault="false">
<npc id="33640" x="-109068" y="-10778" z="-11920" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
<npc id="33640" x="-108968" y="-10678" z="-11920" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
<npc id="33640" x="-109048" y="-10758" z="-11920" heading="-32704" /> <!-- Eliyah's Guardian Spirit -->
</group>
<group name="PRISONERS" spawnByDefault="false">
<npc id="33645" x="-109986" y="-10367" z="-11680" heading="0" /> <!-- Kartia Prisoner -->
<npc id="33645" x="-109988" y="-10543" z="-11680" heading="0" /> <!-- Kartia Prisoner -->

View File

@@ -0,0 +1,5 @@
<html><body>Kartia Researcher:<br>
Don't waste my time! I'm a researcher sent directly by the Kingdom of Aden after all.<br>
You must have the quest started in order to enter the labyrinth.<br>
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
</body></html>

View File

@@ -28,7 +28,7 @@ import ai.AbstractNpcAI;
/**
* Kartia Boss AI.
* @author St3eT
* @author flanagak
*/
public final class KartiaBoss extends AbstractNpcAI
{
@@ -139,8 +139,8 @@ public final class KartiaBoss extends AbstractNpcAI
{
for (int i = 0; i < 3; i++)
{
addSpawn(fighter, npc, false, 0, false, npc.getInstanceId());
addSpawn(mage, npc, false, 0, false, npc.getInstanceId());
addSpawn(fighter, npc, true, 0, false, npc.getInstanceId());
addSpawn(mage, npc, true, 0, false, npc.getInstanceId());
}
}
}

View File

@@ -33,16 +33,14 @@ import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureDeath;
import com.l2jmobius.gameserver.model.events.impl.instance.OnInstanceStatusChange;
import com.l2jmobius.gameserver.model.holders.SkillHolder;
import com.l2jmobius.gameserver.model.instancezone.Instance;
import com.l2jmobius.gameserver.model.skills.Skill;
import com.l2jmobius.gameserver.model.skills.SkillCaster;
import com.l2jmobius.gameserver.network.NpcStringId;
import com.l2jmobius.gameserver.util.Util;
import ai.AbstractNpcAI;
/**
* Kartia Helper Adolph AI.
* @author St3eT
* @author flanagak
*/
public final class KartiaHelperAdolph extends AbstractNpcAI
{
@@ -59,6 +57,27 @@ public final class KartiaHelperAdolph extends AbstractNpcAI
33799, // Life Plunderer (90)
33800, // Life Plunderer (95)
};
private static final int[] KARTIA_FRIENDS =
{
33617, // Elise (Kartia 85)
33628, // Elise (Kartia 90)
33639, // Elise (Kartia 95)
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
33611, // Barton (Kartia 85)
33622, // Barton (Kartia 90)
33633, // Barton (Kartia 95)
33615, // Eliyah (Kartia 85)
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
33613, // Hayuk (Kartia 85)
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
33618, // Eliyah's Guardian Spirit (Kartia 85)
33629, // Eliyah's Guardian Spirit (Kartia 90)
33640, // Eliyah's Guardian Spirit (Kartia 95)
};
// Misc
private static final int[] KARTIA_SOLO_INSTANCES =
{
@@ -82,114 +101,161 @@ public final class KartiaHelperAdolph extends AbstractNpcAI
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && event.equals("CHECK_ACTION"))
{
final StatsSet instParams = instance.getTemplateParameters();
boolean actionFound = false;
if (!npc.isInCombat() || !npc.isAttackingNow() || (npc.getTarget() == null))
final StatsSet npcVars = npc.getVariables();
player = npcVars.getObject("PLAYER_OBJECT", L2PcInstance.class);
if (player != null)
{
final List<L2MonsterInstance> monsterList = L2World.getInstance().getVisibleObjects(npc, L2MonsterInstance.class, 500);
if (!monsterList.isEmpty())
final double distance = npc.calculateDistance(player, false, false);
if (distance > 300)
{
final L2MonsterInstance monster = monsterList.get(getRandom(monsterList.size()));
if (monster.isTargetable() && GeoEngine.getInstance().canSeeTarget(npc, monster) && !CommonUtil.contains(MIRRORS, monster.getId()))
final Location loc = new Location(player.getX(), player.getY(), player.getZ() + 50);
final Location randLoc = new Location(loc.getX() + getRandom(-100, 100), loc.getY() + getRandom(-100, 100), loc.getZ());
if (distance > 600)
{
actionFound = true;
addAttackDesire(npc, monster);
npc.teleToLocation(loc);
}
}
}
if (!actionFound)
{
final SkillHolder hateSkill = instParams.getSkillHolder("adolphHate");
if (npc.isInCombat() && (hateSkill != null) && SkillCaster.checkUseConditions(npc, hateSkill.getSkill()))
{
addSkillCastDesire(npc, npc.getTarget(), hateSkill, 23);
}
else
{
final L2PcInstance instancePlayer = npc.getVariables().getObject("PLAYER_OBJECT", L2PcInstance.class);
if (instancePlayer != null)
else
{
final double radian = Math.toRadians(Util.convertHeadingToDegree(instancePlayer.getHeading()));
final int X = (int) (instancePlayer.getX() + (Math.cos(radian) * 150));
final int Y = (int) (instancePlayer.getY() + (Math.sin(radian) * 150));
final Location loc = GeoEngine.getInstance().canMoveToTargetLoc(instancePlayer.getX(), instancePlayer.getY(), instancePlayer.getZ(), X, Y, instancePlayer.getZ(), instance);
npc.setRunning();
}
addMoveToDesire(npc, randLoc, 23);
}
else if (!npc.isInCombat() || (npc.getTarget() == null))
{
final List<L2MonsterInstance> monsterList = L2World.getInstance().getVisibleObjects(npc, L2MonsterInstance.class, 500);
if (!monsterList.isEmpty())
{
final L2MonsterInstance monster = monsterList.get(getRandom(monsterList.size()));
if (!npc.isInsideRadius(loc, 50, true, true))
if (monster.isTargetable() && GeoEngine.getInstance().canSeeTarget(npc, monster) && !CommonUtil.contains(MIRRORS, monster.getId()) && !CommonUtil.contains(KARTIA_FRIENDS, monster.getId()))
{
npc.setRunning();
addMoveToDesire(npc, loc, 23);
addAttackDesire(npc, monster);
}
}
}
}
}
}
@Override
public String onSpellFinished(L2Npc npc, L2PcInstance player, Skill skill)
{
final Instance instance = npc.getInstanceWorld();
if (instance != null)
else if ((instance != null) && event.equals("USE_SKILL"))
{
final StatsSet instParams = instance.getTemplateParameters();
final SkillHolder hateSkill = instParams.getSkillHolder("adolphHate");
final SkillHolder shieldSkill = instParams.getSkillHolder("adolphShield");
final SkillHolder punishSkill = instParams.getSkillHolder("adolphPunish");
if ((hateSkill != null) && (skill.getId() == hateSkill.getSkillId()))
if (npc.isInCombat() || npc.isAttackingNow() || (npc.getTarget() != null))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.YOU_FILTHY_MONSTERS_I_WILL_TAKE_YOU_ON);
}
else if ((shieldSkill != null) && (skill.getId() == shieldSkill.getSkillId()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.STOP_RIGHT_THERE_I_WILL_BE_YOUR_OPPONENT);
}
else if ((punishSkill != null) && (skill.getId() == punishSkill.getSkillId()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.I_WILL_SHOW_YOU_THE_JUSTICE_OF_ADEN);
if ((npc.getCurrentMpPercent() > 25) && !CommonUtil.contains(KARTIA_FRIENDS, npc.getTargetId()))
{
useRandomSkill(npc);
}
}
}
}
public void useRandomSkill(L2Npc npc)
{
final Instance instance = npc.getInstanceWorld();
final L2Npc target = (L2Npc) npc.getTarget();
if ((instance != null) && !npc.isCastingNow() && (target != null) && (!CommonUtil.contains(KARTIA_FRIENDS, target.getId())))
{
final StatsSet instParams = instance.getTemplateParameters();
final SkillHolder skill_01 = instParams.getSkillHolder("adolphHate");
final SkillHolder skill_02 = instParams.getSkillHolder("adolphPunish");
final SkillHolder skill_03 = instParams.getSkillHolder("adolphShield");
final SkillHolder skill_04 = instParams.getSkillHolder("adolphAggression");
final SkillHolder skill_05 = instParams.getSkillHolder("adolphChainHydra");
final SkillHolder lowHpSkill = instParams.getSkillHolder("adolphUltimate");
final int numberOfActiveSkills = 5;
final int randomSkill = getRandom(numberOfActiveSkills + 1);
if ((lowHpSkill != null) && (npc.getCurrentHpPercent() < 50))
{
// NPC has low HP Skill and HP is < 50% HP
if (!npc.isAffectedBySkill(lowHpSkill.getSkillId()) && (SkillCaster.checkUseConditions(npc, lowHpSkill.getSkill())))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.IT_S_NOT_OVER);
npc.doCast(lowHpSkill.getSkill());
}
}
else
{
switch (randomSkill)
{
case 0:
case 1:
{
if ((skill_01 != null) && SkillCaster.checkUseConditions(npc, skill_01.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.I_WILL_SHOW_YOU_THE_JUSTICE_OF_ADEN);
npc.doCast(skill_01.getSkill(), null, true, false);
final List<L2MonsterInstance> monsterList = L2World.getInstance().getVisibleObjects(npc, L2MonsterInstance.class, 300);
if (!monsterList.isEmpty())
{
for (L2MonsterInstance monster : monsterList)
{
if (monster.isTargetable() && GeoEngine.getInstance().canSeeTarget(npc, monster) && !CommonUtil.contains(MIRRORS, monster.getId()) && !CommonUtil.contains(KARTIA_FRIENDS, monster.getId()))
{
monster.addDamageHate(npc, 100, 10000);
}
}
}
}
break;
}
case 2:
{
if ((skill_02 != null) && SkillCaster.checkUseConditions(npc, skill_02.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.DIE3);
npc.doCast(skill_02.getSkill(), null, true, false);
}
break;
}
case 3:
{
if ((skill_03 != null) && SkillCaster.checkUseConditions(npc, skill_03.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.FOR_THE_GODDESS);
npc.doCast(skill_03.getSkill(), null, true, false);
}
break;
}
case 4:
{
if ((skill_04 != null) && SkillCaster.checkUseConditions(npc, skill_04.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.YOU_WILL_BE_DESTROYED);
npc.doCast(skill_04.getSkill());
}
break;
}
case 5:
{
if ((skill_05 != null) && SkillCaster.checkUseConditions(npc, skill_05.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.YOU_WILL_DIE);
npc.doCast(skill_05.getSkill(), null, true, false);
}
break;
}
}
}
}
return super.onSpellFinished(npc, player, skill);
}
public void onCreatureAttacked(OnCreatureAttacked event)
{
final L2Npc npc = (L2Npc) event.getTarget();
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && !event.getAttacker().isPlayable())
if (npc != null)
{
final StatsSet instParams = instance.getTemplateParameters();
final int random = getRandom(1000);
if (random < 333)
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && !event.getAttacker().isPlayable() && !CommonUtil.contains(KARTIA_FRIENDS, event.getAttacker().getId()))
{
final SkillHolder shieldSkill = instParams.getSkillHolder("adolphShield");
if ((shieldSkill != null) && SkillCaster.checkUseConditions(npc, shieldSkill.getSkill()))
if (!npc.isInCombat())
{
addSkillCastDesire(npc, npc.getTarget(), shieldSkill, 23);
}
}
else if (random < 666)
{
final SkillHolder punishSkill = instParams.getSkillHolder("adolphPunish");
if ((punishSkill != null) && SkillCaster.checkUseConditions(npc, punishSkill.getSkill()))
{
addSkillCastDesire(npc, npc.getTarget(), punishSkill, 23);
}
}
if ((npc.getCurrentHpPercent() < 30) && npc.isScriptValue(0))
{
final SkillHolder ultimateSkill = instParams.getSkillHolder("adolphUltimate");
if ((ultimateSkill != null) && !npc.isAffectedBySkill(ultimateSkill.getSkillId()) && SkillCaster.checkUseConditions(npc, ultimateSkill.getSkill()))
{
npc.setScriptValue(1);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.IT_S_NOT_OVER);
addSkillCastDesire(npc, npc.getTarget(), ultimateSkill, 23);
getTimers().addTimer("RESTORE_SCRIPTVAL", 10000, n -> npc.setScriptValue(0));
npc.setTarget(event.getAttacker());
addAttackDesire(npc, (L2Character) npc.getTarget());
final StatsSet instParams = instance.getTemplateParameters();
final SkillHolder hateSkill = instParams.getSkillHolder("adolphHate");
if ((hateSkill != null) && SkillCaster.checkUseConditions(npc, hateSkill.getSkill()))
{
npc.doCast(hateSkill.getSkill(), null, true, false);
}
}
}
}
@@ -210,23 +276,10 @@ public final class KartiaHelperAdolph extends AbstractNpcAI
{
final Instance instance = event.getWorld();
final int status = event.getStatus();
switch (status)
if (status == 1)
{
case 1:
{
instance.getAliveNpcs(KARTIA_ADOLPH).forEach(adolph -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, adolph, null));
break;
}
case 2:
case 3:
{
final Location loc = instance.getTemplateParameters().getLocation("adolphTeleportStatus" + status);
if (loc != null)
{
instance.getAliveNpcs(KARTIA_ADOLPH).forEach(adolph -> adolph.teleToLocation(loc));
}
break;
}
instance.getAliveNpcs(KARTIA_ADOLPH).forEach(adolph -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, adolph, null));
instance.getAliveNpcs(KARTIA_ADOLPH).forEach(adolph -> getTimers().addRepeatingTimer("USE_SKILL", 6000, adolph, null));
}
}

View File

@@ -35,8 +35,8 @@ import com.l2jmobius.gameserver.network.NpcStringId;
import ai.AbstractNpcAI;
/**
* Kartia Helper Barton AI.
* @author St3eT
* Kartia Helper Barton AI. Tyrr Warrior
* @author flanagak
*/
public final class KartiaHelperBarton extends AbstractNpcAI
{
@@ -53,6 +53,27 @@ public final class KartiaHelperBarton extends AbstractNpcAI
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
};
private static final int[] KARTIA_FRIENDS =
{
33617, // Elise (Kartia 85)
33628, // Elise (Kartia 90)
33639, // Elise (Kartia 95)
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
33611, // Barton (Kartia 85)
33622, // Barton (Kartia 90)
33633, // Barton (Kartia 95)
33615, // Eliyah (Kartia 85)
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
33613, // Hayuk (Kartia 85)
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
33618, // Eliyah's Guardian Spirit (Kartia 85)
33629, // Eliyah's Guardian Spirit (Kartia 90)
33640, // Eliyah's Guardian Spirit (Kartia 95)
};
// Misc
private static final int[] KARTIA_SOLO_INSTANCES =
{
@@ -79,52 +100,50 @@ public final class KartiaHelperBarton extends AbstractNpcAI
if (adolph != null)
{
final double distance = npc.calculateDistance(adolph, false, false);
if (distance > 200)
if (distance > 300)
{
final Location loc = new Location(adolph.getX() + getRandom(-100, 100), adolph.getY() + getRandom(-100, 100), adolph.getZ() + 50);
if (distance > 500)
final Location loc = new Location(adolph.getX(), adolph.getY(), adolph.getZ() + 50);
final Location randLoc = new Location(loc.getX() + getRandom(-100, 100), loc.getY() + getRandom(-100, 100), loc.getZ());
if (distance > 600)
{
npc.teleToLocation(loc);
}
else
{
npc.setRunning();
addMoveToDesire(npc, loc, 23);
}
addMoveToDesire(npc, randLoc, 23);
}
else if (!npc.isInCombat() || !npc.isAttackingNow() || (npc.getTarget() == null))
else if (!npc.isInCombat() || (npc.getTarget() == null))
{
final L2Character monster = (L2Character) adolph.getTarget();
if ((monster != null) && adolph.isInCombat())
if ((monster != null) && adolph.isInCombat() && !CommonUtil.contains(KARTIA_FRIENDS, monster.getId()))
{
addAttackDesire(npc, monster);
}
}
}
}
else if ((instance != null) && event.equals("USE_SKILL"))
{
if (npc.isInCombat() || npc.isAttackingNow() || (npc.getTarget() != null))
{
if ((npc.getCurrentMpPercent() > 25) && !CommonUtil.contains(KARTIA_FRIENDS, npc.getTargetId()))
{
useRandomSkill(npc);
}
}
}
}
public void onInstanceStatusChange(OnInstanceStatusChange event)
{
final Instance instance = event.getWorld();
final int status = event.getStatus();
switch (status)
if (status == 1)
{
case 1:
{
instance.getAliveNpcs(KARTIA_BARTON).forEach(barton -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, barton, null));
break;
}
case 2:
case 3:
{
final Location loc = instance.getTemplateParameters().getLocation("bartonTeleportStatus" + status);
if (loc != null)
{
instance.getAliveNpcs(KARTIA_BARTON).forEach(barton -> barton.teleToLocation(loc));
}
break;
}
instance.getAliveNpcs(KARTIA_BARTON).forEach(barton -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, barton, null));
instance.getAliveNpcs(KARTIA_BARTON).forEach(barton -> getTimers().addRepeatingTimer("USE_SKILL", 6000, barton, null));
}
}
@@ -142,33 +161,83 @@ public final class KartiaHelperBarton extends AbstractNpcAI
return super.onSeeCreature(npc, creature, isSummon);
}
public void useRandomSkill(L2Npc npc)
{
final Instance instance = npc.getInstanceWorld();
final L2Npc target = (L2Npc) npc.getTarget();
if ((instance != null) && !npc.isCastingNow() && (target != null) && (!CommonUtil.contains(KARTIA_FRIENDS, target.getId())))
{
final StatsSet instParams = instance.getTemplateParameters();
final SkillHolder skill_01 = instParams.getSkillHolder("bartonInfinity");
final SkillHolder skill_02 = instParams.getSkillHolder("bartonBerserker");
final SkillHolder skill_03 = instParams.getSkillHolder("bartonHurricane");
final SkillHolder skill_04 = instParams.getSkillHolder("bartonPowerBomber");
final SkillHolder skill_05 = instParams.getSkillHolder("bartonSonicStar");
final int numberOfActiveSkills = 5;
final int randomSkill = getRandom(numberOfActiveSkills + 1);
switch (randomSkill)
{
case 0:
case 1:
{
if ((skill_01 != null) && SkillCaster.checkUseConditions(npc, skill_01.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.I_WILL_SHOW_YOU_THE_JUSTICE_OF_ADEN);
npc.doCast(skill_01.getSkill(), null, true, false);
}
break;
}
case 2:
{
if ((skill_02 != null) && SkillCaster.checkUseConditions(npc, skill_02.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.DIE3);
npc.doCast(skill_02.getSkill(), null, true, false);
}
break;
}
case 3:
{
if ((skill_03 != null) && SkillCaster.checkUseConditions(npc, skill_03.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.FOR_THE_GODDESS);
npc.doCast(skill_03.getSkill(), null, true, false);
}
break;
}
case 4:
{
if ((skill_04 != null) && SkillCaster.checkUseConditions(npc, skill_04.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.YOU_WILL_BE_DESTROYED);
npc.doCast(skill_04.getSkill(), null, true, false);
}
break;
}
case 5:
{
if ((skill_05 != null) && SkillCaster.checkUseConditions(npc, skill_05.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.YOU_WILL_DIE);
npc.doCast(skill_05.getSkill(), null, true, false);
}
break;
}
}
}
}
public void onCreatureAttacked(OnCreatureAttacked event)
{
final L2Npc npc = (L2Npc) event.getTarget();
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && !event.getAttacker().isPlayable())
if (npc != null)
{
final StatsSet instParams = instance.getTemplateParameters();
final int random = getRandom(1000);
if (random < 333)
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && !npc.isInCombat() && !event.getAttacker().isPlayable() && !CommonUtil.contains(KARTIA_FRIENDS, event.getAttacker().getId()))
{
final SkillHolder infinitySkill = instParams.getSkillHolder("bartonInfinity");
if ((infinitySkill != null) && SkillCaster.checkUseConditions(npc, infinitySkill.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.DIE3);
addSkillCastDesire(npc, npc.getTarget(), infinitySkill, 23);
}
}
else if ((npc.getCurrentHpPercent() < 50) && npc.isScriptValue(0))
{
final SkillHolder berserkerSkill = instParams.getSkillHolder("bartonBerserker");
if ((berserkerSkill != null) && !npc.isAffectedBySkill(berserkerSkill.getSkillId()) && SkillCaster.checkUseConditions(npc, berserkerSkill.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.WAAAAAAAAHHHHHH);
addSkillCastDesire(npc, npc.getTarget(), berserkerSkill, 23);
getTimers().addTimer("RESTORE_SCRIPTVAL", 10000, n -> npc.setScriptValue(0));
}
npc.setTarget(event.getAttacker());
addAttackDesire(npc, (L2Character) npc.getTarget());
}
}
}
@@ -180,6 +249,7 @@ public final class KartiaHelperBarton extends AbstractNpcAI
if (world != null)
{
getTimers().cancelTimersOf(npc);
npc.doDie(event.getAttacker());
}
}

View File

@@ -16,8 +16,15 @@
*/
package instances.KartiasLabyrinth;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.l2jmobius.commons.util.CommonUtil;
import com.l2jmobius.gameserver.enums.ChatType;
import com.l2jmobius.gameserver.enums.InstanceType;
import com.l2jmobius.gameserver.model.L2Object;
import com.l2jmobius.gameserver.model.Location;
import com.l2jmobius.gameserver.model.StatsSet;
import com.l2jmobius.gameserver.model.actor.L2Character;
@@ -34,8 +41,8 @@ import com.l2jmobius.gameserver.util.Util;
import ai.AbstractNpcAI;
/**
* Kartia Helper Elise AI.
* @author St3eT
* Kartia Helper Elise AI. Healer
* @author flanagak
*/
public final class KartiaHelperElise extends AbstractNpcAI
{
@@ -70,9 +77,27 @@ public final class KartiaHelperElise extends AbstractNpcAI
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
};
private static final int HEALING_TREE = 19256;
// Skill
private static final SkillHolder TREE_HEAL_SKILL = new SkillHolder(15003, 1); // Summon Tree of Life - NPC
private static final int[] KARTIA_FRIENDS =
{
33617, // Elise (Kartia 85)
33628, // Elise (Kartia 90)
33639, // Elise (Kartia 95)
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
33611, // Barton (Kartia 85)
33622, // Barton (Kartia 90)
33633, // Barton (Kartia 95)
33615, // Eliyah (Kartia 85)
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
33613, // Hayuk (Kartia 85)
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
33618, // Eliyah's Guardian Spirit (Kartia 85)
33629, // Eliyah's Guardian Spirit (Kartia 90)
33640, // Eliyah's Guardian Spirit (Kartia 95)
};
// Misc
private static final int[] KARTIA_SOLO_INSTANCES =
{
@@ -95,167 +120,124 @@ public final class KartiaHelperElise extends AbstractNpcAI
if ((instance != null) && event.equals("CHECK_ACTION"))
{
final StatsSet npcVars = npc.getVariables();
final StatsSet instParams = instance.getTemplateParameters();
player = npcVars.getObject("PLAYER_OBJECT", L2PcInstance.class);
final FriendlyNpcInstance adolph = npcVars.getObject("ADOLPH_OBJECT", FriendlyNpcInstance.class);
final FriendlyNpcInstance barton = npcVars.getObject("BARTON_OBJECT", FriendlyNpcInstance.class);
final FriendlyNpcInstance eliyah = npcVars.getObject("ELIYAH_OBJECT", FriendlyNpcInstance.class);
final FriendlyNpcInstance hayuk = npcVars.getObject("HAYUK_OBJECT", FriendlyNpcInstance.class);
if ((player != null) && !player.isDead() && ((player.getCurrentHpPercent() < 75) || (player.getCurrentMpPercent() < 30)))
if (!npc.isCastingNow())
{
final int hpPer = player.getCurrentHpPercent();
if ((hpPer < 40) && npcVars.getBoolean("CAN_USE_TREE", true))
{
summonHealingTree(npc, player);
}
else if (hpPer < 60)
{
final SkillHolder chainSkill = instParams.getSkillHolder("eliseChainHeal");
if (chainSkill != null)
{
addSkillCastDesire(npc, player, chainSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
}
}
else if (hpPer < 75)
{
final SkillHolder healSkill = instParams.getSkillHolder("eliseHeal");
if (healSkill != null)
{
addSkillCastDesire(npc, player, healSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
}
}
else if (player.getCurrentMpPercent() < 30)
{
final SkillHolder rechargeSkill = instParams.getSkillHolder("eliseRecharge");
if (rechargeSkill != null)
{
addSkillCastDesire(npc, player, rechargeSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.MEN_FOCUS_CHARGING_COMPLETE);
}
}
healFriends(npc, player);
}
else if ((adolph != null) && !adolph.isDead() && (adolph.getCurrentHpPercent() < 75))
{
final int hpPer = adolph.getCurrentHpPercent();
if ((hpPer < 40) && npcVars.getBoolean("CAN_USE_TREE", true))
{
summonHealingTree(npc, adolph);
}
else if (hpPer < 60)
{
final SkillHolder chainSkill = instParams.getSkillHolder("eliseChainHeal");
if (chainSkill != null)
{
addSkillCastDesire(npc, adolph, chainSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
}
}
else
{
final SkillHolder healSkill = instParams.getSkillHolder("eliseHeal");
if (healSkill != null)
{
addSkillCastDesire(npc, adolph, healSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
}
}
}
else if ((barton != null) && !barton.isDead() && (barton.getCurrentHpPercent() < 60))
{
final int hpPer = barton.getCurrentHpPercent();
if ((hpPer < 30) && npcVars.getBoolean("CAN_USE_TREE", true))
{
summonHealingTree(npc, barton);
}
else
{
final SkillHolder chainSkill = instParams.getSkillHolder("eliseChainHeal");
if (chainSkill != null)
{
addSkillCastDesire(npc, barton, chainSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
}
}
}
else if ((eliyah != null) && !eliyah.isDead() && (eliyah.getCurrentHpPercent() < 60))
{
final int hpPer = eliyah.getCurrentHpPercent();
if ((hpPer < 30) && npcVars.getBoolean("CAN_USE_TREE", true))
{
summonHealingTree(npc, eliyah);
}
else
{
final SkillHolder chainSkill = instParams.getSkillHolder("eliseChainHeal");
if (chainSkill != null)
{
addSkillCastDesire(npc, eliyah, chainSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
}
}
}
else if ((hayuk != null) && !hayuk.isDead() && (hayuk.getCurrentHpPercent() < 60))
{
final int hpPer = hayuk.getCurrentHpPercent();
if ((hpPer < 30) && npcVars.getBoolean("CAN_USE_TREE", true))
{
summonHealingTree(npc, hayuk);
}
else
{
final SkillHolder chainSkill = instParams.getSkillHolder("eliseChainHeal");
if (chainSkill != null)
{
addSkillCastDesire(npc, hayuk, chainSkill, 23);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
}
}
}
else if (adolph != null)
if (adolph != null)
{
final double distance = npc.calculateDistance(adolph, false, false);
if (distance > 200)
if (distance > 300)
{
final Location loc = new Location(adolph.getX() + getRandom(-100, 100), adolph.getY() + getRandom(-100, 100), adolph.getZ() + 50);
if (distance > 500)
final Location loc = new Location(adolph.getX(), adolph.getY(), adolph.getZ() + 50);
final Location randLoc = new Location(loc.getX() + getRandom(-100, 100), loc.getY() + getRandom(-100, 100), loc.getZ());
if (distance > 600)
{
npc.teleToLocation(loc);
}
else
{
npc.setRunning();
addMoveToDesire(npc, loc, 23);
}
addMoveToDesire(npc, randLoc, 23);
}
}
npc.setTarget(npc);
}
}
private void healFriends(L2Npc npc, L2PcInstance player)
{
final Instance instance = npc.getInstanceWorld();
if (instance != null)
{
final StatsSet npcVars = npc.getVariables();
final StatsSet instParams = instance.getTemplateParameters();
if (!npc.isCastingNow())
{
player = npcVars.getObject("PLAYER_OBJECT", L2PcInstance.class);
final SkillHolder progressiveHeal = instParams.getSkillHolder("eliseProgressiveHeal"); // AOE heal
final SkillHolder radiantHeal = instParams.getSkillHolder("eliseRadiantHeal"); // Single target heal
final SkillHolder recharge = instParams.getSkillHolder("eliseRecharge");
// Get HP percentage for all friends
final Map<L2Object, Integer> hpMap = new HashMap<>();
instance.getAliveNpcs(KARTIA_FRIENDS).forEach(friend -> hpMap.put(friend, friend != null ? friend.getCurrentHpPercent() : 100));
hpMap.put(player, player != null ? player.getCurrentHpPercent() : 100);
Map<L2Object, Integer> sortedHpMap = new HashMap<>();
sortedHpMap = Util.sortByValue(hpMap, false);
// See if any friends are below 80% HP and add to list of people to heal.
final List<L2Object> peopleToHeal = new ArrayList<>();
for (L2Object friend : sortedHpMap.keySet())
{
if ((friend != null) && (sortedHpMap.get(friend) < 80) && (sortedHpMap.get(friend) > 1))
{
peopleToHeal.add(friend);
}
}
if (peopleToHeal.size() > 0)
{
// At least one friend was below 80% HP.
if (peopleToHeal.size() > 1)
{
// Helper NPC AOE skills affecting monsters so skill power has set to 0.
// Using skill is just for animation. Need to heal each NPC/Player manually.
npc.setTarget(npc);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
npc.doCast(progressiveHeal.getSkill(), null, true, false);
npc.setTarget(npc);
for (L2Object personToHeal : peopleToHeal)
{
if (personToHeal.getInstanceType() == InstanceType.L2PcInstance)
{
L2PcInstance thePlayer = (L2PcInstance) personToHeal;
thePlayer.setCurrentHp((thePlayer.getMaxHp() * .20) + thePlayer.getCurrentHp());
}
else
{
L2Npc npcToHeal = (L2Npc) personToHeal;
npcToHeal.setCurrentHp((npcToHeal.getMaxHp() * .20) + npcToHeal.getCurrentHp());
}
}
}
else
{
// Only one person needs cure. Cast single target heal
for (L2Object personToHeal : peopleToHeal)
{
npc.setTarget(personToHeal);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.POWER_OF_LIGHT_PROTECT_US);
npc.doCast(radiantHeal.getSkill(), null, true, false);
npc.setTarget(npc);
}
}
}
else
{
// No one needs healing. Check if player character needs recharge.
if ((player != null) && !player.isDead() && (player.getCurrentMpPercent() < 50))
{
npc.setTarget(player);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.ELECTRIFYING_RECHARGE);
npc.doCast(recharge.getSkill(), null, true, false);
npc.setTarget(npc);
}
}
}
}
}
public void onInstanceStatusChange(OnInstanceStatusChange event)
{
final Instance instance = event.getWorld();
final int status = event.getStatus();
switch (status)
if (status == 1)
{
case 1:
{
instance.getAliveNpcs(KARTIA_ELISE).forEach(elise -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, elise, null));
break;
}
case 2:
case 3:
{
final Location loc = instance.getTemplateParameters().getLocation("eliseTeleportStatus" + status);
if (loc != null)
{
instance.getAliveNpcs(KARTIA_ELISE).forEach(elise -> elise.teleToLocation(loc));
}
break;
}
instance.getAliveNpcs(KARTIA_ELISE).forEach(elise -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, elise, null));
}
}
@@ -297,18 +279,10 @@ public final class KartiaHelperElise extends AbstractNpcAI
if (world != null)
{
getTimers().cancelTimersOf(npc);
npc.doDie(event.getAttacker());
}
}
private void summonHealingTree(L2Npc npc, L2Character target)
{
npc.getVariables().set("CAN_USE_TREE", false);
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.COME_FORTH_TREE_OF_LIFE);
final L2Npc tree = addSpawn(HEALING_TREE, Util.getRandomPosition(target, 20, 50), false, 0, false, npc.getInstanceId());
getTimers().addTimer("TREE_REUSE", 10000, evnt -> npc.getVariables().set("CAN_USE_TREE", true));
getTimers().addTimer("TREE_HEAL", 3000, evnt -> addSkillCastDesire(tree, target, TREE_HEAL_SKILL, 23));
}
public static void main(String[] args)
{
new KartiaHelperElise();

View File

@@ -16,15 +16,23 @@
*/
package instances.KartiasLabyrinth;
import com.l2jmobius.commons.util.CommonUtil;
import com.l2jmobius.gameserver.model.Location;
import com.l2jmobius.gameserver.model.StatsSet;
import com.l2jmobius.gameserver.model.actor.L2Character;
import com.l2jmobius.gameserver.model.actor.L2Npc;
import com.l2jmobius.gameserver.model.actor.instance.FriendlyNpcInstance;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureAttacked;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureDeath;
import com.l2jmobius.gameserver.model.events.impl.instance.OnInstanceStatusChange;
import com.l2jmobius.gameserver.model.instancezone.Instance;
import ai.AbstractNpcAI;
/**
* Kartia Helper Eliyah AI.
* @author St3eT
* Kartia Helper Eliyah AI. Summoner
* @author flanagak
*/
public final class KartiaHelperEliyah extends AbstractNpcAI
{
@@ -35,6 +43,33 @@ public final class KartiaHelperEliyah extends AbstractNpcAI
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
};
private static final int[] KARTIA_ADOLPH =
{
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
};
private static final int[] KARTIA_FRIENDS =
{
33617, // Elise (Kartia 85)
33628, // Elise (Kartia 90)
33639, // Elise (Kartia 95)
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
33611, // Barton (Kartia 85)
33622, // Barton (Kartia 90)
33633, // Barton (Kartia 95)
33615, // Eliyah (Kartia 85)
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
33613, // Hayuk (Kartia 85)
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
33618, // Eliyah's Guardian Spirit (Kartia 85)
33629, // Eliyah's Guardian Spirit (Kartia 90)
33640, // Eliyah's Guardian Spirit (Kartia 95)
};
// Misc
private static final int[] KARTIA_SOLO_INSTANCES =
{
@@ -45,33 +80,101 @@ public final class KartiaHelperEliyah extends AbstractNpcAI
private KartiaHelperEliyah()
{
setCreatureKillId(this::onCreatureKill, KARTIA_ELIYAH);
setCreatureAttackedId(this::onCreatureAttacked, KARTIA_ELIYAH);
addSeeCreatureId(KARTIA_ELIYAH);
setInstanceStatusChangeId(this::onInstanceStatusChange, KARTIA_SOLO_INSTANCES);
}
@Override
public void onTimerEvent(String event, StatsSet params, L2Npc npc, L2PcInstance player)
{
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && event.equals("CHECK_ACTION"))
{
final FriendlyNpcInstance adolph = npc.getVariables().getObject("ADOLPH_OBJECT", FriendlyNpcInstance.class);
if (adolph != null)
{
final double distance = npc.calculateDistance(adolph, false, false);
if (distance > 300)
{
final Location loc = new Location(adolph.getX(), adolph.getY(), adolph.getZ() + 50);
final Location randLoc = new Location(loc.getX() + getRandom(-100, 100), loc.getY() + getRandom(-100, 100), loc.getZ());
if (distance > 600)
{
npc.teleToLocation(loc);
}
else
{
npc.setRunning();
}
addMoveToDesire(npc, randLoc, 23);
}
else if (!npc.isInCombat() || (npc.getTarget() == null))
{
final L2Character monster = (L2Character) adolph.getTarget();
if ((monster != null) && adolph.isInCombat() && !CommonUtil.contains(KARTIA_FRIENDS, monster.getId()))
{
npc.setTarget(monster);
}
}
}
}
}
public void onInstanceStatusChange(OnInstanceStatusChange event)
{
final Instance instance = event.getWorld();
final int status = event.getStatus();
switch (status)
if (status == 1)
{
case 1:
instance.getAliveNpcs(KARTIA_ELIYAH).forEach(eliyah -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, eliyah, null));
if ((instance.getAliveNpcs(KARTIA_ELIYAH) != null) && (instance.getAliveNpcs(KARTIA_ELIYAH).size() > 0))
{
// Nothing for now
break;
instance.spawnGroup("GUARDIANS");
}
case 2:
case 3:
}
}
@Override
public String onSeeCreature(L2Npc npc, L2Character creature, boolean isSummon)
{
if (creature.isPlayer())
{
npc.getVariables().set("PLAYER_OBJECT", creature.getActingPlayer());
}
else if (CommonUtil.contains(KARTIA_ADOLPH, creature.getId()))
{
npc.getVariables().set("ADOLPH_OBJECT", creature);
}
return super.onSeeCreature(npc, creature, isSummon);
}
public void onCreatureAttacked(OnCreatureAttacked event)
{
final L2Npc npc = (L2Npc) event.getTarget();
if (npc != null)
{
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && !event.getAttacker().isPlayable() && !CommonUtil.contains(KARTIA_FRIENDS, npc.getTargetId()))
{
final Location loc = instance.getTemplateParameters().getLocation("eliyahTeleportStatus" + status);
if (loc != null)
{
instance.getAliveNpcs(KARTIA_ELIYAH).forEach(eliyah -> eliyah.teleToLocation(loc));
}
break;
npc.setTarget(event.getAttacker());
}
}
}
public void onCreatureKill(OnCreatureDeath event)
{
final L2Npc npc = (L2Npc) event.getTarget();
final Instance world = npc.getInstanceWorld();
if (world != null)
{
getTimers().cancelTimersOf(npc);
world.despawnGroup("GUARDIANS");
npc.doDie(event.getAttacker());
}
}
public static void main(String[] args)
{
new KartiaHelperEliyah();

View File

@@ -0,0 +1,237 @@
/*
* This file is part of the L2J Mobius project.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package instances.KartiasLabyrinth;
import com.l2jmobius.commons.util.CommonUtil;
import com.l2jmobius.gameserver.model.Location;
import com.l2jmobius.gameserver.model.StatsSet;
import com.l2jmobius.gameserver.model.actor.L2Character;
import com.l2jmobius.gameserver.model.actor.L2Npc;
import com.l2jmobius.gameserver.model.actor.instance.FriendlyNpcInstance;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureAttacked;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureDeath;
import com.l2jmobius.gameserver.model.events.impl.instance.OnInstanceStatusChange;
import com.l2jmobius.gameserver.model.holders.SkillHolder;
import com.l2jmobius.gameserver.model.instancezone.Instance;
import com.l2jmobius.gameserver.model.skills.SkillCaster;
import ai.AbstractNpcAI;
/**
* Kartia Helper Eliyah's Guardian Spirit
* @author flanagak *
*/
public final class KartiaHelperGuardian extends AbstractNpcAI
{
// NPCs
private static final int[] KARTIA_ELIYAH =
{
33615, // Eliyah (Kartia 85)
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
};
private static final int[] KARTIA_ADOLPH =
{
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
};
private static final int[] KARTIA_FRIENDS =
{
33617, // Elise (Kartia 85)
33628, // Elise (Kartia 90)
33639, // Elise (Kartia 95)
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
33611, // Barton (Kartia 85)
33622, // Barton (Kartia 90)
33633, // Barton (Kartia 95)
33615, // Eliyah (Kartia 85)
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
33613, // Hayuk (Kartia 85)
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
33618, // Eliyah's Guardian Spirit (Kartia 85)
33629, // Eliyah's Guardian Spirit (Kartia 90)
33640, // Eliyah's Guardian Spirit (Kartia 95)
};
private static final int[] KARTIA_GUARDIANS =
{
33618, // Eliyah's Guardian Spirit (Kartia 85)
33629, // Eliyah's Guardian Spirit (Kartia 90)
33640, // Eliyah's Guardian Spirit (Kartia 95)
};
// Misc
private static final int[] KARTIA_SOLO_INSTANCES =
{
205, // Solo 85
206, // Solo 90
207, // Solo 95
};
private KartiaHelperGuardian()
{
setCreatureKillId(this::onCreatureKill, KARTIA_GUARDIANS);
setCreatureAttackedId(this::onCreatureAttacked, KARTIA_GUARDIANS);
addSeeCreatureId(KARTIA_GUARDIANS);
setInstanceStatusChangeId(this::onInstanceStatusChange, KARTIA_SOLO_INSTANCES);
}
@Override
public void onTimerEvent(String event, StatsSet params, L2Npc npc, L2PcInstance player)
{
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && event.equals("CHECK_ACTION"))
{
final FriendlyNpcInstance eliyah = npc.getVariables().getObject("ELIYAH_OBJECT", FriendlyNpcInstance.class);
if (eliyah != null)
{
final double distance = npc.calculateDistance(eliyah, false, false);
if (distance > 300)
{
final Location loc = new Location(eliyah.getX(), eliyah.getY(), eliyah.getZ() + 50);
final Location randLoc = new Location(loc.getX() + getRandom(-50, 50), loc.getY() + getRandom(-50, 50), loc.getZ());
if (distance > 600)
{
npc.teleToLocation(loc);
}
else
{
npc.setRunning();
}
addMoveToDesire(npc, randLoc, 23);
}
else if (!npc.isInCombat() || (npc.getTarget() == null))
{
final L2Character monster = (L2Character) eliyah.getTarget();
if ((monster != null) && !CommonUtil.contains(KARTIA_FRIENDS, monster.getId()))
{
addAttackDesire(npc, monster);
}
}
}
}
else if ((instance != null) && event.equals("USE_SKILL"))
{
if (npc.isInCombat() || npc.isAttackingNow() || (npc.getTarget() != null))
{
if ((npc.getCurrentMpPercent() > 25) && !CommonUtil.contains(KARTIA_FRIENDS, npc.getTargetId()))
{
useRandomSkill(npc);
}
}
}
}
public void onInstanceStatusChange(OnInstanceStatusChange event)
{
final Instance instance = event.getWorld();
final int status = event.getStatus();
if (status == 1)
{
instance.getAliveNpcs(KARTIA_GUARDIANS).forEach(guardian -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, guardian, null));
instance.getAliveNpcs(KARTIA_GUARDIANS).forEach(guardian -> getTimers().addRepeatingTimer("USE_SKILL", 6000, guardian, null));
}
}
@Override
public String onSeeCreature(L2Npc npc, L2Character creature, boolean isSummon)
{
if (creature.isPlayer())
{
npc.getVariables().set("PLAYER_OBJECT", creature.getActingPlayer());
}
else if (CommonUtil.contains(KARTIA_ADOLPH, creature.getId()))
{
npc.getVariables().set("ADOLPH_OBJECT", creature);
}
else if (CommonUtil.contains(KARTIA_ELIYAH, creature.getId()))
{
npc.getVariables().set("ELIYAH_OBJECT", creature);
}
return super.onSeeCreature(npc, creature, isSummon);
}
public void useRandomSkill(L2Npc npc)
{
final Instance instance = npc.getInstanceWorld();
final L2Npc target = (L2Npc) npc.getTarget();
if ((instance != null) && !npc.isCastingNow() && (target != null) && (!CommonUtil.contains(KARTIA_FRIENDS, target.getId())))
{
final StatsSet instParams = instance.getTemplateParameters();
final SkillHolder skill_01 = instParams.getSkillHolder("guardianSpiritsBlow");
final SkillHolder skill_02 = instParams.getSkillHolder("guardianSpiritsWrath");
final int numberOfActiveSkills = 2;
final int randomSkill = getRandom(numberOfActiveSkills + 1);
switch (randomSkill)
{
case 0:
case 1:
{
if ((skill_01 != null) && SkillCaster.checkUseConditions(npc, skill_01.getSkill()))
{
npc.doCast(skill_01.getSkill(), null, true, false);
}
break;
}
case 2:
{
if ((skill_02 != null) && SkillCaster.checkUseConditions(npc, skill_02.getSkill()))
{
npc.doCast(skill_02.getSkill(), null, true, false);
}
break;
}
}
}
}
public void onCreatureAttacked(OnCreatureAttacked event)
{
final L2Npc npc = (L2Npc) event.getTarget();
if (npc != null)
{
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && !npc.isInCombat() && !event.getAttacker().isPlayable() && !CommonUtil.contains(KARTIA_FRIENDS, event.getAttacker().getId()))
{
npc.setTarget(event.getAttacker());
addAttackDesire(npc, (L2Character) npc.getTarget());
}
}
}
public void onCreatureKill(OnCreatureDeath event)
{
final L2Npc npc = (L2Npc) event.getTarget();
final Instance world = npc.getInstanceWorld();
if (world != null)
{
getTimers().cancelTimersOf(npc);
npc.doDie(event.getAttacker());
}
}
public static void main(String[] args)
{
new KartiaHelperGuardian();
}
}

View File

@@ -16,25 +16,65 @@
*/
package instances.KartiasLabyrinth;
import com.l2jmobius.commons.util.CommonUtil;
import com.l2jmobius.gameserver.enums.ChatType;
import com.l2jmobius.gameserver.model.Location;
import com.l2jmobius.gameserver.model.StatsSet;
import com.l2jmobius.gameserver.model.actor.L2Character;
import com.l2jmobius.gameserver.model.actor.L2Npc;
import com.l2jmobius.gameserver.model.actor.instance.FriendlyNpcInstance;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureAttacked;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureDeath;
import com.l2jmobius.gameserver.model.events.impl.instance.OnInstanceStatusChange;
import com.l2jmobius.gameserver.model.holders.SkillHolder;
import com.l2jmobius.gameserver.model.instancezone.Instance;
import com.l2jmobius.gameserver.model.skills.SkillCaster;
import com.l2jmobius.gameserver.network.NpcStringId;
import ai.AbstractNpcAI;
/**
* Kartia Helper Hayuk AI.
* @author St3eT
* Kartia Helper Hayuk AI. Archer
* @author flanagak
*/
public final class KartiaHelperHayuk extends AbstractNpcAI
{
// NPCs
private static final int[] KARTIA_ADOLPH =
{
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
};
private static final int[] KARTIA_HAYUK =
{
33613, // Hayuk (Kartia 85)
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
};
private static final int[] KARTIA_FRIENDS =
{
33617, // Elise (Kartia 85)
33628, // Elise (Kartia 90)
33639, // Elise (Kartia 95)
33609, // Adolph (Kartia 85)
33620, // Adolph (Kartia 90)
33631, // Adolph (Kartia 95)
33611, // Barton (Kartia 85)
33622, // Barton (Kartia 90)
33633, // Barton (Kartia 95)
33615, // Eliyah (Kartia 85)
33626, // Eliyah (Kartia 90)
33637, // Eliyah (Kartia 95)
33613, // Hayuk (Kartia 85)
33624, // Hayuk (Kartia 90)
33635, // Hayuk (Kartia 95)
33618, // Eliyah's Guardian Spirit (Kartia 85)
33629, // Eliyah's Guardian Spirit (Kartia 90)
33640, // Eliyah's Guardian Spirit (Kartia 95)
};
// Misc
private static final int[] KARTIA_SOLO_INSTANCES =
{
@@ -45,33 +85,155 @@ public final class KartiaHelperHayuk extends AbstractNpcAI
private KartiaHelperHayuk()
{
setCreatureKillId(this::onCreatureKill, KARTIA_HAYUK);
setCreatureAttackedId(this::onCreatureAttacked, KARTIA_HAYUK);
addSeeCreatureId(KARTIA_HAYUK);
setInstanceStatusChangeId(this::onInstanceStatusChange, KARTIA_SOLO_INSTANCES);
}
@Override
public void onTimerEvent(String event, StatsSet params, L2Npc npc, L2PcInstance player)
{
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && event.equals("CHECK_ACTION"))
{
final FriendlyNpcInstance adolph = npc.getVariables().getObject("ADOLPH_OBJECT", FriendlyNpcInstance.class);
if (adolph != null)
{
final double distance = npc.calculateDistance(adolph, false, false);
if (distance > 300)
{
final Location loc = new Location(adolph.getX(), adolph.getY(), adolph.getZ() + 50);
final Location randLoc = new Location(loc.getX() + getRandom(-100, 100), loc.getY() + getRandom(-100, 100), loc.getZ());
if (distance > 600)
{
npc.teleToLocation(loc);
}
else
{
npc.setRunning();
}
addMoveToDesire(npc, randLoc, 23);
}
else if (!npc.isInCombat() || (npc.getTarget() == null))
{
final L2Character monster = (L2Character) adolph.getTarget();
if ((monster != null) && adolph.isInCombat() && !CommonUtil.contains(KARTIA_FRIENDS, monster.getId()))
{
addAttackDesire(npc, monster);
}
}
}
}
else if ((instance != null) && event.equals("USE_SKILL"))
{
if (npc.isInCombat() || npc.isAttackingNow() || (npc.getTarget() != null))
{
if ((npc.getCurrentMpPercent() > 25) && !CommonUtil.contains(KARTIA_FRIENDS, npc.getTargetId()))
{
useRandomSkill(npc);
}
}
}
}
public void onInstanceStatusChange(OnInstanceStatusChange event)
{
final Instance instance = event.getWorld();
final int status = event.getStatus();
switch (status)
if (status == 1)
{
case 1:
instance.getAliveNpcs(KARTIA_HAYUK).forEach(hayuk -> getTimers().addRepeatingTimer("CHECK_ACTION", 3000, hayuk, null));
instance.getAliveNpcs(KARTIA_HAYUK).forEach(hayuk -> getTimers().addRepeatingTimer("USE_SKILL", 6000, hayuk, null));
}
}
@Override
public String onSeeCreature(L2Npc npc, L2Character creature, boolean isSummon)
{
if (creature.isPlayer())
{
npc.getVariables().set("PLAYER_OBJECT", creature.getActingPlayer());
}
else if (CommonUtil.contains(KARTIA_ADOLPH, creature.getId()))
{
npc.getVariables().set("ADOLPH_OBJECT", creature);
}
return super.onSeeCreature(npc, creature, isSummon);
}
public void useRandomSkill(L2Npc npc)
{
final Instance instance = npc.getInstanceWorld();
final L2Npc target = (L2Npc) npc.getTarget();
if ((instance != null) && !npc.isCastingNow() && (target != null) && (!CommonUtil.contains(KARTIA_FRIENDS, target.getId())))
{
final StatsSet instParams = instance.getTemplateParameters();
final SkillHolder skill_01 = instParams.getSkillHolder("hayukPinpointShot");
final SkillHolder skill_02 = instParams.getSkillHolder("hayukRecoilShot");
final SkillHolder skill_03 = instParams.getSkillHolder("hayukMultipleArrow");
final int numberOfActiveSkills = 3;
final int randomSkill = getRandom(numberOfActiveSkills + 1);
switch (randomSkill)
{
// Nothing for now
break;
}
case 2:
case 3:
{
final Location loc = instance.getTemplateParameters().getLocation("hayukTeleportStatus" + status);
if (loc != null)
case 0:
case 1:
{
instance.getAliveNpcs(KARTIA_HAYUK).forEach(hayuk -> hayuk.teleToLocation(loc));
if ((skill_01 != null) && SkillCaster.checkUseConditions(npc, skill_01.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.I_WILL_SHOW_YOU_THE_JUSTICE_OF_ADEN);
npc.doCast(skill_01.getSkill(), null, true, false);
}
break;
}
case 2:
{
if ((skill_02 != null) && SkillCaster.checkUseConditions(npc, skill_02.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.DIE3);
npc.doCast(skill_02.getSkill(), null, true, false);
}
break;
}
case 3:
{
if ((skill_03 != null) && SkillCaster.checkUseConditions(npc, skill_03.getSkill()))
{
npc.broadcastSay(ChatType.NPC_GENERAL, NpcStringId.FOR_THE_GODDESS);
npc.doCast(skill_03.getSkill(), null, true, false);
}
break;
}
break;
}
}
}
public void onCreatureAttacked(OnCreatureAttacked event)
{
final L2Npc npc = (L2Npc) event.getTarget();
if (npc != null)
{
final Instance instance = npc.getInstanceWorld();
if ((instance != null) && !npc.isInCombat() && !event.getAttacker().isPlayable() && !CommonUtil.contains(KARTIA_FRIENDS, event.getAttacker().getId()))
{
npc.setTarget(event.getAttacker());
addAttackDesire(npc, (L2Character) npc.getTarget());
}
}
}
public void onCreatureKill(OnCreatureDeath event)
{
final L2Npc npc = (L2Npc) event.getTarget();
final Instance world = npc.getInstanceWorld();
if (world != null)
{
getTimers().cancelTimersOf(npc);
npc.doDie(event.getAttacker());
}
}
public static void main(String[] args)
{
new KartiaHelperHayuk();

View File

@@ -19,13 +19,16 @@ package instances.KartiasLabyrinth;
import java.util.List;
import com.l2jmobius.commons.util.CommonUtil;
import com.l2jmobius.gameserver.ai.CtrlIntention;
import com.l2jmobius.gameserver.enums.ChatType;
import com.l2jmobius.gameserver.enums.InstanceType;
import com.l2jmobius.gameserver.instancemanager.WalkingManager;
import com.l2jmobius.gameserver.model.Location;
import com.l2jmobius.gameserver.model.StatsSet;
import com.l2jmobius.gameserver.model.actor.L2Attackable;
import com.l2jmobius.gameserver.model.actor.L2Character;
import com.l2jmobius.gameserver.model.actor.L2Npc;
import com.l2jmobius.gameserver.model.actor.instance.L2MonsterInstance;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureDeath;
import com.l2jmobius.gameserver.model.events.impl.character.OnCreatureSee;
@@ -47,7 +50,7 @@ import quests.Q00499_IncarnationOfGluttonyKaliosSolo.Q00499_IncarnationOfGlutton
/**
* Kartia Labyrinth instance zone.
* @author St3eT
* @author flanagak
*/
public final class KartiasLabyrinth extends AbstractInstance
{
@@ -84,17 +87,27 @@ public final class KartiasLabyrinth extends AbstractInstance
33623,
33634,
};
// @formatter:off
private static final int[] MONSTERS =
{
19220, 19221, 19222, // Solo 85
19223, 19224, 19225, // Solo 90
19226, 19227, 19228, // Solo 95
19229, 19230, 19231, // Group 85
19232, 19233, 19234, // Group 90
19235, 19236, 19237, // Group 95
19220,
19221,
19222, // Solo 85
19223,
19224,
19225, // Solo 90
19226,
19227,
19228, // Solo 95
19229,
19230,
19231, // Group 85
19232,
19233,
19234, // Group 90
19235,
19236,
19237, // Group 95
};
// @formatter:on
private static final int[] BOSSES =
{
19253, // Zellaka (Solo 85)
@@ -134,19 +147,10 @@ public final class KartiasLabyrinth extends AbstractInstance
// Zones
private static final int KARTIA_85_DETECT_1 = 12020;
private static final int KARTIA_85_DETECT_2 = 12021;
// private static final int KARTIA_85_TELEPORT_1 = 12022;
// private static final int KARTIA_85_TELEPORT_2 = 12023;
// private static final int KARTIA_85_TELEPORT_3 = 12024;
private static final int KARTIA_90_DETECT_1 = 12025;
private static final int KARTIA_90_DETECT_2 = 12026;
// private static final int KARTIA_90_TELEPORT_1 = 12027;
// private static final int KARTIA_90_TELEPORT_2 = 12028;
// private static final int KARTIA_90_TELEPORT_3 = 12029;
private static final int KARTIA_95_DETECT_1 = 12030;
private static final int KARTIA_95_DETECT_2 = 12031;
// private static final int KARTIA_95_TELEPORT_1 = 12032;
// private static final int KARTIA_95_TELEPORT_2 = 12033;
// private static final int KARTIA_95_TELEPORT_3 = 12034;
// Misc
private static final int TEMPLATE_ID_SOLO_85 = 205;
private static final int TEMPLATE_ID_SOLO_90 = 206;
@@ -154,6 +158,22 @@ public final class KartiasLabyrinth extends AbstractInstance
private static final int TEMPLATE_ID_GROUP_85 = 208;
private static final int TEMPLATE_ID_GROUP_90 = 209;
private static final int TEMPLATE_ID_GROUP_95 = 210;
private static final long WAVE_DEALY = 30000;
private static final long WAVE_MONITOR_DELAY = 3000;
// Solo instance XP reward values
private static final int SOLO_BASE_EXP_85 = 480000000;
private static final int SOLO_RAND_EXP_85 = 8055934;
private static final int SOLO_BASE_EXP_90 = 670000000;
private static final int SOLO_RAND_EXP_90 = 6173918;
private static final int SOLO_BASE_EXP_95 = 970000000;
private static final int SOLO_RAND_EXP_95 = 6305195;
// Solo instance SP reward values
private static final int SOLO_BASE_SP_85 = 3800000;
private static final int SOLO_RAND_SP_85 = 73460;
private static final int SOLO_BASE_SP_90 = 5600000;
private static final int SOLO_RAND_SP_90 = 82134;
private static final int SOLO_BASE_SP_95 = 8500000;
private static final int SOLO_RAND_SP_95 = 39112;
public KartiasLabyrinth()
{
@@ -177,9 +197,9 @@ public final class KartiasLabyrinth extends AbstractInstance
setCreatureKillId(this::onCreatureKill, MONSTERS);
setCreatureKillId(this::onBossKill, BOSSES);
setCreatureSeeId(this::onCreatureSee, MONSTERS);
addEnterZoneId(KARTIA_85_DETECT_1, KARTIA_85_DETECT_2 /* , KARTIA_85_TELEPORT_1, KARTIA_85_TELEPORT_2, KARTIA_85_TELEPORT_3 */);
addEnterZoneId(KARTIA_90_DETECT_1, KARTIA_90_DETECT_2 /* , KARTIA_90_TELEPORT_1, KARTIA_90_TELEPORT_2, KARTIA_90_TELEPORT_3 */);
addEnterZoneId(KARTIA_95_DETECT_1, KARTIA_95_DETECT_2 /* , KARTIA_95_TELEPORT_1, KARTIA_95_TELEPORT_2, KARTIA_95_TELEPORT_3 */);
addEnterZoneId(KARTIA_85_DETECT_1, KARTIA_85_DETECT_2);
addEnterZoneId(KARTIA_90_DETECT_1, KARTIA_90_DETECT_2);
addEnterZoneId(KARTIA_95_DETECT_1, KARTIA_95_DETECT_2);
addInstanceCreatedId(TEMPLATE_ID_SOLO_85, TEMPLATE_ID_SOLO_90, TEMPLATE_ID_SOLO_95, TEMPLATE_ID_GROUP_85, TEMPLATE_ID_GROUP_90, TEMPLATE_ID_GROUP_95);
}
@@ -197,33 +217,63 @@ public final class KartiasLabyrinth extends AbstractInstance
}
case "request_zellaka_solo":
{
enterInstance(player, npc, TEMPLATE_ID_SOLO_85);
return null;
final QuestState qs = player.getQuestState(Q00497_IncarnationOfGreedZellakaSolo.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
enterInstance(player, npc, TEMPLATE_ID_SOLO_85);
return null;
}
return "33647-9.htm";
}
case "request_pelline_solo":
{
enterInstance(player, npc, TEMPLATE_ID_SOLO_90);
return null;
final QuestState qs = player.getQuestState(Q00498_IncarnationOfJealousyPellineSolo.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
enterInstance(player, npc, TEMPLATE_ID_SOLO_90);
return null;
}
return "33647-9.htm";
}
case "request_kalios_solo":
{
enterInstance(player, npc, TEMPLATE_ID_SOLO_95);
return null;
final QuestState qs = player.getQuestState(Q00499_IncarnationOfGluttonyKaliosSolo.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
enterInstance(player, npc, TEMPLATE_ID_SOLO_95);
return null;
}
return "33647-9.htm";
}
case "request_zellaka_party":
{
enterInstance(player, npc, TEMPLATE_ID_GROUP_85);
return null;
final QuestState qs = player.getQuestState(Q00494_IncarnationOfGreedZellakaGroup.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
enterInstance(player, npc, TEMPLATE_ID_GROUP_85);
return null;
}
return "33647-9.htm";
}
case "request_pelline_party":
{
enterInstance(player, npc, TEMPLATE_ID_GROUP_90);
return null;
final QuestState qs = player.getQuestState(Q00495_IncarnationOfJealousyPellineGroup.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
enterInstance(player, npc, TEMPLATE_ID_GROUP_90);
return null;
}
return "33647-9.htm";
}
case "request_kalios_party":
{
enterInstance(player, npc, TEMPLATE_ID_GROUP_95);
return null;
final QuestState qs = player.getQuestState(Q00496_IncarnationOfGluttonyKaliosGroup.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
enterInstance(player, npc, TEMPLATE_ID_GROUP_95);
return null;
}
return "33647-9.htm";
}
default:
{
@@ -280,16 +330,18 @@ public final class KartiasLabyrinth extends AbstractInstance
{
if (npc != null)
{
if (npc.getInstanceWorld().getParameters().getInt("ROOM", 1) <= 2)
if (npc.getInstanceWorld().getParameters().getInt("ROOM", 1) < 2)
{
// Move mobs in Room 1 to the middle at top of the steps. Add timer to start moving towards prisoners.
final Location loc = instance.getTemplateParameters().getLocation("middlePointRoom1");
final Location moveTo = new Location(loc.getX() + getRandom(-100, 100), loc.getY() + getRandom(-100, 100), loc.getZ());
npc.setRunning();
addMoveToDesire(npc, moveTo, 6);
getTimers().addTimer("START_MOVE", 15000, npc, null);
getTimers().addTimer("START_MOVE", 12000, npc, null);
}
else if (npc.getInstanceWorld().getParameters().getInt("ROOM", 1) == 3)
{
// Move mobs in Room 3 towards center of room.
final Location loc = instance.getTemplateParameters().getLocation("middlePointRoom3");
final Location moveTo = new Location(loc.getX() + getRandom(-200, 200), loc.getY() + getRandom(-200, 200), loc.getZ());
npc.setRunning();
@@ -302,18 +354,8 @@ public final class KartiasLabyrinth extends AbstractInstance
{
if (npc != null)
{
WalkingManager.getInstance().startMoving(npc, instance.getTemplateParameters().getString(getRandomBoolean() ? "route1" : "route2"));
getTimers().addTimer("CHANGE_TARGETABLE_STATUS", 5000, npc, null);
}
break;
}
case "CHANGE_TARGETABLE_STATUS":
{
if (npc != null)
{
npc.setTargetable(true);
final L2PcInstance randomPlayer = instance.getPlayers().stream().findAny().get();
npc.moveToLocation(randomPlayer.getX(), randomPlayer.getY(), randomPlayer.getZ(), 10);
final String selectedRoute = (getRandomBoolean() ? "route1_" : "route2_") + Integer.toString(getRandom(1, 3));
WalkingManager.getInstance().startMoving(npc, instance.getTemplateParameters().getString(selectedRoute));
}
break;
}
@@ -346,7 +388,6 @@ public final class KartiasLabyrinth extends AbstractInstance
});
instance.getParameters().set("TELEPORT_1_ENABLED", true);
if (!isSoloKartia(instance))
{
getTimers().addTimer("CALL_PROGRESS", 2500, n -> manageProgressInInstance(instance));
@@ -375,6 +416,20 @@ public final class KartiasLabyrinth extends AbstractInstance
}
}
private void manageWaves(Instance instance)
{
if ((instance != null) && instance.getAliveNpcs(MONSTERS).isEmpty())
{
getTimers().cancelTimers("NEXT_WAVE_DELAY");
getTimers().cancelTimers("MONITOR_WAVE");
getTimers().addTimer("CALL_PROGRESS", 5000, n -> manageProgressInInstance(instance));
}
else
{
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
}
}
public void onBossKill(OnCreatureDeath event)
{
final L2Npc npc = (L2Npc) event.getTarget();
@@ -384,80 +439,29 @@ public final class KartiasLabyrinth extends AbstractInstance
{
if (isSoloKartia(instance))
{
final StatsSet tempParam = instance.getTemplateParameters();
final int xp = tempParam.getInt("soloEXP");
final int xp_rnd = tempParam.getInt("SoloEXP_Rand");
final int sp = tempParam.getInt("SoloSP");
final int sp_rnd = tempParam.getInt("SoloSP_Rand");
instance.getPlayers().forEach(player ->
final L2PcInstance player = instance.getFirstPlayer();
if (player != null)
{
addExpAndSp(player, (xp + getRandom(xp_rnd)), (sp + getRandom(sp_rnd)));
});
}
// Check Instance Quests.
instance.getPlayers().forEach(player ->
{
switch (instance.getTemplateId())
{
case TEMPLATE_ID_SOLO_85:
switch (instance.getTemplateId())
{
final QuestState qs = player.getQuestState(Q00497_IncarnationOfGreedZellakaSolo.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
case TEMPLATE_ID_SOLO_85:
{
qs.setCond(2, true);
player.addExpAndSp(SOLO_BASE_EXP_85 + getRandom(SOLO_RAND_EXP_85), SOLO_BASE_SP_85 + getRandom(SOLO_RAND_SP_85));
break;
}
break;
}
case TEMPLATE_ID_SOLO_90:
{
final QuestState qs = player.getQuestState(Q00498_IncarnationOfJealousyPellineSolo.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
case TEMPLATE_ID_SOLO_90:
{
qs.setCond(2, true);
player.addExpAndSp(SOLO_BASE_EXP_90 + getRandom(SOLO_RAND_EXP_90), SOLO_BASE_SP_90 + getRandom(SOLO_RAND_SP_90));
break;
}
break;
}
case TEMPLATE_ID_SOLO_95:
{
final QuestState qs = player.getQuestState(Q00499_IncarnationOfGluttonyKaliosSolo.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
case TEMPLATE_ID_SOLO_95:
{
qs.setCond(2, true);
player.addExpAndSp(SOLO_BASE_EXP_95 + getRandom(SOLO_RAND_EXP_95), SOLO_BASE_SP_95 + getRandom(SOLO_RAND_SP_95));
break;
}
break;
}
case TEMPLATE_ID_GROUP_85:
{
final QuestState qs = player.getQuestState(Q00494_IncarnationOfGreedZellakaGroup.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
qs.setCond(2, true);
}
break;
}
case TEMPLATE_ID_GROUP_90:
{
final QuestState qs = player.getQuestState(Q00495_IncarnationOfJealousyPellineGroup.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
qs.setCond(2, true);
}
break;
}
case TEMPLATE_ID_GROUP_95:
{
final QuestState qs = player.getQuestState(Q00496_IncarnationOfGluttonyKaliosGroup.class.getSimpleName());
if ((qs != null) && (qs.getState() == State.STARTED) && qs.isCond(1))
{
qs.setCond(2, true);
}
break;
}
}
});
}
instance.finishInstance();
}
}
@@ -475,8 +479,6 @@ public final class KartiasLabyrinth extends AbstractInstance
instance.setParameter("BOSS_CAN_ESCAPE", false);
npc.setScriptValue(1);
npc.broadcastSay(ChatType.NPC_SHOUT, NpcStringId.NOT_BAD_FOR_A_BUNCH_OF_HUMANS_I_M_LEAVING);
npc.disableCoreAI(true);
addMoveToDesire(npc, instance.getTemplateParameters().getLocation("bossEscapeLoc1"), 23);
}
}
else
@@ -503,7 +505,6 @@ public final class KartiasLabyrinth extends AbstractInstance
final Instance instance = character.getInstanceWorld();
if ((instance != null) && character.isPlayer())
{
// final L2PcInstance player = character.getActingPlayer();
switch (zone.getId())
{
case KARTIA_85_DETECT_1:
@@ -532,11 +533,6 @@ public final class KartiasLabyrinth extends AbstractInstance
}
break;
}
/*
* case KARTIA_85_TELEPORT_1: case KARTIA_90_TELEPORT_1: case KARTIA_95_TELEPORT_1: { if (instance.getParameters().getBoolean("TELEPORT_1_ENABLED", false)) { player.teleToLocation(instance.getTemplateParameters().getLocation("teleportZone1_loc")); } break; } case
* KARTIA_85_TELEPORT_2: case KARTIA_90_TELEPORT_2: case KARTIA_95_TELEPORT_2: { if (instance.getParameters().getBoolean("TELEPORT_2_ENABLED", false)) { player.teleToLocation(instance.getTemplateParameters().getLocation("teleportZone2_loc")); } break; } case KARTIA_85_TELEPORT_3:
* case KARTIA_90_TELEPORT_3: case KARTIA_95_TELEPORT_3: { if (instance.getParameters().getBoolean("TELEPORT_3_ENABLED", false)) { player.teleToLocation(instance.getTemplateParameters().getLocation("teleportZone3_loc")); } break; }
*/
}
}
return super.onEnterZone(character, zone);
@@ -546,31 +542,15 @@ public final class KartiasLabyrinth extends AbstractInstance
public void onMoveFinished(L2Npc npc)
{
final Instance instance = npc.getInstanceWorld();
if (instance != null)
if ((instance != null) && CommonUtil.contains(PRISONERS, npc.getId()))
{
if (CommonUtil.contains(PRISONERS, npc.getId()))
if (npc.isScriptValue(0))
{
if (npc.isScriptValue(0))
{
npc.setScriptValue(1);
final Location moveTo = new Location(npc.getX() + getRandom(-500, 500), npc.getY() + getRandom(-500, 500), npc.getZ());
addMoveToDesire(npc, moveTo, 23);
}
else
{
npc.deleteMe();
}
final Location moveTo = new Location(npc.getX() + getRandom(-200, 200), npc.getY() + getRandom(-200, 200), npc.getZ());
addMoveToDesire(npc, moveTo, 23);
}
else if (npc.isScriptValue(1))
else
{
npc.setScriptValue(2);
addMoveToDesire(npc, instance.getTemplateParameters().getLocation("bossEscapeLoc2"), 23);
}
else if (npc.isScriptValue(2))
{
instance.setParameter("MINIBOSS_SURVIVED", true);
instance.openCloseDoor(instance.getTemplateParameters().getInt("thirdDoorId"), true);
instance.setStatus(3); // Used for notify helper's AI
npc.deleteMe();
}
}
@@ -585,7 +565,7 @@ public final class KartiasLabyrinth extends AbstractInstance
{
final Location moveTo = new Location(npc.getX() + getRandom(-100, 100), npc.getY() + getRandom(-100, 100), npc.getZ());
npc.setRandomWalking(true);
addMoveToDesire(npc, moveTo, 0);
addMoveToDesire(npc, moveTo, 6);
}
}
@@ -608,6 +588,11 @@ public final class KartiasLabyrinth extends AbstractInstance
npc.setTargetable(false);
npc.setIsInvul(true);
}
else if (CommonUtil.contains(MONSTERS, npc.getId()) || CommonUtil.contains(MINI_BOSSES, npc.getId()))
{
npc.setTargetable(false);
npc.setIsInvul(true);
}
}
return super.onSpawn(npc);
}
@@ -632,14 +617,16 @@ public final class KartiasLabyrinth extends AbstractInstance
showOnScreenMsg(instance, NpcStringId.STAGE_S1, ExShowScreenMessage.TOP_CENTER, 5000, true, Integer.toString(stage));
moveMonsters(instance.spawnGroup("ROOM1_STAGE1_WAVE1"));
param.set("WAVE", 2);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 2:
{
moveMonsters(instance.spawnGroup("ROOM1_STAGE1_WAVE2"));
param.set("WAVE", 3);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 3:
@@ -662,14 +649,16 @@ public final class KartiasLabyrinth extends AbstractInstance
showOnScreenMsg(instance, NpcStringId.STAGE_S1, ExShowScreenMessage.TOP_CENTER, 5000, true, Integer.toString(stage));
moveMonsters(instance.spawnGroup("ROOM1_STAGE2_WAVE1"));
param.set("WAVE", 2);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 2:
{
moveMonsters(instance.spawnGroup("ROOM1_STAGE2_WAVE2"));
param.set("WAVE", 3);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 3:
@@ -692,14 +681,16 @@ public final class KartiasLabyrinth extends AbstractInstance
showOnScreenMsg(instance, NpcStringId.STAGE_S1, ExShowScreenMessage.TOP_CENTER, 5000, true, Integer.toString(stage));
moveMonsters(instance.spawnGroup("ROOM1_STAGE3_WAVE1"));
param.set("WAVE", 2);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 2:
{
moveMonsters(instance.spawnGroup("ROOM1_STAGE3_WAVE2"));
param.set("WAVE", 3);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 3:
@@ -744,7 +735,7 @@ public final class KartiasLabyrinth extends AbstractInstance
}
break;
}
case 4:
case 4: // Only used in group version of instance.
{
switch (wave)
{
@@ -753,14 +744,16 @@ public final class KartiasLabyrinth extends AbstractInstance
showOnScreenMsg(instance, NpcStringId.STAGE_S1, ExShowScreenMessage.TOP_CENTER, 5000, true, Integer.toString(stage));
moveMonsters(instance.spawnGroup("ROOM1_STAGE4_WAVE1"));
param.set("WAVE", 2);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 2:
{
moveMonsters(instance.spawnGroup("ROOM1_STAGE4_WAVE2"));
param.set("WAVE", 3);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 3:
@@ -774,7 +767,7 @@ public final class KartiasLabyrinth extends AbstractInstance
}
break;
}
case 5:
case 5: // Only used in group version of instance.
{
switch (wave)
{
@@ -783,7 +776,8 @@ public final class KartiasLabyrinth extends AbstractInstance
showOnScreenMsg(instance, NpcStringId.STAGE_S1, ExShowScreenMessage.TOP_CENTER, 5000, true, Integer.toString(stage));
moveMonsters(instance.spawnGroup("ROOM1_STAGE5_WAVE1"));
param.set("WAVE", 2);
getTimers().addTimer("NEXT_WAVE_DELAY", 30000, n -> manageProgressInInstance(instance));
getTimers().addTimer("NEXT_WAVE_DELAY", WAVE_DEALY, n -> manageProgressInInstance(instance));
getTimers().addTimer("MONITOR_WAVE", WAVE_MONITOR_DELAY, n -> manageWaves(instance));
break;
}
case 2:
@@ -815,8 +809,7 @@ public final class KartiasLabyrinth extends AbstractInstance
}
else if (room == 2)
{
instance.getParameters().set("TELEPORT_1_ENABLED", false);
instance.setParameter("BOSS_CAN_ESCAPE", true);
instance.setParameter("BOSS_CAN_ESCAPE", false);
instance.setParameter("BOSS_KILL_OPEN_DOOR", true);
instance.spawnGroup("ROOM2_STAGE1_WAVE1");
instance.openCloseDoor(instance.getTemplateParameters().getInt("secondDoorId"), true);
@@ -909,24 +902,23 @@ public final class KartiasLabyrinth extends AbstractInstance
private void moveMonsters(List<L2Npc> monsterList)
{
int delay = 500;
for (L2Npc npc : monsterList)
for (L2Npc monster : monsterList)
{
final Instance world = npc.getInstanceWorld();
if (npc.isAttackable() && (world != null))
final Instance world = monster.getInstanceWorld();
if (monster.isAttackable() && (world != null))
{
if (world.getParameters().getInt("ROOM", 1) <= 2)
{
npc.setRandomWalking(false);
npc.setTargetable(false);
getTimers().addTimer("MOVE_TO_MIDDLE", delay, npc, null);
monster.setRandomWalking(false);
getTimers().addTimer("MOVE_TO_MIDDLE", delay, monster, null);
delay += 250;
}
else if (world.getParameters().getInt("ROOM", 1) == 3)
{
onTimerEvent("MOVE_TO_MIDDLE", null, npc, null);
onTimerEvent("MOVE_TO_MIDDLE", null, monster, null);
}
((L2Attackable) npc).setCanReturnToSpawnPoint(false);
npc.initSeenCreatures();
((L2Attackable) monster).setCanReturnToSpawnPoint(false);
monster.initSeenCreatures();
}
}
}
@@ -937,10 +929,19 @@ public final class KartiasLabyrinth extends AbstractInstance
final L2Npc npc = (L2Npc) event.getSeer();
final Instance world = npc.getInstanceWorld();
if ((world != null) && creature.isPlayer() && npc.isScriptValue(0))
if ((world != null) && (creature.isPlayer() || creature.getInstanceType().isType(InstanceType.FriendlyNpcInstance)) && npc.isScriptValue(0))
{
npc.setScriptValue(1);
addAttackDesire(npc, creature);
final double distance = npc.calculateDistance(creature, false, false);
if ((distance < 450) && !CommonUtil.contains(PRISONERS, creature.getId()))
{
npc.setTargetable(true);
npc.setIsInvul(false);
npc.setScriptValue(1);
WalkingManager.getInstance().cancelMoving(npc);
((L2MonsterInstance) npc).addDamageHate(creature, 0, 1000);
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_ACTIVE);
addAttackDesire(npc, creature);
}
}
}

View File

@@ -33,6 +33,8 @@ public class Q00494_IncarnationOfGreedZellakaGroup extends Quest
private static final int KARTIA_RESEARCHER = 33647;
// Item
private static final int DIMENSION_KEEPER_BLUE_BOX = 34927;
// Boss
private static final int BOSS = 25882; // Zellaka (Group 85)
// Misc
private static final int MIN_LEVEL = 85;
private static final int MAX_LEVEL = 89;
@@ -42,6 +44,7 @@ public class Q00494_IncarnationOfGreedZellakaGroup extends Quest
super(494);
addStartNpc(KARTIA_RESEARCHER);
addTalkId(KARTIA_RESEARCHER);
addKillId(BOSS);
addCondLevel(MIN_LEVEL, MAX_LEVEL, "33647-00.htm");
}
@@ -115,4 +118,21 @@ public class Q00494_IncarnationOfGreedZellakaGroup extends Quest
}
return htmltext;
}
@Override
public String onKill(L2Npc npc, L2PcInstance player, boolean isSummon)
{
executeForEachPlayer(player, npc, isSummon, true, false);
return super.onKill(npc, player, isSummon);
}
@Override
public void actionForEachPlayer(L2PcInstance player, L2Npc npc, boolean isSummon)
{
final QuestState qs = getQuestState(player, false);
if ((qs != null) && qs.isCond(1))
{
qs.setCond(2, true);
}
}
}

View File

@@ -33,6 +33,8 @@ public class Q00495_IncarnationOfJealousyPellineGroup extends Quest
private static final int KARTIA_RESEARCHER = 33647;
// Item
private static final int DIMENSION_KEEPER_RED_BOX = 34928;
// Boss
private static final int BOSS = 25883; // Pelline (Group 90)
// Misc
private static final int MIN_LEVEL = 90;
private static final int MAX_LEVEL = 94;
@@ -42,6 +44,7 @@ public class Q00495_IncarnationOfJealousyPellineGroup extends Quest
super(495);
addStartNpc(KARTIA_RESEARCHER);
addTalkId(KARTIA_RESEARCHER);
addKillId(BOSS);
addCondLevel(MIN_LEVEL, MAX_LEVEL, "33647-00.htm");
}
@@ -115,4 +118,21 @@ public class Q00495_IncarnationOfJealousyPellineGroup extends Quest
}
return htmltext;
}
@Override
public String onKill(L2Npc npc, L2PcInstance player, boolean isSummon)
{
executeForEachPlayer(player, npc, isSummon, true, false);
return super.onKill(npc, player, isSummon);
}
@Override
public void actionForEachPlayer(L2PcInstance player, L2Npc npc, boolean isSummon)
{
final QuestState qs = getQuestState(player, false);
if ((qs != null) && qs.isCond(1))
{
qs.setCond(2, true);
}
}
}

View File

@@ -33,6 +33,8 @@ public class Q00496_IncarnationOfGluttonyKaliosGroup extends Quest
private static final int KARTIA_RESEARCHER = 33647;
// Item
private static final int DIMENSION_KEEPER_GOLDEN_BOX = 34929;
// Boss
private static final int BOSS = 25884; // Kalios (Group 95)
// Misc
private static final int MIN_LEVEL = 95;
private static final int MAX_LEVEL = 99;
@@ -42,6 +44,7 @@ public class Q00496_IncarnationOfGluttonyKaliosGroup extends Quest
super(496);
addStartNpc(KARTIA_RESEARCHER);
addTalkId(KARTIA_RESEARCHER);
addKillId(BOSS);
addCondLevel(MIN_LEVEL, MAX_LEVEL, "33647-00.htm");
}
@@ -115,4 +118,21 @@ public class Q00496_IncarnationOfGluttonyKaliosGroup extends Quest
}
return htmltext;
}
@Override
public String onKill(L2Npc npc, L2PcInstance player, boolean isSummon)
{
executeForEachPlayer(player, npc, isSummon, true, false);
return super.onKill(npc, player, isSummon);
}
@Override
public void actionForEachPlayer(L2PcInstance player, L2Npc npc, boolean isSummon)
{
final QuestState qs = getQuestState(player, false);
if ((qs != null) && qs.isCond(1))
{
qs.setCond(2, true);
}
}
}

View File

@@ -33,6 +33,8 @@ public class Q00497_IncarnationOfGreedZellakaSolo extends Quest
private static final int KARTIA_RESEARCHER = 33647;
// Item
private static final int DIMENSION_TRAVELERS_BLUE_BOX = 34930;
// Boss
private static final int BOSS = 19253; // Zellaka (Solo 85)
// Misc
private static final int MIN_LEVEL = 85;
private static final int MAX_LEVEL = 89;
@@ -42,6 +44,7 @@ public class Q00497_IncarnationOfGreedZellakaSolo extends Quest
super(497);
addStartNpc(KARTIA_RESEARCHER);
addTalkId(KARTIA_RESEARCHER);
addKillId(BOSS);
addCondLevel(MIN_LEVEL, MAX_LEVEL, "33647-00.htm");
}
@@ -115,4 +118,15 @@ public class Q00497_IncarnationOfGreedZellakaSolo extends Quest
}
return htmltext;
}
@Override
public String onKill(L2Npc npc, L2PcInstance player, boolean isSummon)
{
final QuestState qs = getQuestState(player, false);
if ((qs != null) && qs.isCond(1))
{
qs.setCond(2, true);
}
return super.onKill(npc, player, isSummon);
}
}

View File

@@ -33,6 +33,8 @@ public class Q00498_IncarnationOfJealousyPellineSolo extends Quest
private static final int KARTIA_RESEARCHER = 33647;
// Item
private static final int DIMENSION_TRAVELERS_RED_BOX = 34931;
// Boss
private static final int BOSS = 19254; // Pelline (Solo 90)
// Misc
private static final int MIN_LEVEL = 90;
private static final int MAX_LEVEL = 94;
@@ -42,6 +44,7 @@ public class Q00498_IncarnationOfJealousyPellineSolo extends Quest
super(498);
addStartNpc(KARTIA_RESEARCHER);
addTalkId(KARTIA_RESEARCHER);
addKillId(BOSS);
addCondLevel(MIN_LEVEL, MAX_LEVEL, "33647-00.htm");
}
@@ -115,4 +118,15 @@ public class Q00498_IncarnationOfJealousyPellineSolo extends Quest
}
return htmltext;
}
@Override
public String onKill(L2Npc npc, L2PcInstance player, boolean isSummon)
{
final QuestState qs = getQuestState(player, false);
if ((qs != null) && qs.isCond(1))
{
qs.setCond(2, true);
}
return super.onKill(npc, player, isSummon);
}
}

View File

@@ -33,6 +33,8 @@ public class Q00499_IncarnationOfGluttonyKaliosSolo extends Quest
private static final int KARTIA_RESEARCHER = 33647;
// Item
private static final int DIMENSION_TRAVELERS_GOLDEN_BOX = 34932;
// Boss
private static final int BOSS = 19255; // Kalios (Solo 95)
// Misc
private static final int MIN_LEVEL = 95;
private static final int MAX_LEVEL = 99;
@@ -42,6 +44,7 @@ public class Q00499_IncarnationOfGluttonyKaliosSolo extends Quest
super(499);
addStartNpc(KARTIA_RESEARCHER);
addTalkId(KARTIA_RESEARCHER);
addKillId(BOSS);
addCondLevel(MIN_LEVEL, MAX_LEVEL, "33647-00.htm");
}
@@ -115,4 +118,15 @@ public class Q00499_IncarnationOfGluttonyKaliosSolo extends Quest
}
return htmltext;
}
@Override
public String onKill(L2Npc npc, L2PcInstance player, boolean isSummon)
{
final QuestState qs = getQuestState(player, false);
if ((qs != null) && qs.isCond(1))
{
qs.setCond(2, true);
}
return super.onKill(npc, player, isSummon);
}
}

View File

@@ -625,7 +625,7 @@
<param name="MoveAroundSocial" value="120" />
<param name="MoveAroundSocial1" value="120" />
<skill name="Skill01_ID" id="14911" level="1" />
<skill name="Skill03_ID" id="14917" level="1" />
<skill name="Skill02_ID" id="14917" level="1" />
<param name="Attack_BoostValue" value="131" />
</parameters>
<race>UNDEAD</race>
@@ -1999,7 +1999,7 @@
<race>DEMONIC</race>
<sex>MALE</sex>
<stats str="88" int="79" dex="55" wit="78" con="82" men="78">
<vitals hp="689833" hpRegen="8.5" mp="19524" mpRegen="30" />
<vitals hp="1002466" hpRegen="8.5" mp="19524" mpRegen="30" />
<speed>
<walk ground="34" />
<run ground="200" />
@@ -2044,7 +2044,7 @@
<race>DEMONIC</race>
<sex>MALE</sex>
<stats str="88" int="79" dex="55" wit="78" con="82" men="78">
<vitals hp="750827" hpRegen="8.5" mp="21324" mpRegen="30" />
<vitals hp="1636653" hpRegen="8.5" mp="21324" mpRegen="30" />
<speed>
<walk ground="60" />
<run ground="200" />
@@ -2091,7 +2091,7 @@
<race>DEMONIC</race>
<sex>MALE</sex>
<stats str="88" int="79" dex="55" wit="78" con="82" men="78">
<vitals hp="1025316" hpRegen="8.5" mp="23174" mpRegen="30" />
<vitals hp="2979979" hpRegen="8.5" mp="23174" mpRegen="30" />
<speed>
<walk ground="50" />
<run ground="200" />

View File

@@ -10,7 +10,7 @@
<acquire exp="2541011" sp="95136" />
<mpReward value="53" type="DIFF" ticks="10" affects="PARTY" />
<stats str="164" int="188" dex="48" wit="71" con="111" men="149">
<vitals hp="745704" hpRegen="8.5" mp="22800" mpRegen="30" />
<vitals hp="8172432" hpRegen="8.5" mp="22800" mpRegen="30" />
<attack physical="45027.4086463771" magical="7933.39078546243" attackSpeed="253" range="40" type="SWORD" distance="80" width="120" random="10" critical="4" accuracy="5" />
<defence physical="3607.74748074426" magical="2081.35112045963" />
<attribute>
@@ -3556,7 +3556,7 @@
<equipment rhand="5800" lhand="5799" /> <!-- Nephilim Lord / Nephilim Lord -->
<mpReward value="20" type="PER" ticks="10" affects="PARTY" />
<stats str="164" int="188" dex="55" wit="78" con="111" men="149">
<vitals hp="745704" hpRegen="8.5" mp="22800" mpRegen="30" />
<vitals hp="4540240" hpRegen="8.5" mp="22800" mpRegen="30" />
<speed>
<walk ground="56" />
<run ground="180" />
@@ -3605,10 +3605,10 @@
</parameters>
<race>DEMONIC</race>
<sex>MALE</sex>
<acquire exp="2658577152" sp="638058" />
<acquire exp="4570101620" sp="5484121" />
<mpReward value="20" type="PER" ticks="10" affects="PARTY" />
<stats str="164" int="188" dex="55" wit="78" con="111" men="149">
<vitals hp="1341871" hpRegen="8.5" mp="1846" mpRegen="3" />
<vitals hp="3194997" hpRegen="8.5" mp="1846" mpRegen="3" />
<speed>
<walk ground="34" />
<run ground="200" />
@@ -3715,10 +3715,10 @@
</parameters>
<race>DEMONIC</race>
<sex>MALE</sex>
<acquire exp="2969270892" sp="712625" raidPoints="7" />
<acquire exp="12716516673" sp="16912967" raidPoints="7" />
<mpReward value="20" type="PER" ticks="10" affects="PARTY" />
<stats str="164" int="188" dex="55" wit="78" con="111" men="149">
<vitals hp="1468941" hpRegen="8.5" mp="2023" mpRegen="3" />
<vitals hp="10492650" hpRegen="8.5" mp="2023" mpRegen="3" />
<speed>
<walk ground="60" />
<run ground="200" />
@@ -3827,10 +3827,10 @@
</parameters>
<race>DEMONIC</race>
<sex>MALE</sex>
<acquire exp="3297130032" sp="791311" raidPoints="7" />
<acquire exp="35177164807" sp="70354390" raidPoints="7" />
<mpReward value="20" type="PER" ticks="10" affects="PARTY" />
<stats str="164" int="188" dex="55" wit="78" con="111" men="149">
<vitals hp="1644810" hpRegen="8.5" mp="2205" mpRegen="3" />
<vitals hp="15665180" hpRegen="8.5" mp="2205" mpRegen="3" />
<speed>
<walk ground="50" />
<run ground="200" />

View File

@@ -1090,7 +1090,7 @@
<!-- Glory Days confirmed -->
<!-- Drags the selected target and enemies near the target to the user's location. -->
<icon>icon.skill10016</icon>
<operateType>A2</operateType>
<operateType>A1</operateType>
<castRange>600</castRange>
<hitTime>500</hitTime>
<coolTime>1000</coolTime>
@@ -1112,8 +1112,7 @@
<affectLimit>10-10</affectLimit>
<isDebuff>true</isDebuff>
<targetType>ENEMY</targetType>
<affectScope>RANGE</affectScope>
<affectObject>NOT_FRIEND</affectObject>
<affectScope>SINGLE</affectScope>
<effects>
<effect name="PullBack">
<speed>600</speed>
@@ -1128,7 +1127,7 @@
<!-- Glory Days confirmed -->
<!-- Drags the selected target and enemies near the target to the user's location. -->
<icon>icon.skill10016</icon>
<operateType>A2</operateType>
<operateType>A1</operateType>
<castRange>600</castRange>
<hitTime>500</hitTime>
<coolTime>1000</coolTime>
@@ -1150,8 +1149,7 @@
<affectLimit>10-10</affectLimit>
<isDebuff>true</isDebuff>
<targetType>ENEMY</targetType>
<affectScope>RANGE</affectScope>
<affectObject>NOT_FRIEND</affectObject>
<affectScope>SINGLE</affectScope>
<effects>
<effect name="PullBack">
<speed>600</speed>
@@ -1166,7 +1164,7 @@
<!-- Glory Days confirmed -->
<!-- Drags the selected target and enemies near the target to the user's location. -->
<icon>icon.skill10016</icon>
<operateType>A2</operateType>
<operateType>A1</operateType>
<castRange>600</castRange>
<hitTime>500</hitTime>
<coolTime>1000</coolTime>
@@ -1188,8 +1186,7 @@
<affectLimit>10-10</affectLimit>
<isDebuff>true</isDebuff>
<targetType>ENEMY</targetType>
<affectScope>RANGE</affectScope>
<affectObject>NOT_FRIEND</affectObject>
<affectScope>SINGLE</affectScope>
<effects>
<effect name="PullBack">
<speed>600</speed>
@@ -1351,7 +1348,7 @@
<fanRange>0;0;150;180</fanRange>
<abnormalVisualEffect>STUN</abnormalVisualEffect>
<isDebuff>true</isDebuff>
<targetType>SELF</targetType>
<targetType>ENEMY</targetType>
<affectScope>SINGLE</affectScope>
<effects>
<effect name="PhysicalAttack">
@@ -1387,7 +1384,7 @@
<fanRange>0;0;150;180</fanRange>
<abnormalVisualEffect>STUN</abnormalVisualEffect>
<isDebuff>true</isDebuff>
<targetType>SELF</targetType>
<targetType>ENEMY</targetType>
<affectScope>SINGLE</affectScope>
<effects>
<effect name="PhysicalAttack">
@@ -1423,7 +1420,7 @@
<fanRange>0;0;150;180</fanRange>
<abnormalVisualEffect>STUN</abnormalVisualEffect>
<isDebuff>true</isDebuff>
<targetType>SELF</targetType>
<targetType>ENEMY</targetType>
<affectScope>SINGLE</affectScope>
<effects>
<effect name="PhysicalAttack">
@@ -2709,7 +2706,6 @@
<isDebuff>true</isDebuff>
<targetType>TARGET</targetType>
<affectScope>SINGLE</affectScope>
<affectObject>NOT_FRIEND</affectObject>
<effects>
<effect name="TargetMe" />
<effect name="GetAgro" />
@@ -2738,7 +2734,6 @@
<isDebuff>true</isDebuff>
<targetType>TARGET</targetType>
<affectScope>SINGLE</affectScope>
<affectObject>NOT_FRIEND</affectObject>
<effects>
<effect name="TargetMe" />
<effect name="GetAgro" />
@@ -2767,7 +2762,6 @@
<isDebuff>true</isDebuff>
<targetType>TARGET</targetType>
<affectScope>SINGLE</affectScope>
<affectObject>NOT_FRIEND</affectObject>
<effects>
<effect name="TargetMe" />
<effect name="GetAgro" />
@@ -2925,11 +2919,6 @@
<targetType>TARGET</targetType>
<affectScope>RANGE</affectScope>
<affectObject>FRIEND</affectObject>
<effects>
<effect name="HealPercent">
<power>40</power>
</effect>
</effects>
</skill>
<skill id="14899" toLevel="1" name="Elise' Radiant Heal">
<!-- Glory Days confirmed -->
@@ -2950,8 +2939,8 @@
<targetType>TARGET</targetType>
<affectScope>SINGLE</affectScope>
<effects>
<effect name="HpCpHeal">
<power>1488</power>
<effect name="HealPercent">
<power>20</power>
</effect>
</effects>
</skill>