#author("2025-07-28T07:07:54+00:00","default:yoya","yoya")
#author("2025-07-28T07:08:04+00:00","default:yoya","yoya")
[[Windower/Lua]]

* 戦闘終了 [#t4ea4738]

- https://github.com/Technyze/XIVHotbar2/issues/17

 if id == 0x02D then -- Kill Message
     mob_killed = true	
 	old_level = windower.ffxi.get_player().main_job_level
 elseif mob_killed and id == 0x061 then -- Mob Killed and Char Stats Message	
 	local packet = packets.parse('incoming', original)
 	(略)
 	mob_killed = false

- https://github.com/toast-ffxi/FFXIAddons/blob/main/ATA/ATA.lua

 windower.register_event('incoming chunk', function(id, data, modified, injected, blocked)
 	if id == 0x029 then -- Action Message
 		actionMessageHandler(packets.parse('incoming', data))
 
 function actionMessageHandler(amPacket)
 	-- If enemy defeated or falls to the ground message
 	if amPacket.Message == 6 or amPacket.Message == 20 then
 		local mobData = windower.ffxi.get_mob_by_id(amPacket.Target)

* 戦闘アクション [#qaa9bffb]

https://github.com/Windower/Lua/blob/dev/addons/libs/packets/fields.lua#L1799
 enums.action_in = {
     [1] = 'Melee attack',
     [2] = 'Ranged attack finish',
     [3] = 'Weapon Skill finish',
     [4] = 'Casting finish',
     [5] = 'Item finish',
     [6] = 'Job Ability',
     [7] = 'Weapon Skill start',
     [8] = 'Casting start',
     [9] = 'Item start',
     [11] = 'NPC TP finish',
     [12] = 'Ranged attack start',
     [13] = 'Avatar TP finish',
     [14] = 'Job Ability DNC',
     [15] = 'Job Ability RUN',
 }

* 連携 [#q8a1c287]
* 連携 [#skillchain]

- https://github.com/Ivaar/Skillchains/blob/master/Skillchains.lua
- https://github.com/Sippius/Ashita-v4-addons/blob/main/chains/chains.lua
- https://github.com/mousseng/xitools/blob/master/addons/skillchain/skillchain.lua