From d991c3d6d796328846d09e24cd71f80cfc2471d8 Mon Sep 17 00:00:00 2001 From: Skold177 <113406182+Skold177@users.noreply.github.com> Date: Sat, 21 Feb 2026 00:34:33 -0500 Subject: [PATCH] [lua] [sql] King Vinegarroon Updates KV with a capture from retail --- scripts/enum/mob_skill.lua | 1 + scripts/zones/Western_Altepa_Desert/Zone.lua | 10 ++----- .../mobs/King_Vinegarroon.lua | 29 +++++++++++++++---- sql/mob_spawn_points.sql | 2 +- 4 files changed, 29 insertions(+), 13 deletions(-) diff --git a/scripts/enum/mob_skill.lua b/scripts/enum/mob_skill.lua index b3176b26c0e..a54a0d59f6b 100644 --- a/scripts/enum/mob_skill.lua +++ b/scripts/enum/mob_skill.lua @@ -86,6 +86,7 @@ xi.mobSkill = VELOCIOUS_BLADE = 347, -- Mammet-800 + DEATH_SCISSORS = 353, WILD_RAGE = 354, EARTH_POUNDER = 355, diff --git a/scripts/zones/Western_Altepa_Desert/Zone.lua b/scripts/zones/Western_Altepa_Desert/Zone.lua index 886ce798404..ffa3fd99fee 100644 --- a/scripts/zones/Western_Altepa_Desert/Zone.lua +++ b/scripts/zones/Western_Altepa_Desert/Zone.lua @@ -53,18 +53,16 @@ zoneObject.onZoneWeatherChange = function(weather) if kvMob then if weather == xi.weather.DUST_STORM or weather == xi.weather.SAND_STORM then - DisallowRespawn(ID.mob.KING_VINEGARROON, false) -- Allow respawn. - -- Check for respawn. if not kvMob:isSpawned() and kvMob:getRespawnTime() == 0 then if - (weather == xi.weather.DUST_STORM and math.random(1, 100) <= 10) or + (weather == xi.weather.DUST_STORM and math.random(1, 100) <= 50) or weather == xi.weather.SAND_STORM then - SpawnMob(ID.mob.KING_VINEGARROON) + DisallowRespawn(ID.mob.KING_VINEGARROON, false) -- Allow respawn. end end @@ -86,14 +84,12 @@ zoneObject.onZoneWeatherChange = function(weather) } if dahuValidWeather[weather] then - DisallowRespawn(ID.mob.DAHU, false) -- Allow respawn. - -- Spawn if respawn is up if not dahu:isSpawned() and dahu:getRespawnTime() == 0 then - SpawnMob(ID.mob.DAHU) + DisallowRespawn(ID.mob.DAHU, false) -- Allow respawn. end else DisallowRespawn(ID.mob.DAHU, true) -- Disallow respawn. diff --git a/scripts/zones/Western_Altepa_Desert/mobs/King_Vinegarroon.lua b/scripts/zones/Western_Altepa_Desert/mobs/King_Vinegarroon.lua index 46504d3a634..5215ff396dd 100644 --- a/scripts/zones/Western_Altepa_Desert/mobs/King_Vinegarroon.lua +++ b/scripts/zones/Western_Altepa_Desert/mobs/King_Vinegarroon.lua @@ -63,19 +63,30 @@ local function mobRegen(mob) local hour = VanadielHour() if hour >= 6 and hour <= 20 then - mob:setMod(xi.mod.REGEN, 125) + mob:setMod(xi.mod.REGEN, 150) else - mob:setMod(xi.mod.REGEN, 250) + mob:setMod(xi.mod.REGEN, 300) end end entity.onMobInitialize = function(mob) xi.mob.updateNMSpawnPoint(mob) - mob:setRespawnTime(math.random(75600, 86400)) -- 21 to 24 hours + mob:setRespawnTime(75600) -- Opens 21 hours after being defeated, or despawning. + + mob:addImmunity(xi.immunity.SILENCE) + mob:addImmunity(xi.immunity.PETRIFY) + mob:addImmunity(xi.immunity.BIND) + mob:addImmunity(xi.immunity.LIGHT_SLEEP) + mob:addImmunity(xi.immunity.DARK_SLEEP) mob:setMobMod(xi.mobMod.ADD_EFFECT, 1) end +entity.onMobSpawn = function(mob) + mob:setMod(xi.mod.REGAIN, 35) + mob:setMobMod(xi.mobMod.BASE_DAMAGE_MULTIPLIER, 250) +end + entity.onAdditionalEffect = function(mob, target, damage) return xi.mob.onAddEffect(mob, target, damage, xi.mob.ae.PETRIFY, { chance = 100 }) end @@ -117,6 +128,14 @@ entity.onMobFight = function(mob, target) mobRegen(mob) end +-- Table of single target skills KV will use after an AOE TP Move +local skillTable = +{ + [1] = xi.mobSkill.DEATH_SCISSORS, + [2] = xi.mobSkill.CRITICAL_BITE, + [3] = xi.mobSkill.VENOM_STING_1, +} + entity.onMobSkillTarget = function(target, mob, mobskill) if mobskill:isAoE() then -- Chance for draw in to be single target or alliance @@ -140,7 +159,7 @@ entity.onMobSkillTarget = function(target, mob, mobskill) end -- KV always does an AOE TP move followed by a single target TP move - mob:useMobAbility(({ 353, 350, 719, 720 })[math.random(1, 4)]) + mob:useMobAbility(skillTable[math.random(1, #skillTable)]) end end @@ -152,7 +171,7 @@ end entity.onMobDespawn = function(mob) xi.mob.updateNMSpawnPoint(mob) - mob:setRespawnTime(math.random(75600, 86400)) -- 21 to 24 hours + mob:setRespawnTime(75600) -- Opens 21 hours after being defeated, or despawning. end return entity diff --git a/sql/mob_spawn_points.sql b/sql/mob_spawn_points.sql index 1609eb83b4d..f3485c3a778 100644 --- a/sql/mob_spawn_points.sql +++ b/sql/mob_spawn_points.sql @@ -45248,7 +45248,7 @@ INSERT INTO `mob_spawn_points` VALUES (17289571,0,'Fallen_Knight','Fallen Knight INSERT INTO `mob_spawn_points` VALUES (17289572,0,'Lich','Lich',25,49,53,-272.617,-0.332,-601.923,127); INSERT INTO `mob_spawn_points` VALUES (17289573,0,'Tulwar_Scorpion','Tulwar Scorpion',11,53,56,-207.000,-0.200,-670.912,127); INSERT INTO `mob_spawn_points` VALUES (17289574,0,'Earth_Elemental','Earth Elemental',9,56,58,-241.884,-0.612,-672.500,40); -INSERT INTO `mob_spawn_points` VALUES (17289575,0,'King_Vinegarroon','King Vinegarroon',26,80,85,-239.000,-0.226,-650.000,11); +INSERT INTO `mob_spawn_points` VALUES (17289575,0,'King_Vinegarroon','King Vinegarroon',26,80,80,-239.000,-0.226,-650.000,11); INSERT INTO `mob_spawn_points` VALUES (17289576,0,'Desert_Beetle','Desert Beetle',12,47,51,-451.761,-0.547,-683.411,127); INSERT INTO `mob_spawn_points` VALUES (17289577,0,'Desert_Beetle','Desert Beetle',12,47,51,-519.456,-0.383,-516.895,92); INSERT INTO `mob_spawn_points` VALUES (17289578,0,'Cactuar','Cactuar',10,48,53,-478.142,-0.457,-596.091,127);