Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,7 @@ Makefile
**/CMakeFiles
cmake_install.cmake
/cmake-**/**
.cpm-cache/

# ignore servers
*-server
Expand Down
2 changes: 1 addition & 1 deletion documentation/ai_agents/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* This post was written by hand, zhuzhed up by AI, and then manually proofread, fact-checked, and
polished by hand, exactly how it should be.
Even with careful oversight, I still had to alter the tone, correct statements, remove ligatures,
Even with careful oversight, I still had to alter the tone, correct statements, remove ligatures (→, etc.),
remove outright lies and hallucinations, replace the telltale "em dashes"'s that AI is so fond
of (—), etc.
Expand Down
18 changes: 9 additions & 9 deletions scripts/battlefields/Boneyard_Gully/head_wind.lua
Original file line number Diff line number Diff line change
Expand Up @@ -49,20 +49,20 @@ local skillchainData =
-- Shikaree X initiated
[ID.mob.SHIKAREE_X_HW] =
{
-- All shikaree are alive: X Evisceration Y Vorpal Scythe Z Impulse Drive
-- All shikaree are alive: X Evisceration -> Y Vorpal Scythe -> Z Impulse Drive
[allAlive] =
{
{ mobId = ID.mob.SHIKAREE_X_HW, skill = xi.mobSkill.EVISCERATION },
{ mobId = ID.mob.SHIKAREE_Y_HW, skill = xi.mobSkill.VORPAL_SCYTHE },
{ mobId = ID.mob.SHIKAREE_Z_HW, skill = xi.mobSkill.IMPULSE_DRIVE },
},
-- Shikaree X and Y are alive: X Evisceration Y Vorpal Scythe
-- Shikaree X and Y are alive: X Evisceration -> Y Vorpal Scythe
[ID.mob.SHIKAREE_Y_HW] =
{
{ mobId = ID.mob.SHIKAREE_X_HW, skill = xi.mobSkill.EVISCERATION },
{ mobId = ID.mob.SHIKAREE_Y_HW, skill = xi.mobSkill.VORPAL_SCYTHE },
},
-- Shikaree X and Z are alive: X Dancing Edge Z Penta Thrust
-- Shikaree X and Z are alive: X Dancing Edge -> Z Penta Thrust
[ID.mob.SHIKAREE_Z_HW] =
{
{ mobId = ID.mob.SHIKAREE_X_HW, skill = xi.mobSkill.DANCING_EDGE },
Expand All @@ -73,20 +73,20 @@ local skillchainData =
-- Shikaree Y initiated
[ID.mob.SHIKAREE_Y_HW] =
{
-- All shikaree are alive: Y Guillotine X Shadowstitch Z Wheeling Thrust
-- All shikaree are alive: Y Guillotine -> X Shadowstitch -> Z Wheeling Thrust
[allAlive] =
{
{ mobId = ID.mob.SHIKAREE_Y_HW, skill = xi.mobSkill.GUILLOTINE_1 },
{ mobId = ID.mob.SHIKAREE_X_HW, skill = xi.mobSkill.SHADOWSTITCH },
{ mobId = ID.mob.SHIKAREE_Z_HW, skill = xi.mobSkill.WHEELING_THRUST },
},
-- Shikaree Y and X are alive: Y Spiral Hell X Shadowstitch
-- Shikaree Y and X are alive: Y Spiral Hell -> X Shadowstitch
[ID.mob.SHIKAREE_X_HW] =
{
{ mobId = ID.mob.SHIKAREE_Y_HW, skill = xi.mobSkill.SPIRAL_HELL },
{ mobId = ID.mob.SHIKAREE_X_HW, skill = xi.mobSkill.SHADOWSTITCH },
},
-- Shikaree Y and Z are alive: Y Spiral Hell Z Impulse Drive
-- Shikaree Y and Z are alive: Y Spiral Hell -> Z Impulse Drive
[ID.mob.SHIKAREE_Z_HW] =
{
{ mobId = ID.mob.SHIKAREE_Y_HW, skill = xi.mobSkill.SPIRAL_HELL },
Expand All @@ -97,20 +97,20 @@ local skillchainData =
-- Shikaree Z initiated
[ID.mob.SHIKAREE_Z_HW] =
{
-- All shikaree are alive: Z Skewer Y Spiral Hell X Evisceration
-- All shikaree are alive: Z Skewer -> Y Spiral Hell -> X Evisceration
[allAlive] =
{
{ mobId = ID.mob.SHIKAREE_Z_HW, skill = xi.mobSkill.SKEWER },
{ mobId = ID.mob.SHIKAREE_Y_HW, skill = xi.mobSkill.SPIRAL_HELL },
{ mobId = ID.mob.SHIKAREE_X_HW, skill = xi.mobSkill.EVISCERATION },
},
-- Shikaree Z and X are alive: Z Wheeling Thrust X Shark Bite
-- Shikaree Z and X are alive: Z Wheeling Thrust -> X Shark Bite
[ID.mob.SHIKAREE_X_HW] =
{
{ mobId = ID.mob.SHIKAREE_Z_HW, skill = xi.mobSkill.WHEELING_THRUST },
{ mobId = ID.mob.SHIKAREE_X_HW, skill = xi.mobSkill.SHARK_BITE },
},
-- Shikaree Z and Y are alive: Z Skewer Y Spiral Hell
-- Shikaree Z and Y are alive: Z Skewer -> Y Spiral Hell
[ID.mob.SHIKAREE_Y_HW] =
{
{ mobId = ID.mob.SHIKAREE_Z_HW, skill = xi.mobSkill.SKEWER },
Expand Down
18 changes: 9 additions & 9 deletions scripts/battlefields/Boneyard_Gully/requiem_of_sin.lua
Original file line number Diff line number Diff line change
Expand Up @@ -66,20 +66,20 @@ local skillchainData =
-- Shikaree X initiated
[ID.mob.SHIKAREE_X_ROS_TWT] =
{
-- All shikaree are alive: X Evisceration Y Vorpal Scythe Z Impulse Drive
-- All shikaree are alive: X Evisceration -> Y Vorpal Scythe -> Z Impulse Drive
[allAlive] =
{
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.EVISCERATION },
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.VORPAL_SCYTHE },
{ mobId = ID.mob.SHIKAREE_Z_ROS, skill = xi.mobSkill.IMPULSE_DRIVE },
},
-- Shikaree X and Y are alive: X Evisceration Y Vorpal Scythe
-- Shikaree X and Y are alive: X Evisceration -> Y Vorpal Scythe
[ID.mob.SHIKAREE_Y_ROS_TWT] =
{
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.EVISCERATION },
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.VORPAL_SCYTHE },
},
-- Shikaree X and Z are alive: X Dancing Edge Z Penta Thrust
-- Shikaree X and Z are alive: X Dancing Edge -> Z Penta Thrust
[ID.mob.SHIKAREE_Z_ROS] =
{
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.DANCING_EDGE },
Expand All @@ -90,20 +90,20 @@ local skillchainData =
-- Shikaree Y initiated
[ID.mob.SHIKAREE_Y_ROS_TWT] =
{
-- All shikaree are alive: Y Guillotine X Shadowstitch Z Wheeling Thrust
-- All shikaree are alive: Y Guillotine -> X Shadowstitch -> Z Wheeling Thrust
[allAlive] =
{
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.GUILLOTINE_1 },
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.SHADOWSTITCH },
{ mobId = ID.mob.SHIKAREE_Z_ROS, skill = xi.mobSkill.WHEELING_THRUST },
},
-- Shikaree Y and X are alive: Y Spiral Hell X Shadowstitch
-- Shikaree Y and X are alive: Y Spiral Hell -> X Shadowstitch
[ID.mob.SHIKAREE_X_ROS_TWT] =
{
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.SPIRAL_HELL },
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.SHADOWSTITCH },
},
-- Shikaree Y and Z are alive: Y Spiral Hell Z Impulse Drive
-- Shikaree Y and Z are alive: Y Spiral Hell -> Z Impulse Drive
[ID.mob.SHIKAREE_Z_ROS] =
{
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.SPIRAL_HELL },
Expand All @@ -114,20 +114,20 @@ local skillchainData =
-- Shikaree Z initiated
[ID.mob.SHIKAREE_Z_ROS] =
{
-- All shikaree are alive: Z Skewer Y Spiral Hell X Evisceration
-- All shikaree are alive: Z Skewer -> Y Spiral Hell -> X Evisceration
[allAlive] =
{
{ mobId = ID.mob.SHIKAREE_Z_ROS, skill = xi.mobSkill.SKEWER },
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.SPIRAL_HELL },
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.EVISCERATION },
},
-- Shikaree Z and X are alive: Z Wheeling Thrust X Shark Bite
-- Shikaree Z and X are alive: Z Wheeling Thrust -> X Shark Bite
[ID.mob.SHIKAREE_X_ROS_TWT] =
{
{ mobId = ID.mob.SHIKAREE_Z_ROS, skill = xi.mobSkill.WHEELING_THRUST },
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.SHARK_BITE },
},
-- Shikaree Z and Y are alive: Z Skewer Y Spiral Hell
-- Shikaree Z and Y are alive: Z Skewer -> Y Spiral Hell
[ID.mob.SHIKAREE_Y_ROS_TWT] =
{
{ mobId = ID.mob.SHIKAREE_Z_ROS, skill = xi.mobSkill.SKEWER },
Expand Down
4 changes: 2 additions & 2 deletions scripts/battlefields/Boneyard_Gully/tango_with_a_tracker.lua
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@ local msgOffsets =
-- Skillchain execution logic for 2 shikarees (Y and X only)
local skillchainData =
{
-- Shikaree X initiated: X Evisceration Y Vorpal Scythe
-- Shikaree X initiated: X Evisceration -> Y Vorpal Scythe
[ID.mob.SHIKAREE_X_ROS_TWT] =
{
{ mobId = ID.mob.SHIKAREE_X_ROS_TWT, skill = xi.mobSkill.EVISCERATION },
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.VORPAL_SCYTHE },
},

-- Shikaree Y initiated: Y Spiral Hell X Shadowstitch
-- Shikaree Y initiated: Y Spiral Hell -> X Shadowstitch
[ID.mob.SHIKAREE_Y_ROS_TWT] =
{
{ mobId = ID.mob.SHIKAREE_Y_ROS_TWT, skill = xi.mobSkill.SPIRAL_HELL },
Expand Down
6 changes: 3 additions & 3 deletions scripts/commands/cansee.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,17 @@ local commandObj = {}
commandObj.cmdprops =
{
permission = 1,
parameters = ''
parameters = 'i'
}

commandObj.onTrigger = function(player)
commandObj.onTrigger = function(player, ignoreInvisibleBoundaries)
local target = player:getCursorTarget()
if not target then
player:printToPlayer('No cursor target provided')
return
end

local str = player:canSee(target) and 'CAN' or 'CANNOT'
local str = player:canSee(target, ignoreInvisibleBoundaries == 1) and 'CAN' or 'CANNOT'
player:printToPlayer(string.format('%s %s see %s', player:getName(), str, target:getName()))
end

Expand Down
13 changes: 7 additions & 6 deletions scripts/commands/fafnir.lua
Original file line number Diff line number Diff line change
Expand Up @@ -41,18 +41,18 @@ commandObj.onTrigger = function(player)
-- packetName = 'Fake Fafnir',

-- Set the position using in-game x, y and z
x = player:getXPos(),
y = player:getYPos(),
z = player:getZPos(),
x = player:getXPos(),
y = player:getYPos(),
z = player:getZPos(),
rotation = player:getRotPos(),

-- Fafnir's entry in mob_groups:
-- INSERT INTO `mob_groups` VALUES (5, 1280, 154, 'Fafnir', 0, 128, 805, 70000, 0, 90, 90, 0)
-- groupId ---^ ^--- groupZoneId
groupId = 5,
groupId = 5,
groupZoneId = 154,
minLevel = 90,
maxLevel = 90,
minLevel = 90,
maxLevel = 90,
-- You can provide an onMobDeath function if you want: if you don't
-- add one, an empty one will be inserted for you behind the scenes.
onMobDeath = function(mob, playerArg, optParams)
Expand Down Expand Up @@ -82,6 +82,7 @@ commandObj.onTrigger = function(player)
mob:setSpawn(player:getXPos(), player:getYPos(), player:getZPos(), player:getRotPos())
mob:setDropID(0) -- No loot!
mob:setMobMod(xi.mobMod.NO_DROPS, 1)
mob:setMobMod(xi.mobMod.NO_DESPAWN, 1)
mob:spawn()

player:printToPlayer(string.format('Spawning Fafnir (Lv: %i, HP: %i)\n%s', mob:getMainLvl(), mob:getMaxHP(), mob))
Expand Down
4 changes: 2 additions & 2 deletions scripts/data/maze.lua
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,9 @@ xi.data.maze.runeShapeData =
[xi.maze.runeShape.PLUS] = { 0x4E40, 0x4E40, 0x4E40, 0x4E40 },
}

-- Rune item shape and element mapping.
-- Rune item -> shape and element mapping.
-- Source: Item DAT offset 0x14-0x15
-- byte[0x15] & 0xF = shape index, byte[0x14] & 0xF = element (0-7 xi.element + 1, 0xF NONE).
-- byte[0x15] & 0xF = shape index, byte[0x14] & 0xF = element (0-7 -> xi.element + 1, 0xF -> NONE).
---@type table<xi.maze.rune, { shape: xi.maze.runeShape, element: xi.element }>
xi.data.maze.runeInfo =
{
Expand Down
1 change: 1 addition & 0 deletions scripts/enum/mob_mod.lua
Original file line number Diff line number Diff line change
Expand Up @@ -105,4 +105,5 @@ xi.mobMod =
FOLLOW_LEASH_RANGE = 94, -- Distance the leader can walk before their followers start moving. Applied to followers.
FOLLOW_STOP_RANGE = 95, -- Distance the followers attempt to stop at once their leader stops moving. Applied to followers.
TRUST_SHIELD_SIZE = 96, -- TRUSTS ONLY: Set the size of the mob's shield. 3 = Default size, only used for trusts that use shields.
NO_STUCK_TELEPORT = 97, -- Disable the stuck-repath teleport fallback (terrain avoidance is intentional for this encounter).
}
4 changes: 2 additions & 2 deletions scripts/globals/assault/container.lua
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@ end
-- - ancientBoxPos: (optional) { x, y, z, rot } position of the Ancient Lockbox NPC on completion
-- - requiredProgress: (optional) Progress value at which the instance auto-completes
-- - basePoints: (optional) Base assault points before bonuses and penalties
-- - mobs: (optional) { { baseID = id, offset = n } } spawns mobs from baseID to baseID+offset
-- - mobs: (optional) { { baseID = id, offset = n } } - spawns mobs from baseID to baseID+offset
-- - npcs: (optional) Same format as mobs; sets animation to NORMAL on instance creation
-- - wallNPCs: (optional) { npcID, ... } NPCs set to OPEN_DOOR animation on instance creation
-- - wallNPCs: (optional) { npcID, ... } - NPCs set to OPEN_DOOR animation on instance creation
-- - loot: (optional) Ancient Lockbox reward table. Omit to use the zone's Ancient_Lockbox.lua.
-- - loot.appraisalReward = { { { itemId, weight }, ... } } group for unappraised gear
-- - loot.bonusLoot = { { { itemId, weight }, ... }, ... } one or more groups for consumables
Expand Down
4 changes: 0 additions & 4 deletions scripts/globals/dynamis.lua
Original file line number Diff line number Diff line change
Expand Up @@ -446,10 +446,6 @@ xi.dynamis.zoneOnInitialize = function(zone)
SpawnMob(spawnId)
end
end

for _, mob in pairs(zone:getMobs()) do
mob:setCarefulPathing(true)
end
end

xi.dynamis.zoneOnZoneIn = function(player, prevZone)
Expand Down
2 changes: 1 addition & 1 deletion scripts/mixins/families/chariot.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ g_mixins.families.chariot = function(chariotMob)
local time = GetSystemTime()

if time >= mob:getLocalVar('turnTime') then
-- mob:face() -- We lack a lua function for c++ FaceTarget. TODO: code it.
-- mob:face() -- We lack a lua function for c++ LookAtTarget. TODO: code it.

mob:setLocalVar('turnTime', time + math.random(10, 30))
end
Expand Down
8 changes: 2 additions & 6 deletions scripts/specs/core/CBaseEntity.lua
Original file line number Diff line number Diff line change
Expand Up @@ -550,15 +550,11 @@ end
function CBaseEntity:LimitDistance()
end

---@param careful boolean
---@return nil
function CBaseEntity:setCarefulPathing(careful)
end

---@nodiscard
---@param target CBaseEntity
---@param ignoreInvisibleBoundaries boolean?
---@return boolean
function CBaseEntity:canSee(target)
function CBaseEntity:canSee(target, ignoreInvisibleBoundaries)
end

---@nodiscard
Expand Down
1 change: 0 additions & 1 deletion scripts/zones/Attohwa_Chasm/mobs/Tiamat.lua
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ local function enterFlight(mob)
end

entity.onMobInitialize = function(mob)
mob:setCarefulPathing(true) -- Used for drawin
mob:setMobMod(xi.mobMod.AOE_HIT_ALL, 1)

xi.mob.updateNMSpawnPoint(mob)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ local function getFleePosition(mob, target)
end
end

-- Pass 3: cornered escape any direction, tiny step just to unstick
-- Pass 3: cornered escape - any direction, tiny step just to unstick
for _ = 1, 12 do
local pos = GetFurthestValidPosition(mob, math.random(2, 8), math.random() * 2 * math.pi)
if pos then
Expand Down
1 change: 0 additions & 1 deletion scripts/zones/Ifrits_Cauldron/mobs/Ash_Dragon.lua
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ entity.onMobInitialize = function(mob)
xi.mob.updateNMSpawnPoint(mob)
mob:setRespawnTime(math.random(259200, 432000))

mob:setCarefulPathing(true)
mob:addImmunity(xi.immunity.LIGHT_SLEEP)
mob:addImmunity(xi.immunity.DARK_SLEEP)
mob:addImmunity(xi.immunity.SILENCE)
Expand Down
1 change: 0 additions & 1 deletion scripts/zones/King_Ranperres_Tomb/mobs/Vrtra.lua
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ entity.onMobInitialize = function(mob)
mob:addImmunity(xi.immunity.TERROR)
mob:setMobMod(xi.mobMod.AOE_HIT_ALL, 1)

mob:setCarefulPathing(true)
mob:setRespawnTime(math.random(144, 240) * 1800) -- 3 to 5 days in 30 minute windows
end

Expand Down
2 changes: 0 additions & 2 deletions scripts/zones/Sacrarium/mobs/Old_Professor_Mariselle.lua
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ entity.onMobInitialize = function(mob)
end

entity.onMobSpawn = function(mob)
mob:setCarefulPathing(true)

for i = 0, 5 do
if GetNPCByID(ID.npc.QM_MARISELLE_OFFSET + i):getLocalVar('hasProfessorMariselle') == 1 then
mob:setLocalVar('spawnLocation', i)
Expand Down
1 change: 0 additions & 1 deletion scripts/zones/Uleguerand_Range/mobs/Jormungand.lua
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ entity.onMobInitialize = function(mob)
mob:addImmunity(xi.immunity.GRAVITY)
mob:addImmunity(xi.immunity.TERROR)

mob:setCarefulPathing(true)
mob:setMobMod(xi.mobMod.AOE_HIT_ALL, 1)

xi.mob.updateNMSpawnPoint(mob)
Expand Down
Loading
Loading