From 78dfccaa6f2451b2e90b993e281ddf70b168674e Mon Sep 17 00:00:00 2001 From: Chiaia Date: Mon, 12 Jul 2021 11:54:44 -0400 Subject: [PATCH 01/15] July 11th, 2021 Update --- addons/boxdestroyer/messages.lua | 42 ++++++++++++++++---------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/addons/boxdestroyer/messages.lua b/addons/boxdestroyer/messages.lua index dd8de669c..87be19465 100644 --- a/addons/boxdestroyer/messages.lua +++ b/addons/boxdestroyer/messages.lua @@ -12,36 +12,36 @@ messages = { -- These dialogue IDs match "You were unable to enter a combination [110] = 7611, [111] = 8588, [112] = 8190, - [113] = 7929, - [114] = 7786, + [113] = 7932, + [114] = 7789, [115] = 7885, [116] = 7581, [117] = 7588, [118] = 8130, [119] = 8367, [120] = 7527, - [121] = 8104, - [122] = 7435, - [123] = 7887, - [124] = 7838, - [125] = 7648, + [121] = 8107, + [122] = 7438, + [123] = 7890, + [124] = 7841, + [125] = 7651, [126] = 8074, [127] = 7355, - [128] = 7507, - [130] = 7571, - [153] = 11397, + [128] = 7510, + [130] = 7574, + [153] = 11400, [158] = 7386, - [159] = 8446, - [160] = 7410, + [159] = 8449, + [160] = 7413, [166] = 10582, [167] = 10596, [169] = 7543, [172] = 7416, - [173] = 10518, - [174] = 11396, - [176] = 7605, - [177] = 11220, - [178] = 11400, + [173] = 10521, + [174] = 11399, + [176] = 7608, + [177] = 11223, + [178] = 11403, [190] = 8257, [191] = 8377, [192] = 7413, @@ -53,9 +53,9 @@ messages = { -- These dialogue IDs match "You were unable to enter a combination [198] = 8275, [200] = 7531, [204] = 7519, - [205] = 11483, - [208] = 8285, - [212] = 10639, - [213] = 10449, + [205] = 11486, + [208] = 8288, + [212] = 10642, + [213] = 10452, } offsets = {greater_less=1, failure=2, success=4, second_even_odd=5, first_even_odd=6, range=7, less=8, greater=9, equal=10, second_multiple=11, first_multiple=12, tool_failure=13} From 492797bf2a568d6c9d5ecdb91ddc74c8907ff23f Mon Sep 17 00:00:00 2001 From: KenshiDRK Date: Mon, 12 Jul 2021 21:36:37 +0200 Subject: [PATCH 02/15] Update thtracker.lua Update th tracker to use packets instead of text --- addons/thtracker/thtracker.lua | 73 +++++++++++++++++++++------------- 1 file changed, 46 insertions(+), 27 deletions(-) diff --git a/addons/thtracker/thtracker.lua b/addons/thtracker/thtracker.lua index e3be84364..063a770aa 100644 --- a/addons/thtracker/thtracker.lua +++ b/addons/thtracker/thtracker.lua @@ -27,11 +27,12 @@ _addon.name = 'THTracker' _addon.author = 'Krizz' -_addon.version = 1.1 +_addon.version = 1.2 _addon.commands = {'thtracker', 'th'} config = require ('config') texts = require ('texts') +packets = require('packets') require('logger') defaults = {} @@ -51,7 +52,9 @@ defaults.bg.blue = 30 settings = config.load(defaults) -th = texts.new('No current mob', settings) +th = texts.new('${th_string}', settings) + +local th_table = {} windower.register_event('addon command', function(command, ...) command = command and command:lower() @@ -74,33 +77,49 @@ windower.register_event('addon command', function(command, ...) end end) -windower.register_event('incoming text', function(original, new, color) - original = original:strip_format() - local name, count = original:match('Additional effect: Treasure Hunter effectiveness against[%s%a%a%a]- (.*) increases to (%d+).') - - if name and count then - name = name.gsub(name, "the ", "") - mob = name - th:text(' '..name..'\n TH: '..count); - th:show() +windower.register_event('incoming chunk', function(id, data) + if id == 0x028 then + local packet = packets.parse('incoming', data) + if packet.Category == 1 and packet['Target 1 Action 1 Has Added Effect'] and packet['Target 1 Action 1 Added Effect Message'] == 603 then + th_table[packet['Target 1 ID']] = 'TH: '..packet['Target 1 Action 1 Added Effect Param'] + update_text() + elseif packet.Category == 3 and packet['Target 1 Action 1 Message'] == 608 then + th_table[packet['Target 1 ID']] = 'TH: '..packet['Target 1 Action 1 Param'] + update_text() + end + elseif id == 0x038 then + local packet = packets.parse('incoming', data) + if th_table[packet['Mob']] and packet['Type'] == 'kesu' then + th_table[packet['Mob']] = nil + update_text() + end + elseif id == 0x00E then + local packet = packets.parse('incoming', data) + if th_table[packet['NPC']] and packet['Status'] == 0 and packet['HP %'] == 100 then + th_table[packet['NPC']] = nil + update_text() + end end +end) - local deadmob = original:match('%w+ defeats[%s%a%a%a]- (.*).') - - if deadmob then - deadmob = deadmob.gsub(deadmob, "the ", "") - end - - if deadmob == mob then - - th:text('No current mob') - th:hide() - mob = nil - end +windower.register_event('zone change', function() + th_table = {} + update_text() +end) +windower.register_event('target change', function() + update_text() end) -windower.register_event('zone change', function() - th:text('No current mob') - th:hide() -end) \ No newline at end of file +function update_text() + local current_string + local target = windower.ffxi.get_mob_by_target('st') or windower.ffxi.get_mob_by_target('t') + if target and th_table[target.id] then + current_string = target.name..'\n '..th_table[target.id] + th:show() + else + current_string = '' + th:hide() + end + th.th_string = current_string +end From a03b322358366bccafc8e7be124cb2e2ec2c8474 Mon Sep 17 00:00:00 2001 From: KenshiDRK Date: Tue, 13 Jul 2021 14:19:07 +0200 Subject: [PATCH 03/15] Update slips.lua Adding Leafkin Bed --- addons/libs/slips.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/libs/slips.lua b/addons/libs/slips.lua index 12cb8bfd6..de0e18893 100644 --- a/addons/libs/slips.lua +++ b/addons/libs/slips.lua @@ -34,7 +34,7 @@ slips.items = { [slips.storages[19]] = L{27715, 27866, 27716, 27867, 278, 281, 284, 3680, 3681, 27859, 28149, 27860, 28150, 21107, 21108, 27625, 27626, 26693, 26694, 26707, 26708, 27631, 27632, 26705, 26706, 27854, 27855, 26703, 26704, 3682, 3683, 3684, 3685, 3686, 3687, 3688, 3689, 3690, 3691, 3692, 3693, 3694, 3695, 21097, 21098, 26717, 26718, 26728,26719,26720,26889,26890, 21095, 21096, 26738, 26739, 26729, 26730, 26788, 26946, 27281, 27455, 26789, 3698, 20713, 20714, 26798, 26954, 26799, 26955, 3706, 26956, 26957, 3705, 26964, 26965, 27291, 26967, 27293, 26966, 27292, 26968, 27294, 21153, 21154, 21086, 21087, 25606, 26974, 27111, 27296, 27467, 25607, 26975, 27112, 27297, 27468, 14195, 14830, 14831, 13945, 13946, 14832, 13947, 17058, 13948, 14400, 14392, 14393, 14394, 14395, 14396, 14397, 14398, 14399, 11337, 11329, 11330, 11331, 11332, 11333, 11334, 11335, 11336, 15819, 15820, 15821, 15822, 15823, 15824, 15825, 15826, 3670, 3672, 3661, 3595, 3665, 3668, 3663, 3674, 3667, 191, 28, 153, 151, 198, 202, 142, 134, 137, 340, 341, 334, 335, 337, 339, 336, 342, 338, 3631, 3632, 3625, 3626, 3628, 3630, 3627, 3633, 3629, 25632, 25633, 25604, 25713, 27325, 25714, 27326, 3651, 25711, 25712, 10925, 10948, 10949, 10950, 10951, 10952, 10953, 10954, 10955, 25657, 25756, 25658, 25757, 25909}, -- 192 [slips.storages[20]] = L{26740, 26898, 27052, 27237, 27411, 26742, 26900, 27054, 27239, 27413, 26744, 26902, 27056, 27241, 27415, 26746, 26904, 27058, 27243, 27417, 26748, 26906, 27060, 27245, 27419, 26750, 26908, 27062, 27247, 27421, 26752, 26910, 27064, 27249, 27423, 26754, 26912, 27066, 27251, 27425, 26756, 26914, 27068, 27253, 27427, 26758, 26916, 27070, 27255, 27429, 26760, 26918, 27072, 27257, 27431, 26762, 26920, 27074, 27259, 27433, 26764, 26922, 27076, 27261, 27435, 26766, 26924, 27078, 27263, 27437, 26768, 26926, 27080, 27265, 27439, 26770, 26928, 27082, 27267, 27441, 26772, 26930, 27084, 27269, 27443, 26774, 26932, 27086, 27271, 27445, 26776, 26934, 27088, 27273, 27447, 26778, 26936, 27090, 27275, 27449, 26780, 26938, 27092, 27277, 27451, 26782, 26940, 27094, 27279, 27453}, -- 110 [slips.storages[21]] = L{26741, 26899, 27053, 27238, 27412, 26743, 26901, 27055, 27240, 27414, 26745, 26903, 27057, 27242, 27416, 26747, 26905, 27059, 27244, 27418, 26749, 26907, 27061, 27246, 27420, 26751, 26909, 27063, 27248, 27422, 26753, 26911, 27065, 27250, 27424, 26755, 26913, 27067, 27252, 27426, 26757, 26915, 27069, 27254, 27428, 26759, 26917, 27071, 27256, 27430, 26761, 26919, 27073, 27258, 27432, 26763, 26921, 27075, 27260, 27434, 26765, 26923, 27077, 27262, 27436, 26767, 26925, 27079, 27264, 27438, 26769, 26927, 27081, 27266, 27440, 26771, 26929, 27083, 27268, 27442, 26773, 26931, 27085, 27270, 27444, 26775, 26933, 27087, 27272, 27446, 26777, 26935, 27089, 27274, 27448, 26779, 26937, 27091, 27276, 27450, 26781, 26939, 27093, 27278, 27452, 26783, 26941, 27095, 27280, 27454}, -- 110 - [slips.storages[22]] = L{25639, 25715, 25638, 3707, 3708, 21074, 26406, 25645, 25726, 25648, 25649, 25650, 25758, 25759, 25672, 25673, 282, 279, 280, 268, 25670, 25671, 26520, 25652, 25669, 22017, 22018, 25586, 25587, 10384, 10385, 22019, 22020, 25722, 25585, 25776, 25677, 25678, 25675, 25679, 20668, 20669, 22069, 25755, 3722, 21608, 3713, 3714, 3715, 3717, 3727, 3728, 20577, 3726, 20666, 20667, 21741, 21609, 3723, 26410, 26411, 25850, 21509, 3725, 3720, 21658, 26524, 20665, 26412, 21965, 21966, 21967, 25774, 25838, 25775, 25839, 3724, 3721, 21682, 22072, 21820, 21821, 23731, 26517, 23730, 20573, 20674, 21742, 21860, 22065, 22039, 22124, 22132, 3719, 3738, 26518, 27623, 21867, 21868, 22283, 26516, 20933, 20578, 20568, 3739, 20569, 20570, 22288, 26352, 23737, 22282, 3740, 0, 26545, 21977, 21978, 3742, 26519, 26514, 26515, 3743, 21636, 23753, 23754, 54, 25910, 20571, 23790, 23791, 26489, 22153, 22154, 20574, 20675, 21743, 21861, 22066}, -- 137 SE Skipped an index hence the 0 as one of the items + [slips.storages[22]] = L{25639, 25715, 25638, 3707, 3708, 21074, 26406, 25645, 25726, 25648, 25649, 25650, 25758, 25759, 25672, 25673, 282, 279, 280, 268, 25670, 25671, 26520, 25652, 25669, 22017, 22018, 25586, 25587, 10384, 10385, 22019, 22020, 25722, 25585, 25776, 25677, 25678, 25675, 25679, 20668, 20669, 22069, 25755, 3722, 21608, 3713, 3714, 3715, 3717, 3727, 3728, 20577, 3726, 20666, 20667, 21741, 21609, 3723, 26410, 26411, 25850, 21509, 3725, 3720, 21658, 26524, 20665, 26412, 21965, 21966, 21967, 25774, 25838, 25775, 25839, 3724, 3721, 21682, 22072, 21820, 21821, 23731, 26517, 23730, 20573, 20674, 21742, 21860, 22065, 22039, 22124, 22132, 3719, 3738, 26518, 27623, 21867, 21868, 22283, 26516, 20933, 20578, 20568, 3739, 20569, 20570, 22288, 26352, 23737, 22282, 3740, 0, 26545, 21977, 21978, 3742, 26519, 26514, 26515, 3743, 21636, 23753, 23754, 54, 25910, 20571, 23790, 23791, 26489, 22153, 22154, 20574, 20675, 21743, 21861, 22066, 3748}, -- 138 SE Skipped an index hence the 0 as one of the items [slips.storages[23]] = L{25659, 25745, 25800, 25858, 25925, 25660, 25746, 25801, 25859, 25926, 25663, 25749, 25804, 25862, 25929, 25664, 25750, 25805, 25863, 25930, 25665, 25751, 25806, 25865, 25931, 25666, 25752, 25807, 25866, 25932, 25661, 25747, 25802, 25860, 25927, 25662, 25748, 25803, 25861, 25928, 25667, 25753, 25808, 25867, 25933, 25668, 25754, 25809, 25868, 25934, 25579, 25779, 25818, 25873, 25940, 25580, 25780, 25819, 25874, 25941, 25590, 25764, 25812, 25871, 25937, 25591, 25765, 25813, 25872, 25938, 25581, 25781, 25820, 25875, 25942, 25582, 25782, 25821, 25876, 25943, 25588, 25762, 25810, 25869, 25935, 25589, 25763, 25811, 25870, 25936, 25583, 25783, 25822, 25877, 25944, 25584, 25784, 25823, 25878, 25945, 25574, 25790, 25828, 25879, 25946, 25575, 25791, 25829, 25880, 25947, 25576, 25792, 25830, 25881, 25948, 25577, 25793, 25831, 25882, 25949, 25578, 25794, 25832, 25883, 25950, 26204, 26205, 26206, 26207, 26208, 25569, 25797, 25835, 25886, 25953, 25573, 25796, 25834, 25885, 25952, 25570, 25798, 25836, 25887, 25954, 25572, 25795, 25833, 25884, 25951, 25571, 25799, 25837, 25888, 25955, 26211, 26210, 26212, 26209, 26213, 21863, 22004, 21744, 21272, 20576, 21761, 26409, 22070, 21681, 22005, 21745, 22068, 21759, 21770}, --174 [slips.storages[24]] = L{23040, 23107, 23174, 23241, 23308, 23041, 23108, 23175, 23242, 23309, 23042, 23109, 23176, 23243, 23310, 23043, 23110, 23177, 23244, 23311, 23044, 23111, 23178, 23245, 23312, 23045, 23112, 23179, 23246, 23313, 23046, 23113, 23180, 23247, 23314, 23047, 23114, 23181, 23248, 23315, 23048, 23115, 23182, 23249, 23316, 23049, 23116, 23183, 23250, 23317, 23050, 23117, 23184, 23251, 23318, 23051, 23118, 23185, 23252, 23319, 23052, 23119, 23186, 23253, 23320, 23053, 23120, 23187, 23254, 23321, 23054, 23121, 23188, 23255, 23322, 23055, 23122, 23189, 23256, 23323, 23056, 23123, 23190, 23257, 23324, 23057, 23124, 23191, 23258, 23325, 23058, 23125, 23192, 23259, 23326, 23059, 23126, 23193, 23260, 23327, 23060, 23127, 23194, 23261, 23328, 23061, 23128, 23195, 23262, 23329, 23062, 23129, 23196, 23263, 23330}, --115 [slips.storages[25]] = L{23375, 23442, 23509, 23576, 23643, 23376, 23443, 23510, 23577, 23644, 23377, 23444, 23511, 23578, 23645, 23378, 23445, 23512, 23579, 23646, 23379, 23446, 23513, 23580, 23647, 23380, 23447, 23514, 23581, 23648, 23381, 23448, 23515, 23582, 23649, 23382, 23449, 23516, 23583, 23650, 23383, 23450, 23517, 23584, 23651, 23384, 23451, 23518, 23585, 23652, 23385, 23452, 23519, 23586, 23653, 23386, 23453, 23520, 23587, 23654, 23387, 23454, 23521, 23588, 23655, 23388, 23455, 23522, 23589, 23656, 23389, 23456, 23523, 23590, 23657, 23390, 23457, 23524, 23591, 23658, 23391, 23458, 23525, 23592, 23659, 23392, 23459, 23526, 23593, 23660, 23393, 23460, 23527, 23594, 23661, 23394, 23461, 23528, 23595, 23662, 23395, 23462, 23529, 23596, 23663, 23396, 23463, 23530, 23597, 23664, 23397, 23464, 23531, 23598, 23665}, --115 From 85ff50e74d5b2e6afa88e51846ecddf66ff72fe9 Mon Sep 17 00:00:00 2001 From: RubenatorX Date: Thu, 15 Jul 2021 17:34:45 -0600 Subject: [PATCH 04/15] Linkshell name and color fixes --- addons/libs/extdata.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/libs/extdata.lua b/addons/libs/extdata.lua index aeae471c9..0537a4375 100644 --- a/addons/libs/extdata.lua +++ b/addons/libs/extdata.lua @@ -1823,15 +1823,15 @@ function decode.Linkshell(str) end local name_map = {[0]="'",[1]="a",[2]='b',[3]='c',[4]='d',[5]='e',[6]='f',[7]='g',[8]='h',[9]='i',[10]='j', [11]='k',[12]='l',[13]='m',[14]='n',[15]='o',[16]='p',[17]='q',[18]='r',[19]='s',[20]='t',[21]='u',[22]='v',[23]='w', - [24]='x',[25]='yx',[26]='z',[27]='A',[28]='B',[29]='C',[30]='D',[31]='E',[32]='F',[33]='G',[34]='H',[35]='I',[36]='J', + [24]='x',[25]='y',[26]='z',[27]='A',[28]='B',[29]='C',[30]='D',[31]='E',[32]='F',[33]='G',[34]='H',[35]='I',[36]='J', [37]='K',[38]='L',[39]='M',[40]='N',[41]='O',[42]='P',[43]='Q',[44]='R',[45]='S',[46]='T',[47]='U',[48]='V',[49]='W', [50]='X',[51]='Y',[52]='Z' } local rettab = {type = 'Linkshell', linkshell_id = str:unpack('I'), - r = 17*str:byte(7)%16, + r = 17*(str:byte(7)%16), g = 17*math.floor(str:byte(7)/16), - b = 17*str:byte(8)%16, + b = 17*(str:byte(8)%16), status_id = str:byte(9), status = status_map[str:byte(9)]} From 2e6f9b649ef253e5158f7a3a99278c9e05b530cb Mon Sep 17 00:00:00 2001 From: Ian Anderson Date: Fri, 16 Jul 2021 20:59:54 -0700 Subject: [PATCH 05/15] Update roe.lua See discord message --- addons/roe/roe.lua | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/addons/roe/roe.lua b/addons/roe/roe.lua index 6202066ad..4de822afe 100644 --- a/addons/roe/roe.lua +++ b/addons/roe/roe.lua @@ -206,8 +206,12 @@ local function blacklist(add_remove,id) settings.blacklist:add(id) notice('roe quest %d added to the blacklist':format(id)) elseif add_remove == 'remove' then - settings.blacklist:remove(id) - notice('roe quest %d removed from the blacklist':format(id)) + if not id >= 4008 and not id <= 4021 then + return + else + settings.blacklist:remove(id) + notice('roe quest %d removed from the blacklist':format(id)) + end else error('`blacklist` specify \'add\' or \'remove\'') end From 8c7d7b400b4896d8c86ec1cd2126cd80dc0cf85e Mon Sep 17 00:00:00 2001 From: Ian Anderson Date: Fri, 16 Jul 2021 21:07:38 -0700 Subject: [PATCH 06/15] Update roe.lua --- addons/roe/roe.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/roe/roe.lua b/addons/roe/roe.lua index 4de822afe..5d2742912 100644 --- a/addons/roe/roe.lua +++ b/addons/roe/roe.lua @@ -206,7 +206,7 @@ local function blacklist(add_remove,id) settings.blacklist:add(id) notice('roe quest %d added to the blacklist':format(id)) elseif add_remove == 'remove' then - if not id >= 4008 and not id <= 4021 then + if id >= 4008 and id <= 4021 then return else settings.blacklist:remove(id) From d2832254e4ff1433f7aab1821b673a1f78f4a6f5 Mon Sep 17 00:00:00 2001 From: Ian Anderson Date: Sat, 17 Jul 2021 05:01:27 -0700 Subject: [PATCH 07/15] Update roe.lua --- addons/roe/roe.lua | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/addons/roe/roe.lua b/addons/roe/roe.lua index 5d2742912..236073c36 100644 --- a/addons/roe/roe.lua +++ b/addons/roe/roe.lua @@ -27,7 +27,7 @@ _addon = {} _addon.name = 'ROE' -_addon.version = '1.0' +_addon.version = '1.1' _addon.author = "Cair" _addon.commands = {'roe'} @@ -206,12 +206,12 @@ local function blacklist(add_remove,id) settings.blacklist:add(id) notice('roe quest %d added to the blacklist':format(id)) elseif add_remove == 'remove' then - if id >= 4008 and id <= 4021 then - return - else - settings.blacklist:remove(id) - notice('roe quest %d removed from the blacklist':format(id)) - end + if id >= 4008 and id <= 4021 then + return + else + settings.blacklist:remove(id) + notice('roe quest %d removed from the blacklist':format(id)) + end else error('`blacklist` specify \'add\' or \'remove\'') end From 8c7b1aab352dffecb09118617ba05956a6f3ec2d Mon Sep 17 00:00:00 2001 From: lili-ffxi <40600148+lili-ffxi@users.noreply.github.com> Date: Sat, 17 Jul 2021 17:00:55 +0100 Subject: [PATCH 08/15] Added Nomad Moogle check. Check for Nomad/Pilgrim Moogles at the start of the command. Added appropriate debug notices. --- addons/organizer/organizer.lua | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/addons/organizer/organizer.lua b/addons/organizer/organizer.lua index 9abb43f04..a3c3107c8 100644 --- a/addons/organizer/organizer.lua +++ b/addons/organizer/organizer.lua @@ -35,6 +35,7 @@ require 'lists' require 'functions' config = require 'config' slips = require 'slips' +packets = require 'packets' _addon.name = 'Organizer' _addon.author = 'Byrth, maintainer: Rooks' @@ -243,6 +244,11 @@ windower.register_event('addon command',function(...) return end + local moogle = nomad_moogle() + if moogle then + org_debug("command","Using '" .. mog .. "' for Mog House interaction") + end + local bag = 'all' if inp[1] and (_static.bag_ids[inp[1]:lower()] or inp[1]:lower() == 'all') then bag = table.remove(inp,1):lower() @@ -299,6 +305,11 @@ windower.register_event('addon command',function(...) windower.send_command('input /heal') end + if moogle then + clear_moogle() + org_debug("command","Clearing '" .. moogle .. "' status") + end + org_debug("command", "Organizer complete") end) From 20a05162f456545476e8450d956d6588e0801546 Mon Sep 17 00:00:00 2001 From: lili-ffxi <40600148+lili-ffxi@users.noreply.github.com> Date: Sat, 17 Jul 2021 17:02:32 +0100 Subject: [PATCH 09/15] Added poke to Nomad Moogles Initiate menu interaction with Moogles before using Mog House bags. --- addons/organizer/items.lua | 34 +++++++++++++++++++++++++++++++--- 1 file changed, 31 insertions(+), 3 deletions(-) diff --git a/addons/organizer/items.lua b/addons/organizer/items.lua index 3a1afea58..ceaeb87d0 100644 --- a/addons/organizer/items.lua +++ b/addons/organizer/items.lua @@ -29,14 +29,30 @@ local items = {} local bags = {} local item_tab = {} -local nomad_moogle -local clear_moogles do local names = {'Nomad Moogle', 'Pilgrim Moogle'} local moogles = {} + local poked = false + local block_menu = false clear_moogles = function() moogles = {} + poked = false + end + + local poke_moogle = function(npc) + print('poking', npc.name) + local p = packets.new('outgoing', 0x1a, { + ["Target"] = npc.id, + ["Target Index"] = npc.index, + }) + poked = true + block_menu = true + packets.inject(p) + repeat + coroutine.sleep(0.4) + print('waitan') + until not block_menu end nomad_moogle = function() @@ -45,6 +61,7 @@ do local npcs = windower.ffxi.get_mob_list(name) for index in pairs(npcs) do table.insert(moogles,index) + print(name,index) end end end @@ -53,11 +70,22 @@ do for _, moo_index in ipairs(moogles) do local moo = windower.ffxi.get_mob_by_index(moo_index) if moo and (moo.x - player.x)^2 + (moo.y - player.y)^2 < 36 then - return true + if not poked then + poke_moogle(moo) + end + return moo.name end end return false end + + windower.register_event('incoming chunk',function(id,data,modified,injected,blocked) + if id == 0x02E and block_menu then + print('moogle poked, menu blocked') + block_menu = false + return true + end + end) end windower.register_event('zone change',function() From e05ab958aa176f864753c33122a59c3d8e69780e Mon Sep 17 00:00:00 2001 From: lili-ffxi <40600148+lili-ffxi@users.noreply.github.com> Date: Sat, 17 Jul 2021 17:05:26 +0100 Subject: [PATCH 10/15] Removing leftover debug lines --- addons/organizer/items.lua | 4 ---- 1 file changed, 4 deletions(-) diff --git a/addons/organizer/items.lua b/addons/organizer/items.lua index ceaeb87d0..91b5d7950 100644 --- a/addons/organizer/items.lua +++ b/addons/organizer/items.lua @@ -41,7 +41,6 @@ do end local poke_moogle = function(npc) - print('poking', npc.name) local p = packets.new('outgoing', 0x1a, { ["Target"] = npc.id, ["Target Index"] = npc.index, @@ -51,7 +50,6 @@ do packets.inject(p) repeat coroutine.sleep(0.4) - print('waitan') until not block_menu end @@ -61,7 +59,6 @@ do local npcs = windower.ffxi.get_mob_list(name) for index in pairs(npcs) do table.insert(moogles,index) - print(name,index) end end end @@ -81,7 +78,6 @@ do windower.register_event('incoming chunk',function(id,data,modified,injected,blocked) if id == 0x02E and block_menu then - print('moogle poked, menu blocked') block_menu = false return true end From 92abc7df459752a323dca6ee16884a3443db29d9 Mon Sep 17 00:00:00 2001 From: lili-ffxi <40600148+lili-ffxi@users.noreply.github.com> Date: Sat, 17 Jul 2021 17:05:57 +0100 Subject: [PATCH 11/15] Typo fix --- addons/organizer/organizer.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/organizer/organizer.lua b/addons/organizer/organizer.lua index a3c3107c8..26f1917b1 100644 --- a/addons/organizer/organizer.lua +++ b/addons/organizer/organizer.lua @@ -246,7 +246,7 @@ windower.register_event('addon command',function(...) local moogle = nomad_moogle() if moogle then - org_debug("command","Using '" .. mog .. "' for Mog House interaction") + org_debug("command","Using '" .. moogle .. "' for Mog House interaction") end local bag = 'all' From 5e21c855baa4b7ccef492e0f197d18dc8b08d251 Mon Sep 17 00:00:00 2001 From: lili-ffxi <40600148+lili-ffxi@users.noreply.github.com> Date: Sun, 18 Jul 2021 00:06:10 +0100 Subject: [PATCH 12/15] Commas --- addons/organizer/items.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/organizer/items.lua b/addons/organizer/items.lua index 91b5d7950..126cde3f4 100644 --- a/addons/organizer/items.lua +++ b/addons/organizer/items.lua @@ -76,7 +76,7 @@ do return false end - windower.register_event('incoming chunk',function(id,data,modified,injected,blocked) + windower.register_event('incoming chunk',function(id) if id == 0x02E and block_menu then block_menu = false return true From 253042c648f4d0b223a401e065579ce3674d26f2 Mon Sep 17 00:00:00 2001 From: lili-ffxi <40600148+lili-ffxi@users.noreply.github.com> Date: Sun, 18 Jul 2021 00:07:37 +0100 Subject: [PATCH 13/15] Parentheses and spaces --- addons/organizer/organizer.lua | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/addons/organizer/organizer.lua b/addons/organizer/organizer.lua index 26f1917b1..56e67826f 100644 --- a/addons/organizer/organizer.lua +++ b/addons/organizer/organizer.lua @@ -24,18 +24,18 @@ --(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS --SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -res = require 'resources' -files = require 'files' -require 'pack' -Items = require 'items' -extdata = require 'extdata' -logger = require 'logger' -require 'tables' -require 'lists' -require 'functions' -config = require 'config' -slips = require 'slips' -packets = require 'packets' +res = require('resources') +files = require('files') +require('pack') +Items = require('items') +extdata = require('extdata') +logger = require('logger') +require('tables') +require('lists') +require('functions') +config = require('config') +slips = require('slips') +packets = require('packets') _addon.name = 'Organizer' _addon.author = 'Byrth, maintainer: Rooks' @@ -246,7 +246,7 @@ windower.register_event('addon command',function(...) local moogle = nomad_moogle() if moogle then - org_debug("command","Using '" .. moogle .. "' for Mog House interaction") + org_debug("command", "Using '" .. moogle .. "' for Mog House interaction") end local bag = 'all' @@ -307,7 +307,7 @@ windower.register_event('addon command',function(...) if moogle then clear_moogle() - org_debug("command","Clearing '" .. moogle .. "' status") + org_debug("command", "Clearing '" .. moogle .. "' status") end org_debug("command", "Organizer complete") From 383f893e40de36f924123f6058d09e269b12f3dc Mon Sep 17 00:00:00 2001 From: Ian Anderson Date: Sat, 17 Jul 2021 22:07:02 -0700 Subject: [PATCH 14/15] Update roe.lua --- addons/roe/roe.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/addons/roe/roe.lua b/addons/roe/roe.lua index 236073c36..dfa7570c1 100644 --- a/addons/roe/roe.lua +++ b/addons/roe/roe.lua @@ -70,8 +70,9 @@ local function accept_roe(id) id = tonumber(id) if not id or _roe.complete[id] or _roe.active[id] then return end + if id and id >= 4008 and id <= 4021 then return end - local p = packets.new('outgoing', 0x10c, {['RoE Quest'] = id }) + local p = packets.new('outgoing', 0x10c, {['RoE Quest'] = id }) packets.inject(p) end From 06a5c6725cf55b2af606d0ab5cef0c2ca73fbebd Mon Sep 17 00:00:00 2001 From: Ian Anderson Date: Sat, 17 Jul 2021 22:09:05 -0700 Subject: [PATCH 15/15] Update roe.lua --- addons/roe/roe.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/roe/roe.lua b/addons/roe/roe.lua index dfa7570c1..49dd52d33 100644 --- a/addons/roe/roe.lua +++ b/addons/roe/roe.lua @@ -72,7 +72,7 @@ local function accept_roe(id) if not id or _roe.complete[id] or _roe.active[id] then return end if id and id >= 4008 and id <= 4021 then return end - local p = packets.new('outgoing', 0x10c, {['RoE Quest'] = id }) + local p = packets.new('outgoing', 0x10c, {['RoE Quest'] = id }) packets.inject(p) end