Skip to content

Instantly share code, notes, and snippets.

@Ivaar
Last active July 2, 2020 02:13
Show Gist options
  • Save Ivaar/a779820384dbe1bdf04e58518385ee99 to your computer and use it in GitHub Desktop.
Save Ivaar/a779820384dbe1bdf04e58518385ee99 to your computer and use it in GitHub Desktop.
return {
['Abyssea - La Theine'] = {option = 260, unlock_bit = 0},
['Abyssea - Konschtat'] = {option = 264, unlock_bit = 1},
['Abyssea - Tahrongi'] = {option = 268, unlock_bit = 2},
['Abyssea - Vunkerl'] = {option = 272, unlock_bit = 32},
['Abyssea - Misareaux'] = {option = 276, unlock_bit = 33},
['Abyssea - Attohwa'] = {option = 280, unlock_bit = 34},
['Abyssea - Altepa'] = {option = 284, unlock_bit = 64},
['Abyssea - Uleguerand'] = {option = 288, unlock_bit = 65},
['Abyssea - Grauberg'] = {option = 292, unlock_bit = 66},
}
local alias = {}
alias.zone = {}
alias.zone = {
['sandy'] = 'Southern San\'doria',
['nsandy'] = 'Northern San\'doria',
}
alias.waypoints = {
global = {
triumphus = {zone = 'Western Adoulin', point = 1},
couriers = {zone = 'Western Adoulin', point = 1},
pioneers = {zone = 'Western Adoulin', point = 2},
mummers = {zone = 'Western Adoulin', point = 3},
inventors = {zone = 'Western Adoulin', point = 4},
bridge = {zone = 'Western Adoulin', point = 7},
airship = {zone = 'Western Adoulin', point = 8},
docks = {zone = 'Western Adoulin', point = 8},
waterfront = {zone = 'Western Adoulin', point = 9},
peacekeepers = {zone = 'Eastern Adoulin', point = 1},
scouts = {zone = 'Eastern Adoulin', point = 2},
statue = {zone = 'Eastern Adoulin', point = 3},
goddess = {zone = 'Eastern Adoulin', point = 3},
wharf = {zone = 'Eastern Adoulin', point = 4},
sverdhried = {zone = 'Eastern Adoulin', point = 7},
hillock = {zone = 'Eastern Adoulin', point = 7},
hill = {zone = 'Eastern Adoulin', point = 7},
coronal = {zone = 'Eastern Adoulin', point = 8},
esplanade = {zone = 'Eastern Adoulin', point = 8},
castle = {zone = 'Eastern Adoulin', point = 9},
gates = {zone = 'Eastern Adoulin', point = 9},
ah = {zone = 'Western Adoulin', point = 5},
mh = {zone = 'Western Adoulin', point = 6},
},
['Western Adoulin'] = {
ah = 5,
mh = 6,
},
['Eastern Adoulin'] = {
mh = 5,
ah = 6,
},
['Ceizak Battlegrounds'] = {
fs = 0,
},
['Yahse Hunting Grounds'] = {
fs = 0,
},
['Foret de Hennetiel'] = {
fs = 0,
},
['Morimar Basalt Fields'] = {
fs = 0,
},
['Yorcia Weald'] = {
fs = 0,
ed = 4,
},
['Marjami Ravine'] = {
fs = 0,
},
['Kamihr Drifts'] = {
fs = 0,
},
}
alias.homepoints = {
global = {
fish = {zone = 'Port Windurst', point = 1},
ww = {zone = 'nsandy', point = 4},
bs = {zone = 'Metalworks', point = 2},
gs = {zone = 'Bastok Markets', point = 4},
cc = {zone = 'Windurst Woods', point = 5},
lc = {zone = 'sandy', point = 4},
bc = {zone = 'Windurst Woods', point = 5},
alc = {zone = 'Bastok Mines', point = 3},
cook = {zone = 'Windurst Waters', point = 4},
},
['Southern San d\'Oria'] = {
entrance = 1,
ah = 2,
mh = 3,
guild = 4,
},
['Northern San d\'Oria'] = {
entrance = 1,
mh = 3,
guild = 4,
},
['Port San d\'Oria'] = {
mh = 2,
ah = 3,
},
['Bastok Mines'] = {
ah = 1,
mh = 2,
guild = 3,
},
['Bastok Markets'] = {
entrance = 1,
ah = 2,
mh = 3,
guild = 4,
},
['Port Bastok'] = {
entrance = 1,
mh = 2,
},
['Windurst Waters'] = {
entrance = 1,
mh = 2,
guild = 4,
},
['Windurst Walls'] = {
mh = 2,
ah = 3,
},
['Port Windurst'] = {
entrance = 2,
mh = 3,
guild = 1,
},
['Windurst Woods'] = {
entrance = 2,
mh = 3,
ah = 4,
guild = 5,
},
['Ru\'Lude Gardens'] = {
mh = 2,
ah = 3,
},
['Upper Jeuno'] = {
entrance = 1,
mh = 2,
ah = 3,
},
['Lower Jeuno'] = {
entrance = 1,
mh = 2,
},
['Port Jeuno'] = {
entrance = 1,
mh = 2,
},
['Aht Urhgan Whitegate'] = {
ah = 3,
mh = 4,
},
['Norg'] = {
entrance = 1,
ah = 2,
},
['Rabao'] = {
entrance = 1,
},
['Western Adoulin'] = {
ah = 1,
entrance = 1,
mh = 2,
},
['Eastern Adoulin'] = {
ah = 2,
mh = 2,
},
}
for k in pairs(alias.waypoints) do
alias.waypoints[k].a = alias.waypoints[k].ah
alias.waypoints[k].m = alias.waypoints[k].mh
end
for k in pairs(alias.homepoints) do
alias.homepoints[k].a = alias.homepoints[k].ah
alias.homepoints[k].m = alias.homepoints[k].mh
end
return alias
return {
[15] = {--id=15,en="Abyssea - Konschtat"
{index = 1, x = 126.00000762939, z = -72.800003051758, y = -834.00006103516, rotation = 223},
{index = 2, x = -164.00001525879, z = -32.700000762939, y = -276, rotation = 159},
{index = 3, x = -644.00006103516, z = -0.70000004768372, y = 124.00000762939, rotation = 159},
{index = 4, x = 20, z = 8.7000007629395, y = 45.000003814697, rotation = 191},
{index = 5, x = -125.00000762939, z = 15.200000762939, y = 282, rotation = 127},
{index = 6, x = -316, z = 47.100002288818, y = 564, rotation = 223},
{index = 7, x = 476.00003051758, z = 7.3000001907349, y = 124.00000762939, rotation = 159},
{index = 8, x = 244.00001525879, z = 39.200000762939, y = 636, rotation = 31},
},
[45] = {--id=45,en="Abyssea - Tahrongi",
{index = 1, x = 7.826000213623, z = 31.515001296997, y = -636.83404541016, rotation = 81},
{index = 2, x = 24.010000228882, z = -16.682001113892, y = -171.58700561523, rotation = 162},
{index = 3, x = -290.78402709961, z = -25.574001312256, y = -171.65501403809, rotation = 201},
{index = 4, x = -239.86801147461, z = 7.4700002670288, y = 166.16600036621, rotation = 76},
{index = 5, x = -56.126003265381, z = 31.085000991821, y = 547.42602539063, rotation = 150},
{index = 6, x = -64.581001281738, z = 36.774002075195, y = 331.84002685547, rotation = 39},
{index = 7, x = 120.1490020752, z = 15.776000976563, y = 155.14100646973, rotation = 177},
{index = 8, x = 324.22500610352, z = 39.661003112793, y = 433.3330078125, rotation = 159},
},
[132] = {--id=132,en="Abyssea - La Theine",
{index = 1, x = -480.00003051758, z = -0.40000000596046, y = 764.00006103516, rotation = 63},
{index = 2, x = -593.81103515625, z = -16.300001144409, y = 30.151000976563, rotation = 180},
{index = 3, x = -122.96600341797, z = -8.6000003814697, y = -38.954002380371, rotation = 31},
{index = 4, x = -54.61600112915, z = 29.200000762939, y = 175.25001525879, rotation = 244},
{index = 5, x = 201.68101501465, z = 23.300001144409, y = -398.15502929688, rotation = 100},
{index = 6, x = 595.37701416016, z = 39.400001525879, y = -507.18603515625, rotation = 10},
{index = 7, x = 494.22302246094, z = 39.600002288818, y = 333.0940246582, rotation = 112},
{index = 8, x = 215.14500427246, z = 15.800001144409, y = -198.91801452637, rotation = 53},
},
[215] = {--id=215,en="Abyssea - Attohwa",
{index = 1, x = -140, z = 19.5, y = -200.00001525879, rotation = 191},
{index = 2, x = -485.50402832031, z = -3.996000289917, y = -4.9400000572205, rotation = 223},
{index = 3, x = 258.90902709961, z = 20.94100189209, y = -21.157001495361, rotation = 131},
{index = 4, x = -603.87701416016, z = -4.3210000991821, y = 191.93600463867, rotation = 0},
{index = 5, x = 466.83102416992, z = 20.555000305176, y = 78.005004882813, rotation = 191},
{index = 6, x = -247.10301208496, z = 13.979001045227, y = 283.57202148438, rotation = 62},
{index = 7, x = 378.84503173828, z = 20, y = -141.94599914551, rotation = 181},
{index = 8, x = 1.4460000991821, z = -3.6520001888275, y = 150.79200744629, rotation = 191},
[0] = {index = 9, x = -280, z = -4.5, y = 0, rotation = 191},
},
[216] = {--id=216,en="Abyssea - Misareaux",
{index = 1, x = 634, z = -16.5, y = 286, rotation = 159},
{index = 2, x = 399.44900512695, z = -6.7550001144409, y = 33.19100189209, rotation = 156},
{index = 3, x = -96.818000793457, z = -33.828002929688, y = 254.32000732422, rotation = 249},
{index = 4, x = 141.42300415039, z = -10.116000175476, y = -222.39100646973, rotation = 95},
{index = 5, x = -40.898002624512, z = -24.068000793457, y = 439.29000854492, rotation = 193},
{index = 6, x = -231.25300598145, z = -32.804000854492, y = 208.75801086426, rotation = 128},
{index = 7, x = 288.97399902344, z = 23.489000320435, y = -407.23400878906, rotation = 193},
{index = 8, x = 648.31103515625, z = -0.016000000759959, y = -476.11102294922, rotation = 31},
[0] = {index = 9, x = 276, z = -16.342000961304, y = 236.00001525879, rotation = 63},
},
[217] = {--id=217,en="Abyssea - Vunkerl",
{index = 1, x = -322.00003051758, z = -40.523002624512, y = 676.00006103516, rotation = 127},
{index = 2, x = -24.502000808716, z = -34.138999938965, y = 370.20001220703, rotation = 95},
{index = 3, x = 202.53201293945, z = -31.807001113892, y = 312.14300537109, rotation = 159},
{index = 4, x = -266.89801025391, z = -41.942001342773, y = -111.42200469971, rotation = 63},
{index = 5, x = -118.68200683594, z = -39.89400100708, y = -477.37503051758, rotation = 0},
{index = 6, x = -100.00000762939, z = -56.000003814697, y = -764.01605224609, rotation = 159},
{index = 7, x = -675.13201904297, z = -45.693000793457, y = -555.55200195313, rotation = 223},
{index = 8, x = -291.04000854492, z = -32.020999908447, y = 282.5710144043, rotation = 127},
[0] = {index = 9, x = 158, z = -38.100002288818, y = -158, rotation = 159},
},
[218] = {--id=218,en="Abyssea - Altepa",
{index = 1, x = 404.00003051758, z = -0.30000001192093, y = 288, rotation = 127},
{index = 2, x = 639, z = 0, y = -126.00000762939, rotation = 159},
{index = 3, x = -80, z = 0, y = 437.00003051758, rotation = 63},
{index = 4, x = -323.00003051758, z = 0.87800002098083, y = -263, rotation = 31},
{index = 5, x = -477.00003051758, z = -1, y = -684.00006103516, rotation = 191},
{index = 6, x = -640, z = 0, y = -242.00001525879, rotation = 79},
{index = 7, x = -604, z = -1, y = -39, rotation = 0},
{index = 8, x = -826.00006103516, z = -10, y = -591, rotation = 159},
},
[253] = {--id=253,en="Abyssea - Uleguerand",
{index = 1, x = -202.00001525879, z = -39.900001525879, y = -506.00003051758, rotation = 31},
{index = 2, x = -381.05502319336, z = -25.283000946045, y = -169.20001220703, rotation = 204},
{index = 3, x = -300.77301025391, z = -53.509002685547, y = -34.171001434326, rotation = 58},
{index = 4, x = 137.36601257324, z = 0.10000000149012, y = -368.51901245117, rotation = 243},
{index = 5, x = 576.00805664063, z = -36.076000213623, y = -8.3860006332397, rotation = 228},
{index = 6, x = 338.86001586914, z = -100.28800201416, y = 500.10900878906, rotation = 90},
{index = 7, x = -257.35900878906, z = -176.33500671387, y = 236.791015625, rotation = 23},
{index = 8, x = -582.97705078125, z = -40.378002166748, y = 45.543003082275, rotation = 89},
},
[254] = {--id=254,en="Abyssea - Grauberg",
{index = 1, x = -514, z = 22.417001724243, y = -756.00006103516, rotation = 63},
{index = 2, x = 321.8330078125, z = 31.439001083374, y = -557.98303222656, rotation = 93},
{index = 3, x = 423.95001220703, z = -0.89300006628036, y = -174.13000488281, rotation = 159},
{index = 4, x = -26.465002059937, z = -0.93500006198883, y = -464.54602050781, rotation = 127},
{index = 5, x = -165.41400146484, z = -32.099002838135, y = 405.60803222656, rotation = 137},
{index = 6, x = 102.16500854492, z = 16.461999893188, y = 497.28903198242, rotation = 254},
{index = 7, x = -323.07302856445, z = -127.96900939941, y = 113.65300750732, rotation = 63},
{index = 8, x = 490.77603149414, z = -5.5460004806519, y = 340.56301879883, rotation = 191},
},
}
return {
[288] = { -- Escha - Zi'Tah
{index = 0, x = -343.00003051758, z = -0.070000000298023, y = -172.00001525879, rotation = 0},
{index = 1, x = -303, z = -0.030000001192093, y = 308, rotation = 191},
{index = 2, x = -261, z = 0.6700000166893, y = -16, rotation = 191},
{index = 3, x = -110.00000762939, z = 0.12000000476837, y = -241.00001525879, rotation = 63},
{index = 4, x = 245.00001525879, z = 0.27000001072884, y = -148, rotation = 0},
{index = 5, x = 452.00003051758, z = 1.3900001049042, y = -344.00003051758, rotation = 191},
{index = 6, x = 191.00001525879, z = 0.20000000298023, y = -318, rotation = 0},
{index = 7, x = -134, z = 1.8000000715256, y = -454.00003051758, rotation = 159},
},
[289] = { -- Escha - Ru'Aun
{index = 8, x = 10, z = -34, y = -464.00003051758, rotation = 191},
{index = 9, x = -275.5, z = -40.500003814697, y = -378.50003051758, rotation = 223},
{index = 10, x = -454.00003051758, z = -3.5000002384186, y = -147.5, rotation = 127},
{index = 11, x = -452.50003051758, z = -71.42000579834, y = -307.5, rotation = 223},
{index = 12, x = -444.50003051758, z = -40.500003814697, y = 144, rotation = 0},
{index = 13, x = -280.5, z = -3.5000002384186, y = 386.50003051758, rotation = 159},
{index = 14, x = -431.50003051758, z = -71.850006103516, y = 335.50003051758, rotation = 31},
{index = 15, x = 0, z = -40.500003814697, y = 466.50003051758, rotation = 63},
{index = 16, x = 278.5, z = -3.6300001144409, y = 384.00003051758, rotation = 223},
{index = 17, x = 186.00001525879, z = -71.850006103516, y = 514.5, rotation = 95},
{index = 18, x = 444.50003051758, z = -40, y = 144, rotation = 127},
{index = 19, x = 454.50003051758, z = -3.6000001430511, y = -147.5, rotation = 0},
{index = 20, x = 546.5, z = -71.5, y = -17, rotation = 127},
{index = 21, x = 275, z = -40.500003814697, y = -377.50003051758, rotation = 159},
{index = 22, x = -1.2000000476837, z = -52.000003814697, y = -581.5, rotation = 191},
},
[291] = { -- Reisenjima
{index = 23, x = -495.44003295898, z = -19, y = -476.48001098633, rotation = 0},
{index = 24, x = -404.00003051758, z = -55.000003814697, y = 86.000007629395, rotation = 63},
{index = 25, x = -530.40002441406, z = -50.000003814697, y = 399.75003051758, rotation = 95},
{index = 26, x = -554.40002441406, z = -48.750003814697, y = 602, rotation = 191},
{index = 27, x = 107.00000762939, z = -75.400001525879, y = 599, rotation = 63},
{index = 28, x = 243.50001525879, z = -87.400001525879, y = 106.00000762939, rotation = 127},
{index = 29, x = 641.60003662109, z = -374.00003051758, y = -912.20007324219, rotation = 159},
{index = 30, x = -368.72003173828, z = -113.30000305176, y = 212.45001220703, rotation = 63, scintillating = true},
{index = 31, x = -581, z = -417.40002441406, y = -1065, rotation = 0},
{index = 32, x = -390.22003173828, z = -439.71002197266, y = -835.13006591797, rotation = 0, scintillating = true},
}
}
return {
['Southern San d\'Oria'] = {
{index = 0, content = 0, zone = 230, x = -84.468002319336, z = 1, y = -65.454002380371, rotation = 95},
{index = 1, content = 0, zone = 230, x = 45.000003814697, z = 2, y = -34, rotation = 63},
{index = 2, content = 0, zone = 230, x = 140, z = -2, y = 124.00000762939, rotation = 63},
{index = 97, content = 0, zone = 230, x = -164.00001525879, z = -1, y = 11.000000953674, rotation = 127},
},
['Northern San d\'Oria'] = {
{index = 3, content = 0, zone = 231, x = -179.10101318359, z = 4, y = 71.279006958008, rotation = 0},
{index = 4, content = 0, zone = 231, x = 10, z = -0.20000000298023, y = 94.000007629395, rotation = 191},
{index = 5, content = 0, zone = 231, x = 69, z = -0.20000000298023, y = 9, rotation = 223},
{index = 98, content = 0, zone = 231, x = -134, z = 12.000000953674, y = 195.00001525879, rotation = 0},
},
['Port San d\'Oria'] = {
{index = 6, content = 0, zone = 232, x = -38, z = -4, y = -64, rotation = 191},
{index = 7, content = 0, zone = 232, x = 49.000003814697, z = -12.000000953674, y = -106.00000762939, rotation = 159},
{index = 8, content = 0, zone = 232, x = -6.0000004768372, z = -13.000000953674, y = -151, rotation = 191},
},
['Bastok Mines'] = {
{index = 9, content = 0, zone = 234, x = 38.189002990723, z = 0, y = -42.618003845215, rotation = 0},
{index = 10, content = 0, zone = 234, x = 117.00000762939, z = 1, y = -58.000003814697, rotation = 0},
{index = 99, content = 0, zone = 234, x = 86.000007629395, z = 7.0000004768372, y = 1, rotation = 0},
},
['Bastok Markets'] = {
{index = 11, content = 0, zone = 235, x = -343.00003051758, z = -10, y = -156, rotation = 159},
{index = 12, content = 0, zone = 235, x = -329.00003051758, z = -12.000000953674, y = -33, rotation = 0},
{index = 13, content = 0, zone = 235, x = -189.00001525879, z = -8, y = 27.000001907349, rotation = 63},
{index = 100, content = 0, zone = 235, x = -190.00001525879, z = -6.0000004768372, y = -68, rotation = 95},
},
['Port Bastok'] = {
{index = 14, content = 0, zone = 236, x = 125.00000762939, z = 8.5, y = 7.0000004768372, rotation = 223},
{index = 15, content = 0, zone = 236, x = 41.000003814697, z = 8.5, y = -238.00001525879, rotation = 127},
{index = 101, content = 0, zone = 236, x = -126.00000762939, z = -6.0000004768372, y = 11.000000953674, rotation = 95},
},
['Metalworks'] = {
{index = 16, content = 0, zone = 237, x = 45.000003814697, z = -14.000000953674, y = -18, rotation = 63},
{index = 102, content = 0, zone = 237, x = -77, z = 2, y = 3.0000002384186, rotation = 127},
},
['Windurst Waters'] = {
{index = 17, content = 0, zone = 238, x = -33.022003173828, z = -5, y = 131.74101257324, rotation = 0},
{index = 18, content = 0, zone = 238, x = 137, z = 0, y = -14.000000953674, rotation = 0},
{index = 103, content = 0, zone = 238, x = 4, z = -4, y = -175.00001525879, rotation = 0},
{index = 118, content = 0, zone = 238, x = -92.000007629395, z = -2, y = 53.000003814697, rotation = 191},
},
['Windurst Walls'] = {
{index = 19, content = 0, zone = 239, x = -73.069999694824, z = -5.0130000114441, y = 124.78400421143, rotation = 0},
{index = 20, content = 0, zone = 239, x = -212.00001525879, z = 0, y = -100.00000762939, rotation = 191},
{index = 21, content = 0, zone = 239, x = 31.000001907349, z = -6.5000004768372, y = -39, rotation = 63},
},
['Port Windurst'] = {
{index = 22, content = 0, zone = 240, x = -188.00001525879, z = -4, y = 100.00000762939, rotation = 191},
{index = 23, content = 0, zone = 240, x = -208.00001525879, z = -8.1600008010864, y = 209.00001525879, rotation = 223},
{index = 24, content = 0, zone = 240, x = 179.00001525879, z = -12.000000953674, y = 226.00001525879, rotation = 0},
},
['Windurst Woods'] = {
{index = 25, content = 0, zone = 241, x = 10.088000297546, z = -2.5, y = 0.61700004339218, rotation = 95},
{index = 26, content = 0, zone = 241, x = 108.00000762939, z = -5, y = -56.000003814697, rotation = 127},
{index = 27, content = 0, zone = 241, x = -92.000007629395, z = -5, y = 63.000003814697, rotation = 63},
{index = 28, content = 0, zone = 241, x = 75, z = -7.5000004768372, y = -139, rotation = 127},
{index = 119, content = 0, zone = 241, x = -44.500003814697, z = 0, y = -145, rotation = 0},
},
['Ru\'Lude Gardens'] = {
{index = 29, content = 0, zone = 243, x = -6.0000004768372, z = 3.0000002384186, y = -1, rotation = 191},
{index = 30, content = 0, zone = 243, x = 53.000003814697, z = 9, y = -56.000003814697, rotation = 63},
{index = 31, content = 0, zone = 243, x = -67, z = 6.0000004768372, y = -26.000001907349, rotation = 191},
},
['Upper Jeuno'] = {
{index = 32, content = 0, zone = 244, x = -99.981002807617, z = 0, y = 167.56901550293, rotation = 0},
{index = 33, content = 0, zone = 244, x = 31.000001907349, z = -1, y = -44.000003814697, rotation = 0},
{index = 34, content = 0, zone = 244, x = -52.000003814697, z = 1, y = 15.000000953674, rotation = 191},
},
['Lower Jeuno'] = {
{index = 35, content = 0, zone = 245, x = -99.588005065918, z = 0, y = -183.416015625, rotation = 0},
{index = 36, content = 0, zone = 245, x = 19, z = -1, y = 53.000003814697, rotation = 159},
},
['Port Jeuno'] = {
{index = 37, content = 0, zone = 246, x = 36.076000213623, z = 0, y = 8.831000328064, rotation = 0},
{index = 38, content = 0, zone = 246, x = -155, z = -1, y = -3.0000002384186, rotation = 63},
},
['Tavnazian Safehold'] = {
{index = 64, content = 2, zone = 26, x = -2.25, z = -27.907001495361, y = 106.42500305176, rotation = 223},
{index = 120, content = 2, zone = 26, x = 13.000000953674, z = -10, y = -5, rotation = 0},
{index = 121, content = 2, zone = 26, x = 74.590003967285, z = -36.150001525879, y = 38.870002746582, rotation = 127},
},
['Aht Urhgan Whitegate'] = {
{index = 65, content = 3, zone = 50, x = -20.130001068115, z = 0, y = -19.944000244141, rotation = 95},
{index = 106, content = 3, zone = 50, x = 129, z = 0, y = -16, rotation = 0},
{index = 107, content = 3, zone = 50, x = -107.00000762939, z = -6.0000004768372, y = 108.00000762939, rotation = 127},
{index = 108, content = 3, zone = 50, x = -98.000007629395, z = 0, y = -68, rotation = 127},
},
['Bhaflau Thickets'] = {
{index = 74, content = 3, zone = 52}
},
['Western Adoulin'] = {
{index = 44, content = 11, zone = 256, x = -85.435005187988, z = 3.9990000724792, y = -31.303001403809, rotation = 31},
{index = 109, content = 11, zone = 256, x = 30.950000762939, z = 0, y = -163.00001525879, rotation = 31},
},
['Eastern Adoulin'] = {
{index = 45, content = 11, zone = 257, x = -52.857002258301, z = -0.15000000596046, y = 58.877002716064, rotation = 223},
{index = 110, content = 11, zone = 257, x = -50.500003814697, z = -0.15000000596046, y = -95.500007629395, rotation = 95},
},
['Yughott Grotto'] = {
{index = 52, content = 0, zone = 142},
},
['Selbina'] = {
{index = 43, content = 0, zone = 248},
},
['Palborough Mines'] = {
{index = 53, content = 0, zone = 143},
},
['Giddeus'] = {
{index = 54, content = 0, zone = 145},
},
['Toraimarai Canal'] = {
{index = 115, content = 0, zone = 169},
},
['Mhaura'] = {
{index = 40, content = 0, zone = 249},
},
['Attohwa Chasm'] = {
{index = 81, content = 2, zone = 7},
},
['Pso\'Xja'] = {
{index = 82, content = 2, zone = 9},
},
['Fei\'Yin'] = {
{index = 55, content = 0, zone = 204, x = 242.00001525879, z = -24.500001907349, y = 62.000003814697, rotation = 0},
{index = 94, content = 0, zone = 204, x = 102.34400177002, z = -0.11300000548363, y = 269.36199951172, rotation = 191},
},
['Uleguerand Range'] = {
{index = 76, content = 2, zone = 5, x = 64, z = -196.50001525879, y = 181.00001525879, rotation = 0},
{index = 77, content = 2, zone = 5, x = 380.00003051758, z = 23.000001907349, y = -62.600002288818, rotation = 127},
{index = 78, content = 2, zone = 5, x = 424.00003051758, z = -32.5, y = 221.00001525879, rotation = 63},
{index = 79, content = 2, zone = 5, x = 64, z = -96.500007629395, y = 461.00003051758, rotation = 63},
{index = 80, content = 2, zone = 5, x = -220.00001525879, z = -1, y = -62.000003814697, rotation = 0},
},
['Castle Zvahl Keep'] = {
{index = 58, content = 0, zone = 162},
},
['Qufim Island'] = {
{index = 114, content = 0, zone = 126},
},
['Upper Delkfutt\'s Tower'] = {
{index = 71, content = 0, zone = 158},
},
['The Boyahda Tree'] = {
{index = 92, content = 1, zone =153},
},
['Quicksand Caves'] = {
{index = 56, content = 1, zone = 208, x = -984.00006103516, z = 17, y = -290, rotation = 191},
{index = 96, content = 1, zone = 208, x = 573, z = 8.9500007629395, y = -500.00003051758, rotation = 191},
},
['Rabao'] = {
{index = 42, content = 1, zone = 247, x = -29.276000976563, z = 0, y = -77.585006713867, rotation = 191},
{index = 105, content = 1, zone = 247, x = -21.000001907349, z = 8.1300001144409, y = 111.00000762939, rotation = 63},
},
['Cape Teriggan'] = {
{index = 91, content = 1, zone = 113},
},
['Kazham'] = {
{index = 39, content = 1, zone = 250},
},
['Norg'] = {
{index = 41, content = 1, zone = 252, x = -25.910001754761, z = 0.2960000038147, y = -46.164001464844, rotation = 95},
{index = 104, content = 1, zone = 252, x = -65, z = -5.2000002861023, y = 54.000003814697, rotation = 127},
},
['Den of Rancor'] = {
{index = 57, content = 1, zone = 160, x = -79, z = 46.000003814697, y = 62.000003814697, rotation = 127},
{index = 93, content = 1, zone = 160, x = 182.00001525879, z = 34.470001220703, y = -62.000003814697, rotation = 223},
},
['Ifrit\'s Cauldron'] = {
{index = 95, content = 1, zone = 205},
},
['Ru\'Aun Gardens'] = {
{index = 59, content = 1, zone = 130, x = 5, z = -42.000003814697, y = 525, rotation = 191},
{index = 60, content = 1, zone = 130, x = -311, z = -42.000003814697, y = -421.00003051758, rotation = 95},
{index = 61, content = 1, zone = 130, x = -498.00003051758, z = -42.000003814697, y = 167.00001525879, rotation = 127},
{index = 62, content = 1, zone = 130, x = 499.00003051758, z = -42.000003814697, y = 158, rotation = 0},
{index = 63, content = 1, zone = 130, x = 304, z = -42.000003814697, y = -426.00003051758, rotation = 31},
},
['The Shrine of Ru\'Avitau'] = {
{index = 72, content = 1, zone = 178}
},
['Newton Movalpolos'] = {
{index = 83, content = 2, zone = 12},
},
['Misareaux Coast'] = {
{index = 117, content = 2, zone = 25},
},
['Riverne - Site #B01'] = {
{index = 73, content = 2, zone = 29}
},
['Riverne - Site #A01'] = {
{index = 84, content = 2, zone = 30}
},
['Al\'Taieu'] = {
{index = 85, content = 2, zone = 33, x = 7.0000004768372, z = 0, y = 708.00006103516, rotation = 191},
{index = 86, content = 2, zone = 33, x = -531, z = 0, y = 447.00003051758, rotation = 127},
{index = 87, content = 2, zone = 33, x = 569, z = 0, y = 409.00003051758, rotation = 191},
},
['Grand Palace of Hu\'Xzoi'] = {
{index = 88, content = 2, zone = 34}
},
['The Garden of Ru\'Hmet'] = {
{index = 89, content = 2, zone = 35}
},
['Mount Zhayolm'] = {
{index = 90, content = 3, zone = 61}
},
['Nashmau'] = {
{index = 66, content = 3,zone = 53}
},
['Caedarva Mire'] = {
{index = 75, content = 3, zone = 79}
},
['Southern San d\'Oria [S]'] = {
{index = 68, content = 4, zone = 80}
},
['Bastok Markets [S]'] = {
{index = 69, content = 4, zone = 87}
},
['Windurst Waters [S]'] = {
{index = 70, content = 4, zone = 94}
},
['Xarcabard [S]'] = {
{index = 111, content = 4, zone = 137}
},
['Castle Zvahl Keep [S]'] = {
{index = 113, content = 4, zone = 155}
},
['Ceizak Battlegrounds'] = {
{index = 46, content = 11, zone = 261}
},
['Foret de Hennetiel'] = {
{index = 47, content = 11, zone = 262}
},
['Yorcia Weald'] = {
{index = 49, content = 11, zone = 263}
},
['Morimar Basalt Fields'] = {
{index = 48, content = 11, zone = 265}
},
['Marjami Ravine'] = {
{index = 50, content = 11, zone = 266}
},
['Kamihr Drifts'] = {
{index = 51, content = 11, zone = 267}
},
['Leafallia'] = {
{index = 112, content = 11, zone = 281}
},
['Ra\'Kaznar Inner Court'] = {
{index = 116, content = 11, zone = 276}
},
}
return {
['Ru\'lude Gardens'] = {index = 4, zone = 243, cost = 30},
['Selbina'] = {index = 5, zone = 248, cost = 30},
['Mhaura'] = {index = 6, zone = 249, cost = 30},
['Rabao'] = {index = 7, zone = 247, cost = 30},
['Norg'] = {index = 8, zone = 252, cost = 30},
['West Ronfaure'] = {index = 9, zone = 100, cost = 100},
['North Gustaberg'] = {index = 10, zone = 106, cost = 100},
['West Sarutabaruta'] = {index = 11, zone = 115, cost = 100},
['La Theine Plateau'] = {index = 12, zone = 102, cost = 100},
['Konschtat Highlands'] = {index = 13, zone = 108, cost = 100},
['Tahrongi Canyon'] = {index = 14, zone = 117, cost = 100},
['Jugner Forest'] = {index = 15, zone = 104, cost = 100},
['Pashhow Marshlands'] = {index = 16, zone = 109, cost = 100},
['Meriphataud Mountains'] = {index = 17, zone = 119, cost = 100},
['Attohwa Chasm'] = {index = 18, zone = 7, cost = 100},
['Uleguerand Range'] = {index = 19, zone = 5, cost = 100},
['Davoi'] = {index = 20, zone = 149, cost = 300},
['Beadeaux'] = {index = 21, zone = 147, cost = 300},
['Castle Oztroja'] = {index = 22, zone = 151, cost = 300},
['Quicksand Caves'] = {index = 23, zone = 208, cost = 300},
['Sea Serpent Grotto'] = {index = 24, zone = 176, cost = 300},
['Temple of Uggalepih'] = {index = 25, zone = 159, cost = 300},
['The Boyahda Tree'] = {index = 26, zone = 153, cost = 300},
['Oldton Movalpolos'] = {index = 27, zone = 11, cost = 300},
['Riverne - Site #B01'] = {index = 28, zone = 29, cost = 300},
['Castle Zvahl Keep'] = {index = 29, zone = 162, cost = 300},
}
local runic_portals = {
['Azouph Isle staging point'] = {index = 1},
['Dvucca Isle staging point'] = {index = 2},
['Mamool Ja staging point'] = {index = 3},
['Halvung staging point'] = {index = 4},
['Ilrusi Atoll staging point'] = {index = 5},
['Nyzul Isle'] = {index = 6},
}
runic_portals['Leujaoam Sanctum'] = runic_portals['Azouph Isle staging point']
runic_portals['Caedarva Mire'] = runic_portals['Azouph Isle staging point']
runic_portals['Periqia'] = runic_portals['Dvucca Isle staging point']
runic_portals['Caedarva Mire 2'] = runic_portals['Dvucca Isle staging point']
runic_portals['Bhaflau Thickets'] = runic_portals['Mamool Ja staging point']
runic_portals['Lebros Cavern'] = runic_portals['Halvung staging point']
runic_portals['Mount Zhayolm'] = runic_portals['Halvung staging point']
runic_portals['Arrapago Reef'] = runic_portals['Ilrusi Atoll staging point']
runic_portals['Alzadaal Undersea Ruins'] = runic_portals['Nyzul Isle']
return runic_portals
return {
['Northern San d\'Oria'] = {index = 0, unlock_bit = 24, content = 0, zone = 231},
['Bastok Mines'] = {index = 1, unlock_bit = 25, content = 0, zone = 234},
['Port Windurst'] = {index = 2, unlock_bit = 26, content = 0, zone = 240},
['Ru\'Lude Gardens'] = {index = 3, unlock_bit = 27, content = 0, zone = 243},
['Tavnazian Safehold'] = {index = 4, unlock_bit = 83, content = 2, zone = 26},
['Aht Urhgan Whitegate'] = {index = 5, unlock_bit = 84, content = 3, zone = 50},
['West Ronfaure'] = {index = 6, unlock_bit = 0, content = 0, zone = 100},
['Fort Ghelsba'] = {index = 7, unlock_bit = 34, content = 0, zone = 141},
['Bostaunieux Oubliette'] = {index = 8, unlock_bit = 19, content = 0, zone = 167},
['King Ranperre\'s Tomb'] = {index = 9, unlock_bit = 41, content = 0, zone = 190},
['La Theine Plateau'] = {index = 10, unlock_bit = 28, content = 0, zone = 102},
['Valkurm Dunes'] = {index = 11, unlock_bit = 1, content = 0, zone = 103},
['Konschtat Highlands'] = {index = 12, unlock_bit = 30, content = 0, zone = 108},
['Ordelle\'s Caves'] = {index = 13, unlock_bit = 44, content = 0, zone = 193},
['Gusgen Mines'] = {index = 14, unlock_bit = 45, content = 0, zone = 196},
['Carpenters\' Landing'] = {index = 15, unlock_bit = 55, content = 0, zone = 2},
['Jugner Forest'] = {index = 16, unlock_bit = 2, content = 0, zone = 104},
['Batallia Downs'] = {index = 17, unlock_bit = 29, content = 0, zone = 105},
['Davoi'] = {index = 18, unlock_bit = 36, content = 0, zone = 149},
['The Eldieme Necropolis'] = {index = 19, unlock_bit = 21, content = 0, zone = 195},
['North Gustaberg'] = {index = 20, unlock_bit = 3, content = 0, zone = 106},
['Zeruhn Mines'] = {index = 21, unlock_bit = 96, content = 0, zone = 172},
['Korroloka Tunnel'] = {index = 22, unlock_bit = 50, content = 1, zone = 173},
['Dangruf Wadi'] = {index = 23, unlock_bit = 42, content = 0, zone = 191},
['Pashhow Marshlands'] = {index = 24, unlock_bit = 4, content = 0, zone = 109},
['Rolanberry Fields'] = {index = 25, unlock_bit = 31, content = 0, zone = 110},
['Beadeaux'] = {index = 26, unlock_bit = 35, content = 0, zone = 147},
['Crawlers\' Nest'] = {index = 27, unlock_bit = 22, content = 0, zone = 197},
['West Sarutabaruta'] = {index = 28, unlock_bit = 5, content = 0, zone = 115},
['Toraimarai Canal'] = {index = 29, unlock_bit = 20, content = 0, zone = 169},
['Inner Horutoto Ruins'] = {index = 30, unlock_bit = 43, content = 0, zone = 192},
['Bibiki Bay'] = {index = 31, unlock_bit = 56, content = 0, zone = 4},
['Tahrongi Canyon'] = {index = 32, unlock_bit = 32, content = 0, zone = 117},
['Buburimu Peninsula'] = {index = 33, unlock_bit = 6, content = 0, zone = 118},
['Maze of Shakhrami'] = {index = 34, unlock_bit = 46, content = 0, zone = 198},
['Labyrinth of Onzozo'] = {index = 35, unlock_bit = 54, content = 1, zone = 213},
['Meriphataud Mountains'] = {index = 36, unlock_bit = 10, content = 0, zone = 119},
['Sauromugue Champaign'] = {index = 37, unlock_bit = 33, content = 0, zone = 120},
['Castle Oztroja'] = {index = 38, unlock_bit = 37, content = 0, zone = 151},
['Garlaige Citadel'] = {index = 39, unlock_bit = 23, content = 0, zone = 200},
['Beaucedine Glacier'] = {index = 40, unlock_bit = 7, content = 0, zone = 111},
['Ranguemont Pass'] = {index = 41, unlock_bit = 39, content = 0, zone = 166},
['Xarcabard'] = {index = 42, unlock_bit = 8, content = 0, zone = 112},
['Castle Zvahl Baileys'] = {index = 43, unlock_bit = 38, content = 0, zone = 161},
['Qufim Island'] = {index = 44, unlock_bit = 9, content = 0, zone = 126},
['Behemoth\'s Dominion'] = {index = 45, unlock_bit = 92, content = 0, zone = 127},
['Lower Delkfutt\'s Tower'] = {index = 46, unlock_bit = 40, content = 0, zone = 184},
['The Sanctuary of Zi\'Tah'] = {index = 47, unlock_bit = 11, content = 1, zone = 121},
['Ro\'Maeve'] = {index = 48, unlock_bit = 47, content = 1, zone = 122},
['Dragon\'s Aery'] = {index = 49, unlock_bit = 93, content = 1, zone = 154},
['Eastern Altepa Desert'] = {index = 50, unlock_bit = 12, content = 1, zone = 114},
['Western Altepa Desert'] = {index = 51, unlock_bit = 48, content = 1, zone = 125},
['Rabao'] = {index = 52, unlock_bit = 82, content = 1, zone = 247},
['Cape Teriggan'] = {index = 53, unlock_bit = 13, content = 1, zone = 113},
['Valley of Sorrows'] = {index = 54, unlock_bit = 94, content = 1, zone = 128},
['Kuftal Tunnel'] = {index = 55, unlock_bit = 51, content = 1, zone = 174},
['Gustav Tunnel'] = {index = 56, unlock_bit = 53, content = 1, zone = 212},
['Yuhtunga Jungle'] = {index = 57, unlock_bit = 14, content = 1, zone = 123},
['Sea Serpent Grotto'] = {index = 58, unlock_bit = 52, content = 1, zone = 176},
['Kazham'] = {index = 59, unlock_bit = 80, content = 1, zone = 250},
['Norg'] = {index = 60, unlock_bit = 81, content = 1, zone = 252},
['Yhoator Jungle'] = {index = 61, unlock_bit = 15, content = 1, zone = 124},
['Temple of Uggalepih'] = {index = 62, unlock_bit = 49, content = 1, zone = 159},
['Ifrit\'s Cauldron'] = {index = 63, unlock_bit = 95, content = 1, zone = 205},
['Ru\'Aun Gardens'] = {index = 64, unlock_bit = 17, content = 1, zone = 130},
['Oldton Movalpolos'] = {index = 65, unlock_bit = 18, content = 2, zone = 11},
['Lufaise Meadows'] = {index = 66, unlock_bit = 16, content = 2, zone = 24},
['Misareaux Coast'] = {index = 67, unlock_bit = 57, content = 2, zone = 25},
['Phomiuna Aqueducts'] = {index = 68, unlock_bit = 58, content = 2, zone = 27},
['Sacrarium'] = {index = 69, unlock_bit = 59, content = 2, zone = 28},
['Wajaom Woodlands'] = {index = 70, unlock_bit = 60, content = 3, zone = 51},
['Mamook'] = {index = 71, unlock_bit = 61, content = 3, zone = 65},
['Aydeewa Subterrane'] = {index = 72, unlock_bit = 62, content = 3, zone = 68},
['Halvung'] = {index = 73, unlock_bit = 91, content = 3, zone = 62},
['Nashmau'] = {index = 74, unlock_bit = 85, content = 3, zone = 53},
['Arrapago Reef'] = {index = 75, unlock_bit = 90, content = 3, zone = 54},
['Caedarva Mire'] = {index = 76, unlock_bit = 89, content = 3, zone = 79},
['Southern San d\'Oria [S]'] = {index = 77, unlock_bit = 86, content = 4, zone = 80},
['East Ronfaure [S]'] = {index = 78, unlock_bit = 63, content = 4, zone = 81},
['Jugner Forest [S]'] = {index = 79, unlock_bit = 64, content = 4, zone = 82},
['Batallia Downs [S]'] = {index = 80, unlock_bit = 66, content = 4, zone = 84},
['The Eldieme Necropolis [S]'] = {index = 81, unlock_bit = 79, content = 4, zone = 175},
['North Gustaberg [S]'] = {index = 83, unlock_bit = 67, content = 4, zone = 88},
['Grauberg [S]'] = {index = 84, unlock_bit = 68, content = 4, zone = 89},
['Vunkerl Inlet [S]'] = {index = 85, unlock_bit = 65, content = 4, zone = 83},
['Pashhow Marshlands [S]'] = {index = 86, unlock_bit = 69, content = 4, zone = 90},
['Rolanberry Fields [S]'] = {index = 87, unlock_bit = 70, content = 4, zone = 91},
['Crawlers\' Nest [S]'] = {index = 88, unlock_bit = 78, content = 4, zone = 171},
['Windurst Waters [S]'] = {index = 89, unlock_bit = 88, content = 4, zone = 94},
['West Sarutabaruta [S]'] = {index = 90, unlock_bit = 71, content = 4, zone = 95},
['Fort Karugo-Narugo [S]'] = {index = 91, unlock_bit = 72, content = 4, zone = 96},
['Meriphataud Mountains [S]'] = {index = 92, unlock_bit = 73, content = 4, zone = 97},
['Sauromugue Champaign [S]'] = {index = 93, unlock_bit = 74, content = 4, zone = 98},
['Garlaige Citadel [S]'] = {index = 94, unlock_bit = 77, content = 4, zone = 164},
['Beaucedine Glacier [S]'] = {index = 95, unlock_bit = 75, content = 4, zone = 136},
['Castle Zvahl Baileys [S]'] = {index = 96, unlock_bit = 76, content = 4, zone = 138},
['Eastern Adoulin'] = {index = 97, unlock_bit = 97, content = 11, zone = 257},
}
_addon.author = 'Ivaar'
_addon.name = 'Transwarp'
_addon.version = '0.0.0.4'
_addon.commands = {'tw'}
require('luau')
require('pack')
packets = require('packets')
alias = require('alias')
maps = {
homepoints = require('homepoints'),
survival_guides = require('survival_guides'),
waypoints = require('waypoints'),
confluxes = require('confluxes'),
eschan_portals = require('eschan_portals'),
proto_waypoints = require('proto_waypoints'),
abyssea_warp = require('abyssea_warp'),
runic_portal = require('runic_portals'),
voidwatch = require('voidwatch'),
unity = require('unity'),
}
local last_attempt = os.time() - 10
local send_all_delay = 1
local retry_delay = 3
local retry_limit = 5
local enable_injection = true
local queued = {}
local function build_packet(p)
if enable_injection then
packets.inject(p)
elseif p._id ~= 0x1A and p._id ~= 0x114 then
queued = queued or {}
queued[#queued+1] = packets.build(p)
end
end
local function build_dialog_option(p)
return packets.new('outgoing', 0x05B, {
['Target'] = p['NPC'],
['Target Index'] = p['NPC Index'],
['Zone'] = p['Zone'],
['Menu ID'] = p['Menu ID'],
['Automated Message'] = true
})
end
local function npc_warp_request(p, action, option)
build_packet( packets.new('outgoing', 0x05C, {
['Target ID'] = p['NPC'],
['Target Index'] = p['NPC Index'],
['Zone'] = p['Zone'],
['Menu ID'] = p['Menu ID'],
['X'] = action.x,
['Y'] = action.y,
['Z'] = action.z,
['_unknown1'] = option,
['_unknown2'] = 1,
['Rotation'] = action.rotation
}))
end
local function interact_npc(target)
last_attempt = os.time()
notice('Initiating NPC Interaction: %s':format(target.name))
packets.inject( packets.new('outgoing', 0x01A, {['Target'] = target.id, ['Target Index'] = target.index}))
end
string.has_bit = function(data, position)
return data:unpack('q', math.floor(position/8)+1, position%8+1)
end
math.has_bit = function(mask, offset)
return math.floor(mask/2^offset)%2 == 1
end
local handled_menus = {}
handled_menus.homepoints = {
npcs = S{'Home Point #1','Home Point #2','Home Point #3','Home Point #4','Home Point #5'},
ids = S{8700,8701,8702,8703,8704},
zones = S{230,231,232,234,235,236,237,238,239,240,241,243,244,245,246,250,249,252,247,248,256,257,261,262,265,263,266,267,142,143,
145,204,208,160,162,130,26,50,53,80,87,94,158,178,29,52,79,5,7,9,12,30,33,34,35,61,113,153,205,137,281,155,126,169,276,25},
}
handled_menus.survival_guides = {
npcs = S{'Survival Guide'},
ids = S{8500,8501},
zones = S{231,234,240,243,26,50,100,141,167,190,102,103,108,193,196,2,104,105,149,195,106,172,173,191,109,110,147,197,115,169,
192,4,117,118,198,213,119,120,151,200,111,166,112,161,126,127,184,121,122,154,114,125,247,113,128,174,212,123,176,250,252,
124,159,205,130,11,24,25,27,28,51,65,68,62,53,54,79,80,81,82,84,175,87,88,89,83,90,91,171,94,95,96,97,98,164,136,138,257},
}
handled_menus.waypoints = {
npcs = S{'Waypoint'},
zones = {
[245] = S{10121},
[256] = S{5000,5001,5002,5003,5004,5005,5006,5007,5008},
[257] = S{5000,5001,5002,5003,5004,5005,5006,5007,5008},
[260] = S{5000,5001,5002,5003},
[261] = S{5000,5001,5002,5003},
[262] = S{5000,5001,5002,5003,5004},
[263] = S{5000,5001,5002,5003},
[265] = S{5000,5001,5002,5003,5004,5005},
[266] = S{5000,5001,5002,5003,5004},
[267] = S{5000,5001,5002,5003,5004},
},
}
handled_menus.proto_waypoints = {
npcs = S{'Proto-Waypoint'},
zones = {
[243] = S{10209},
[247] = S{141},
[248] = S{10012},
[249] = S{345},
[252] = S{266},
},
}
handled_menus.eschan_portals = {
npcs = {
['Eschan Portal'] = true,
['Ethereal Ingress'] = true,
contains = function(names, str)
return names[str:gsub('[%#%d]', ''):trim()] == true
end
},
ids = S{9100},
zones = S{288,289,291},
}
handled_menus.confluxes = {
npcs = {
['Veridical Conflux'] = true,
contains = function(names, str)
return names[str:sub(1, 17)] == true
end
},
zones = {
[15] = S{2132,2133,2134,2135,2136,2137,2138,2139},
[45] = S{2132,2133,2134,2135,2136,2137,2138,2139},
[132] = S{2132,2133,2134,2135,2136,2137,2138,2139},
[215] = S{2132,2133,2134,2135,2136,2137,2138,2139,123},
[216] = S{2132,2133,2134,2135,2136,2137,2138,2139,123},
[217] = S{2132,2133,2134,2135,2136,2137,2138,2139,123},
[218] = S{2132,2133,2134,2135,2136,2137,2138,2139},
[253] = S{2132,2133,2134,2135,2136,2137,2138,2139},
[254] = S{2132,2133,2134,2135,2136,2137,2138,2139},
},
}
handled_menus.elvorseal = {
npcs = S{'Affi', 'Dremi', 'Shiftrix'},
ids = S{9701},
zones = S{288,289,291},
}
handled_menus.unity = {
npcs = S{'Urbiolaine', 'Igsli', 'Teldro-Kesdrodo', 'Nunaarl Bthtrogg'},
zones = {
[230] = S{3529},
[235] = S{598},
[241] = S{879},
[256] = S{5149}
},
}
handled_menus.voidwatch = {
npcs = S{'Atmacite Refiner'},
zones = {
[80] = S{657},
[230] = S{962},
}
}
handled_menus.runic_portal = {
npcs = S{'Runic Portal'},
zones = {
[50] = S{101},
[52] = S{109},
[54] = S{109},
[61] = S{109},
[72] = S{117,118},
[79] = S{131,134},
}
}
handled_menus.abyssea_warp = {
npcs = S{'Horst', 'Ivan', 'Willis', 'Ernst', 'Vincent'},
zones = {
[232] = S{795},
[236] = S{404},
[240] = S{873},
[243] = S{10185},
[246] = S{339},
}
}
handled_menus.enter = {
npcs = S{'Undulating Confluence', 'Cavernous Maw', 'Dimensional Portal'},
zones = {
[25] = S{14},
[126] = S{65},
[103] = S{55},
[102] = S{218,222},
[104] = S{47},
[106] = S{908},
[107] = S{914},
[108] = S{107,926},
[112] = S{204},
[117] = S{100,926},
[118] = S{61},
},
reisenjima = {[102] = 222,[108] = 926,[117] = 926}
}
local events = {}
events.homepoints = function(p, packet)
local unlocks = p['Menu Parameters']:unpack('A16', 5)
local gil = p['Menu Parameters']:unpack('i', 21)
local enabled_expansions = p['Menu Parameters']:unpack('A2', 25)
local current_index = p['Menu Parameters']:unpack('C', 29)
local rhapsody_in_white = p['Menu Parameters']:unpack('q', 31, 2)
packet['Option Index'] = 8
build_packet( packet)
packet['Option Index'] = 0
packet['_unknown1'] = 0x4000
action.cost = 1000 -- FIX ME
local teleport_cost = rhapsody_in_white and action.cost * 0.2 or action.cost
if not action.index then
packet['Option Index'] = 1
packet['_unknown1'] = 0
elseif current_index == action.index then
notice('You are already at that teleport')
elseif gil < teleport_cost then
notice('You do not have enough gil.')
elseif not unlocks:has_bit(action.index) then
notice('You have not unlocked the destination teleport')
elseif not enabled_expansions:has_bit(action.content) then
notice('You do not have that expansion registered')
else
build_packet( packets.new('outgoing', 0x114))
packet['Option Index'] = 2
packet['_unknown1'] = action.index
build_packet( packet)
if action.zone == p['Zone'] then
npc_warp_request(p, action, bit.bor(3, bit.lshift(action.index, 16)))
packet['Option Index'] = 3
packet['_unknown1'] = 0
end
end
packet['Automated Message'] = false
build_packet( packet)
end
events.survival_guides = function(p, packet)
local current_index = p['Menu Parameters']:unpack('C', 5)
local thrifty_transit = p['Menu Parameters']:unpack('q', 6, 3)
local rhapsody_in_white = p['Menu Parameters']:unpack('q', 6, 6)
local valor_points = p['Menu Parameters']:unpack('H', 7)
local gil = p['Menu Parameters']:unpack('i', 9)
local unlocks = p['Menu Parameters']:unpack('A16', 13)
local enabled_expansions = p['Menu Parameters']:unpack('A2', 29)
local teleport_cost = thrifty_transit and 0 or rhapsody_in_white and 200 or 1000
local tab_cost = rhapsody_in_white and 10 or 50
if current_index == action.index then
notice('You are already at that teleport')
elseif gil < teleport_cost then
notice('You do not have enough gil.')
elseif not unlocks:has_bit(action.unlock_bit) then
notice('You have not unlocked the destination teleport')
elseif not enabled_expansions:has_bit(action.content) then
notice('You do not have that expansion registered')
else
build_packet( packets.new('outgoing', 0x114))
packet['Option Index'] = 7
build_packet( packet)
packet['Option Index'] = 1
build_packet( packet)
packet['_unknown1'] = action.index
end
packet['Automated Message'] = false
build_packet( packet)
end
local waypoint_unlocks = {
[01] = {'b9', 5, 1},
[02] = {'b9', 6, 8},
[12] = {'b32', 9, 1},
[03] = {'b4', 13, 1},
[04] = {'b4', 13, 7},
[05] = {'b5', 17, 1},
[06] = {'b6', 17, 7},
[07] = {'b4', 21, 1},
[08] = {'b5', 21, 7},
[11] = {'b6', 25, 1},
[09] = {'b5', 25, 7},
}
local has_waypoint = function(params, category, point)
if category == 10 then
return true
end
local unlocks = params:unpack(unpack(waypoint_unlocks[category]))
if category == 12 then
return bit.bnot(unlocks):has_bit(point)
end
return unlocks:has_bit(point - 1)
end
events.waypoints = function(p, packet)
local current_index = p['Menu Parameters']:byte(1)
local kinetic_cost_adjustment = p['Menu Parameters']:unpack('b2', 2, 6)
local kinetic_units, unlocks = p['Menu Parameters']:unpack('HA24', 3)
local current_category = math.max(1, math.floor(current_index/10))
local current_point = current_index % 10
--[[
local current_category = {
[256] = 1,
[257] = 2,
[261] = 3,
[260] = 4,
[262] = 5,
[265] = 6,
[263] = 7,
[266] = 8,
[267] = 9,
[245] = 10,
}[p.Zone]
]]
local teleport_cost = ({
{1,1,50,50,50,50,50,50,50,15,150,100},
{1,1,50,50,50,50,50,50,50,15,150,100},
{15,15,2},
{15,15,[4]=2},
{15,15,[5]=2},
{15,15,[6]=2},
{15,15,[7]=2},
{15,15,[8]=2},
{15,15,[9]=2},
{15,15}
}[current_category] or {})[action.category]
if current_category == action.category and current_point == action.point then
notice('You are already at that teleport')
elseif not teleport_cost then
notice('You can not travel to that destination from this area')
elseif kinetic_cost_adjustment ~= 2 then
notice('Kinetic Unit Cost Adjustment II is not active')
elseif kinetic_units < teleport_cost then
notice('You do not have enough kinetic units.')
elseif not has_waypoint(p['Menu Parameters'], action.category, action.point) then
notice('You have not unlocked the destination teleport')
else
build_packet( packets.new('outgoing', 0x114))
packet['Option Index'] = current_index % 2^7 + action.category * 2^7 + action.point * 2^11
packet['_unknown1'] = teleport_cost * 2^5
build_packet( packet)
if action.category == current_category then
npc_warp_request(p, action, 0)
packet['Option Index'] = action.category > 2 and 1002 or 0
else
packet['Option Index'] = action.index
end
packet['_unknown1'] = 0
end
packet['Automated Message'] = false
build_packet( packet)
end
events.proto_waypoints = function(p, packet)
local unlocks = p['Menu Parameters']:unpack('A4')
--local zone_id = p['Menu Parameters']:unpack('H', 9)
local kinetic_units = p['Menu Parameters']:unpack('i', 13)
if p.Zone == action.zone then
notice('You are already at that teleport')
elseif kinetic_units < action.cost then
notice('You do not have enough kinetic units.')
elseif not unlocks:has_bit(action.index - 4) then
notice('You have not unlocked the destination teleport')
else
packet['Option Index'] = action.index
build_packet( packet)
end
packet['Automated Message'] = false
build_packet( packet)
end
events.eschan_portals = function(p, packet)
-- teleport = 1,
-- use_escha_silt = 2,
-- use_eschan_droplets = 3,
-- use_scintillating_rhapsody = 4,
local unlocks = p['Menu Parameters']:unpack('I', 5)
local zone_id = p['Menu Parameters']:unpack('I', 9)
local current_index = p['Menu Parameters']:unpack('I', 13)
--local new_teleport = p['Menu Parameters']:unpack('q', 17)
--local has_eschan_droplets = p['Menu Parameters']:unpack('q', 17, 2)
local has_scintillating = p['Menu Parameters']:unpack('q', 17, 3)
local silt = p['Menu Parameters']:unpack('i', 21)
local teleport_cost = p['Menu Parameters']:unpack('i', 25)
local use_scintillating_rhapsody = action.scintillating and has_scintillating
if current_index == action.index then
notice('You are already at that teleport')
elseif silt < teleport_cost then
notice('You do not have enough silt.')
elseif not use_scintillating_rhapsody and not unlocks:has_bit(action.index) then
notice('You have not unlocked the destination teleport')
else
build_packet( packets.new('outgoing', 0x114))
packet['Option Index'] = 1
packet['_unknown1'] = action.index
build_packet( packet)
local option = use_scintillating_rhapsody and 4 or 2
npc_warp_request(p, action, bit.bor(option, bit.lshift(action.index, 16)))
packet['Option Index'] = option
packet['_unknown1'] = 0
end
packet['Automated Message'] = false
build_packet( packet)
end
events.elvorseal = function(p, packet)
local dragon_state = p['Menu Parameters']:unpack('b3') -- 1 and 6 - coming soon, 2 and 7 - shown up
local dragon_hpp = p['Menu Parameters']:unpack('b7', 1, 4)
--local unknown = p['Menu Parameters']:unpack('b21', 2, 3)
local has_elvorseal = p['Menu Parameters']:unpack('q', 4, 8)
local silt = p['Menu Parameters']:unpack('i', 5)
--local zone_index = p['Menu Parameters']:unpack('C', 11) -- 0 based, used to lookup teleport destinations
local can_select_options = p['Menu Parameters']:unpack('q', 12, 2)
local elvorseal_available = {[1]=true,[2]=true,[6]=true,[7]=true}[dragon_state]
local destination = {
[288] = {x = -2, z = 0, y = 59.500003814697, rotation = 63}, -- Zitah
[289] = {x = 0, z = -43.600002288818, y = -238.00001525879, rotation = 191}, -- Ru'Aun
[291] = {x = 640, z = -372.00003051758, y = -921.00006103516, rotation = 95}, -- Reisenjima
}[p.Zone]
--print(dragon_hpp)
packet['Option Index'] = 14
build_packet( packet)
packet['Option Index'] = 8
build_packet( packet)
if can_select_options then
packet['Option Index'] = 9
build_packet( packet)
if elvorseal_available then
if not has_elvorseal then
packet['Option Index'] = 9
build_packet( packet)
packet['Option Index'] = 10
build_packet( packet)
end
packet['Option Index'] = 11
build_packet( packet)
npc_warp_request(p, destination, 12)
packet['Option Index'] = 12
else
packet['Option Index'] = 0
packet['_unknown1'] = 0x4000
notice('Elvorseal is not currently available')
end
else
packet['Option Index'] = 0
packet['_unknown1'] = 0x4000
notice('You have not selected to hear various explanations at this NPC... unable to proceed')
end
packet['Automated Message'] = false
build_packet( packet)
end
events.unity = function(p, packet)
local accolades = p['Menu Parameters']:unpack('i', 9)
local unlocks = p['Menu Parameters']:unpack('A', 25)
local expansions = p['Menu Parameters']:unpack('A2', 29)
packet['Option Index'] = 10
build_packet( packet)
packet['Option Index'] = 0
if action.unlock_bit and not unlocks:has_bit(action.unlock_bit) then
notice('You have not unlocked the destination teleport')
elseif not expansions:has_bit(action.content) then
notice('You do not have that expansion registered')
elseif accolades < 200 then
notice('You do not have enough Accolades.')
else
packet['Option Index'] = 7
build_packet( packet)
packet['Option Index'] = action.option
end
packet['Automated Message'] = false
build_packet( packet)
end
events.runic_portal = function(p, packet)
if p['Zone'] == 50 then
if p['Menu ID'] == 101 then
local runic_permit, unlocks, merc_ranks, imperial_standing, free_portal_use, astral_candescence, has_permit = p['Menu Parameters']:unpack('i7')
if not action.index then
notice('Unable to confirm destination')
elseif not unlocks:has_bit(action.index) then
notice('You have not unlocked the destination teleport')
elseif astral_candescence == 0 then
packet['Option Index'] = action.index + 100
elseif free_portal_use == 1 then
packet['Option Index'] = action.index
elseif imperial_standing >= 200 then
packet['Option Index'] = action.index + 1000
else
notice('You do not have enough Imperial Standing.')
end
elseif p['Menu ID'] >= 120 and p['Menu ID'] <= 125 then
if action.index and p['Menu ID']-119 ~= action.index then
notice('Assault orders prevent you from traveling to that destination')
else
notice('Confirming orders')
packet['Option Index'] = 1
end
end
else
packet['Option Index'] = 0
build_packet( packet)
packet['Option Index'] = 1
end
packet['Automated Message'] = false
build_packet( packet)
end
events.confluxes = function(p, packet)
local conflux_costs = {p['Menu Parameters']:unpack('H8')}
local unlocks = p['Menu Parameters']:unpack('I', 17)
local current_index = p['Menu Parameters']:unpack('I', 21) + 1
local conflux_state = p['Menu Parameters']:unpack('I', 25) -- 1 = activated, 2 = unactivated
local cruor = p['Menu Parameters']:unpack('i', 29)
if conflux_state == 2 then
if conflux_costs[current_index] <= cruor then
packet['Option Index'] = 1
notice('Activating conflux')
else
notice('You do not have enough Cruor.')
end
elseif action.index ~= 9 and conflux_costs[action.index] > cruor then
notice('You do not have enough Cruor.')
elseif current_index == action.index then
notice('You are already at that teleport')
elseif not unlocks:has_bit(action.index - 1) then
notice('You have not unlocked the destination teleport')
elseif conflux_state == 1 then
packet['Option Index'] = 1
packet['_unknown1'] = action.index
build_packet( packet)
npc_warp_request(p, action, bit.bor(2, bit.lshift(action.index, 16)))
packet['Option Index'] = action.index
packet['_unknown1'] = 0
end
packet['Automated Message'] = false
build_packet( packet)
end
events.abyssea_warp = function(p, packet)
local menu_enabled = p['Menu Parameters']:unpack('i')
local cruor = p['Menu Parameters']:unpack('i', 5)
local unlocks = p['Menu Parameters']:unpack('A12', 9)
if menu_enabled == 0 then
notice('You do not meet the requirements.')
elseif not unlocks:has_bit(action.unlock_bit) then
notice('You have not unlocked the destination teleport')
elseif cruor < 200 then
notice('You do not have enough Cruor.')
else
packet['Option Index'] = action.option
build_packet( packet)
end
packet['Automated Message'] = false
build_packet( packet)
end
local past_vw = {[4]=true,[5]=true,[6]=true,[13]=true,[14]=true,[15]=true}
events.voidwatch = function(p, packet)
local menu_enabled = p['Menu Parameters']:unpack('b', 1, 2)
local current_index = p['Menu Parameters']:unpack('b6',3, 3)
local cruor = p['Menu Parameters']:unpack('i', 17)
local unlocks = p['Menu Parameters']:unpack('I', 21)
local content = p['Menu Parameters']:byte(29)
packet['_unknown1'] = 0x4000
if not menu_enabled then
packet['_unknown1'] = 0
notice('You do not meet the requirements.')
elseif current_index == action.index then
notice('You are already at that teleport')
elseif action.option ~= 55 and past_vw[current_index] ~= action.past_vw then
notice('You can not travel to that destination from this area')
elseif action.content and not content:has_bit(action.content) then
notice('You do not have that expansion registered')
elseif bit.band(unlocks, action.unlock_mask) == 0 then
notice('You have not unlocked the destination teleport')
elseif cruor < 1000 then
notice('You do not have enough Cruor.')
else
packet['Option Index'] = 2
packet['_unknown1'] = action.option
end
packet['Automated Message'] = false
build_packet( packet)
end
events.outpost = function(p, packet)
--[[
sandyRegions, bastokRegions, windyRegions, beastmenRegions,
bit.lshift(1, teleporterRegion), 0,
main_job_level,
allowedTeleports
]]
end
events.enter = function(p, packet)
packet['Option Index'] = 0
build_packet( packet)
if p['Menu ID'] == handled_menus.enter.reisenjima[p.Zone] then
--local sea_access = p['Menu Parameters']:unpack('b', 1)
packet['Option Index'] = 2
else
packet['Option Index'] = 1
end
packet['Automated Message'] = false
build_packet( packet)
end
local function check_event(menu, p)
if menu.ids then
return menu.zones:contains(p.Zone) and menu.ids:contains(p['Menu ID'])
else
return menu.zones[p.Zone] and menu.zones[p.Zone]:contains(p['Menu ID'])
end
end
local map_markers = {
unknown_1 = {'H', 0x06+1},
homepoints = {'A16', 0x08+1},
survival_guides = {'A16', 0x18+1},
waypoints = {
[01] = {'b9', 0x28+1, 1},
[02] = {'b9', 0x29+1, 2},
[03] = {'b4', 0x2A+1, 3},
[04] = {'b4', 0x2A+1, 7},
[05] = {'b5', 0x2B+1, 3},
[06] = {'b6', 0x2B+1, 8},
[07] = {'b4', 0x2C+1, 6},
[08] = {'b5', 0x2D+1, 2},
[09] = {'b5', 0x2D+1, 7},
},
gate_crystals = {'b9', 0x38+1},
wotg_maws = {'b9', 0x3C+1},
unknown_2 = {'b23', 0x3D+1, 1},
eschan_portals = {'I', 0x40+1},
}
windower.register_event('incoming chunk', function(id, data, modified, injected, blocked)
if (id == 0x32 or id == 0x34) and action then
local p = packets.parse('incoming', data)
if check_event(handled_menus[action.str], p) then
if not action.in_event then
action.in_event = true
queued = {}
events[action.str](p, build_dialog_option(p))
action = nil
return enable_injection
end
end
elseif id == 0x052 then
elseif id == 0x05C then
elseif id == 0x063 and data:byte(5) == 6 and check_unlocks then
if check_unlocks == 'homepoints' then
local unlocks = data:sub(0x08+1, 0x17+1)
for zone, tab in pairs(maps.homepoints) do
for k, v in ipairs(tab) do
if unlocks:has_bit(v.index) then
windower.add_to_chat(207, 'Home Point #%s: %s':format(k, zone))
end
end
end
elseif check_unlocks == 'survival_guides' then
local unlocks = data:sub(0x18+1, 0x27+1)
for zone, tab in pairs(maps.survival_guides) do
if unlocks:has_bit(tab.unlock_bit) then
windower.add_to_chat(207, 'Survival Guide: %s':format(zone))
end
end
end
check_unlocks = nil
end
end)
windower.register_event('outgoing chunk', function(id, data, modified, injected, blocked)
if (id == 0x05C or id == 0x5B) and not enable_injection then
--local p = packets.parse('outgoing', data)
local matches
local num = #queued
if queued[1] then
matches = queued[1]:sub(5) == data:sub(5)
if not matches then
print('queued ' .. queued[1]:hex())
end
table.remove(queued, 1)
print(injected and 'injected' or 'outgoing '.. data:hex() .. (matches and ' MATCHES ' or ' ERROR ') .. num)
end
if id == 0x05B and data:byte(15) == 0 then queued = {} end
end
end)
local function get_distance(a, b)
return math.sqrt((a.x-b.x)^2 + (a.y-b.y)^2)
end
local function valid_target(targ)
return targ and targ.valid_target and targ.is_npc and targ.spawn_type == 2
end
local function find_npc(names)
local targ, dist
local self = windower.ffxi.get_mob_by_target('me')
for index = 0, 0x3FF do local npc = windower.ffxi.get_mob_by_index(index)
if valid_target(npc) and names:contains(npc.name) and (not targ or get_distance(self, npc) < dist) then
targ = npc
dist = get_distance(self, npc)
end
end
return targ, dist
end
local function retry()
if action and not action.in_event then
if retry_limit > action.retry_attempts then
action.retry_attempts = action.retry_attempts + 1
local self = windower.ffxi.get_mob_by_target('me')
local targ = windower.ffxi.get_mob_by_id(action.target)
if self and self.status == 0 and valid_target(targ) and get_distance(self, targ) <= 6 then
notice('retrying')
interact_npc(targ)
retry:schedule(retry_delay)
return
end
end
action = nil
end
end
local function valid_args(command, arg)
if not alias[command] then return end
for zone, tab in pairs(alias[command]) do
if tab[arg] then
return true
end
end
end
local function check_args(command, args)
if not args[2] then return end
local point = args[#args]:lower()
if tonumber(point) or valid_args(command, point) then
if #args == 2 then
local zone = res.zones[windower.ffxi.get_info().zone].english
if alias[command].global[point] and not (alias[command][zone] and alias[command][zone][point]) then
return command, table.copy(alias[command].global[point])
end
return command, {zone = zone, point = point}
end
return command, {zone = table.concat(args,' ', 2, #args-1), point = point}
end
return command, {zone = table.concat(args, ' ', 2)}
end
local translate = function(str)
if #str == 5 and str:byte(1) == 0xFD and str:sub(4) == string.char(0x27,0xFD) then
str = str:sub(1,4) .. 0x5C:char() .. str:sub(5)
end
return windower.convert_auto_trans(str)
end
local function resolve_zone(command, args)
if not args then return end
args.command = command
local map = maps[args.command]
args.zone = translate(args.zone)
args.zone = alias.zone[args.zone] or args.zone
if map[args.zone] then
args.message = 'Teleporting to ' .. args.zone
args.dest = table.copy(map[args.zone])
return args
end
local match = ('*' .. args.zone:gsub('%p', '') .. '*'):gsub(' ', '*')
for zone, dest in pairs(map) do
if zone:gsub('[%s%p]', ''):wmatch(match) then
args.message = 'Teleporting to ' .. zone
args.zone = zone
args.dest = dest
return args
end
end
notice('Unable to locate destination zone %s.':format(args.zone))
end
local function resolve_point(args)
if not args then return end
if not args.point then
args.dest = args.dest[0] or args.dest[1]
else
local point = tonumber(args.point) or alias[args.command] and alias[args.command][args.zone] and alias[args.command][args.zone][args.point]
args.dest = args.dest[point]
args.message = args.message .. ' ' .. args.point
end
if args.dest then
return args
end
notice('Unable to locate destination point%s in %s.':format(args.point, args.zone))
end
local function handle_command(commands)
if not commands then return end
local targ, dist = find_npc(handled_menus[commands.command].npcs)
if not targ then
notice('No target found')
elseif dist > 6 then
notice('%s is too far away':format(targ.name))
else
action = commands.dest and table.copy(commands.dest) or {}
action.str = commands.command
action.target = targ.id
action.retry_attempts = 0
interact_npc(targ)
if commands.message then
notice(commands.message)
end
retry:schedule(retry_delay)
end
end
local names = {}
local function do_all(str)
for name in pairs(names) do
windower.send_ipc_message(name .. ' ' .. str)
coroutine.sleep(send_all_delay)
end
end
handled_commands = {
hp = 'homepoints',
sg = 'survival_guides',
wp = 'waypoints',
pw = 'proto_waypoints',
uw = 'unity',
di = 'elvorseal',
ew = 'eschan_portals',
ab = 'confluxes',
aw = 'abyssea_warp',
rp = 'runic_portal',
vw = 'voidwatch',
enter = 'enter',
}
local function on_command(...)
local commands = {...}
local command = commands[1] and handled_commands[commands[1]:lower()]
if not command then return end
if action then return end
if os.time() - last_attempt < 5 then return end
if windower.ffxi.get_player().status ~= 0 then return end
if commands[2] == 'list' then
packets.inject( packets.new('outgoing', 0x114))
check_unlocks = command
return
end
local zone_id = windower.ffxi.get_info().zone
if not handled_menus[command].zones[zone_id] then return end
if commands[2] and commands[2]:lower() == 'all' then
names = {}
windower.send_ipc_message('roll_call')
while commands[2] and commands[2]:lower() == 'all' do
table.remove(commands, 2)
end
do_all:schedule(send_all_delay, table.concat(commands, ' '))
end
if command == 'waypoints' or command == 'homepoints' and 'set' ~= (commands[2] and commands[2]:lower()) then
handle_command(resolve_point(resolve_zone(check_args(command, commands))))
elseif command == 'eschan_portals' or command == 'confluxes' then
local point = tonumber(commands[2])
if not point then return end
handle_command(resolve_point{
command = command,
message = 'Teleporting to point',
zone = res.zones[zone_id].name,
dest = maps[command][zone_id],
point = point
})
elseif command == 'survival_guides' or
command == 'proto_waypoints' or
command == 'unity' or
command == 'abyssea_warp' or
command == 'voidwatch' or
command == 'runic_portal' and commands[2] then
handle_command(resolve_zone(command, {zone = table.concat(commands, ' ', 2)}))
else
handle_command{command = command}
end
end
local function ipc_message(message)
message = message:split(' ')
if message[1] == 'roll_call' then
windower.send_ipc_message('name %s':format(windower.ffxi.get_mob_by_target('me').name))
elseif message[1] == 'name' then
names[message[2]] = true
elseif message[1] == windower.ffxi.get_mob_by_target('me').name then
table.remove(message, 1)
on_command(unpack(message))
end
end
windower.register_event('ipc message', ipc_message)
windower.register_event('addon command', on_command)
windower.register_event('unhandled command', on_command)
local unity = {
['East Ronfaure'] = {option = 1, content = 0},
['South Gustaberg'] = {option = 33, content = 0},
['East Sarutabaruta'] = {option = 65, content = 0},
['La Theine Plateau'] = {option = 97, content = 0},
['Konschtat Highlands'] = {option = 129, content = 0},
['Tahrongi Canyon'] = {option = 161, content = 0},
['Valkurm Dunes'] = {option = 193, content = 0},
['Buburimu Peninsula'] = {option = 225, content = 0},
['Qufim Island'] = {option = 257, content = 0},
['Bibiki Bay'] = {option = 289, content = 2},
['Carpenters\' Landing'] = {option = 321, content = 0},
['Yuhtunga Jungle'] = {option = 353, content = 1},
['Lufaise Meadows'] = {option = 385, content = 2, unlock_bit = 1},
['Jugner Forest'] = {option = 417, content = 0},
['Pashhow Marshlands'] = {option = 449, content = 0},
['Meriphataud Mountains'] = {option = 481, content = 0},
['Eastern Altepa Desert'] = {option = 513, content = 1},
['Yhoator Jungle'] = {option = 545, content = 1},
['The Sanctuary of Zi\'Tah'] = {option = 577, content = 1},
['Misareaux Coast'] = {option = 609, content = 2, unlock_bit = 2},
['Labyrinth of Onzozo'] = {option = 641, content = 1},
['Bostaunieux Oubliette'] = {option = 673, content = 0, unlock_bit = 4},
['Batallia Downs'] = {option = 705, content = 0},
['Rolanberry Fields'] = {option = 737, content = 0},
['Sauromugue Champaign'] = {option = 769, content = 0},
['Beaucedine Glacier'] = {option = 801, content = 0},
['Xarcabard'] = {option = 833, content = 0},
['Ro\'Maeve'] = {option = 865, content = 1},
['Western Altepa Desert'] = {option = 897, content = 1},
['Attohwa Chasm'] = {option = 929, content = 2},
['Garlaige Citadel'] = {option = 961, content = 0},
['Ifrit\'s Cauldron'] = {option = 993, content = 1},
['The Boyahda Tree'] = {option = 1025, content = 1},
['Kuftal Tunnel'] = {option = 1057, content = 1},
['Sea Serpent Grotto'] = {option = 1089, content = 1},
['Temple of Uggalepih'] = {option = 1121, content = 1},
['Quicksand Caves'] = {option = 1153, content = 1},
['Wajaom Woodlands'] = {option = 1185, content = 3, unlock_bit = 5},
--['Lufaise Meadows'] = {option = 1217, content = 2, unlock_bit = 1},
['Cape Teriggan'] = {option = 1249, content = 1},
['Uleguerand Range'] = {option = 1313, content = 2},
['Den of Rancor'] = {option = 1345, content = 1, unlock_bit = 3},
['Fei\'Yin'] = {option = 1377, content = 0},
['Alzadaal Undersea Ruins'] = {option = 1441, content = 3, unlock_bit = 6},
--['Misareaux Coast'] = {option = 1473, content = 2, unlock_bit = 2},
['Mount Zhayolm'] = {option = 1505, content = 3, unlock_bit = 5},
['Gustav Tunnel'] = {option = 1537, content = 1},
['Behemoth\'s Dominion'] = {option = 1569, content = 0},
--['The Boyahda Tree'] = {option = 1601, content = 1},
['Valley of Sorrows'] = {option = 1633, content = 1},
--['Wajaom Woodlands'] = {option = 1665, content = 3, unlock_bit = 5},
--['Mount Zhayolm'] = {option = 1697, content = 3, unlock_bit = 5},
['Caedarva Mire'] = {option = 1729, content = 3, unlock_bit = 6},
['Aydeewa Subterrane'] = {option = 1761, content = 3, unlock_bit = 7},
}
unity['Hugemaw Harold'] = unity['East Ronfaure']
unity['Bounding Belinda'] = unity['South Gustaberg']
unity['Prickly Pitriv'] = unity['East Sarutabaruta']
unity['Ironhorn Baldurno'] = unity['La Theine Plateau']
unity['Sleepy Mabel'] = unity['Konschtat Highlands']
unity['Serpopard Ninlil'] = unity['Tahrongi Canyon']
unity['Valkurm Imperator'] = unity['Valkurm Dunes']
unity['Abyssdiver'] = unity['Buburimu Peninsula']
unity['Jester Malatrix'] = unity['Qufim Island']
unity['Intuila'] = unity['Bibiki Bay']
unity['Orcfeltrap'] = unity['Carpenters\' Landing']
unity['Sybaritic Samantha'] = unity['Yuhtunga Jungle']
unity['Immanibugard'] = unity['Lufaise Meadows']
unity['Vermillion Fishfly'] = unity['Lufaise Meadows']
unity['Emperor Arthro'] = unity['Jugner Forest']
unity['Joyous Green'] = unity['Pashhow Marshlands']
unity['Warblade Beak'] = unity['Meriphataud Mountains']
unity['Cactrot Veloz'] = unity['Eastern Altepa Desert']
unity['Woodland Mender'] = unity['Yhoator Jungle']
unity['Keeper of Heiligtum'] = unity['The Sanctuary of Zi\'Tah']
unity['Tiyanak'] = unity['Misareaux Coast']
unity['Volatile Cluster'] = unity['Misareaux Coast']
unity['Voso'] = unity['Labyrinth of Onzozo']
unity['Garbage Gel'] = unity['Bostaunieux Oubliette']
unity['Lumber Jill'] = unity['Batallia Downs']
unity['Strix'] = unity['Rolanberry Fields']
unity['Arke'] = unity['Sauromugue Champaign']
unity['Largantua'] = unity['Beaucedine Glacier']
unity['Beist'] = unity['Xarcabard']
unity['Douma Weapon'] = unity['Ro\'Maeve']
unity['King Uropygid'] = unity['Western Altepa Desert']
unity['Muut'] = unity['Attohwa Chasm']
unity['Mephitas'] = unity['Garlaige Citadel']
unity['Coca'] = unity['Ifrit\'s Cauldron']
unity['Ayapec'] = unity['The Boyahda Tree']
unity['Hidhaegg'] = unity['The Boyahda Tree']
unity['Specter Worm'] = unity['Kuftal Tunnel']
unity['Bakunawa'] = unity['Sea Serpent Grotto']
unity['Azure-toothed Clawberry'] = unity['Temple of Uggalepih']
unity['Centurio XX-I'] = unity['Quicksand Caves']
unity['Kubool Ja\'s Mhuufya'] = unity['Wajaom Woodlands']
unity['Thu\'ban'] = unity['Wajaom Woodlands']
unity['Vedrfolnir'] = unity['Cape Teriggan']
unity['Glazemane'] = unity['Cape Teriggan']
unity['Camahueto'] = unity['Uleguerand Range']
unity['Azrael'] = unity['Den of Rancor']
unity['Borealis Shadow'] = unity['Fei\'Yin']
unity['Carousing Celine'] = unity['Fei\'Yin']
unity['Vidmapire'] = unity['Alzadaal Undersea Ruins']
unity['Grand Grenade'] = unity['Mount Zhayolm']
unity['Sarama'] = unity['Mount Zhayolm']
unity['Wyvernhunter Bambrox'] = unity['Gustav Tunnel']
unity['Sovereign Behemoth'] = unity['Behemoth\'s Dominion']
unity['Tolba'] = unity['Valley of Sorrows']
unity['Shedu'] = unity['Caedarva Mire']
unity['Tumult Curator'] = unity['Aydeewa Subterrane']
return unity
return {
['East Ronfaure'] = {option = 1, unlock_mask = 0x000000F},
['East Ronfaure [S]'] = {option = 2, unlock_mask = 0x000000F, past_vw = true},
['Ordelle\'s Caves'] = {option = 3, unlock_mask = 0x000000E},
['Jugner Forest'] = {option = 4, unlock_mask = 0x000000C},
['Jugner Forest [S]'] = {option = 5, unlock_mask = 0x000000C, past_vw = true},
['King Ranperre\'s Tomb'] = {option = 6, unlock_mask = 0x0000008},
['North Gustaberg'] = {option = 7, unlock_mask = 0x00000F0},
['North Gustaberg [S]'] = {option = 8, unlock_mask = 0x00000F0, past_vw = true},
['Gusgen Mines'] = {option = 9, unlock_mask = 0x00000E0},
['Pashhow Marshlands'] = {option = 10, unlock_mask = 0x00000C0},
['Pashhow Marshlands [S]'] = {option = 11, unlock_mask = 0x00000C0, past_vw = true},
['Dangruf Wadi'] = {option = 12, unlock_mask = 0x0000080},
['West Sarutabaruta'] = {option = 13, unlock_mask = 0x0000F00},
['West Sarutabaruta [S]'] = {option = 14, unlock_mask = 0x0000F00, past_vw = true},
['Maze of Shakhrami'] = {option = 15, unlock_mask = 0x0000E00},
['Meriphataud Mountains'] = {option = 16, unlock_mask = 0x0000C00},
['Meriphataud Mountains [S]'] = {option = 17, unlock_mask = 0x0000C00, past_vw = true},
['Outer Horutoto Ruins'] = {option = 18, unlock_mask = 0x0000800},
['Batallia Downs'] = {option = 19, unlock_mask = 0x0707000, index = 10},
['Batallia Downs [S]'] = {option = 20, unlock_mask = 0x0707000, index = 13, past_vw = true},
['Rolanberry Fields'] = {option = 21, unlock_mask = 0x0707000, index = 11},
['Rolanberry Fields [S]'] = {option = 22, unlock_mask = 0x0707000, index = 14, past_vw = true},
['Sauromugue Champaign'] = {option = 23, unlock_mask = 0x0707000, index = 12},
['Sauromugue Champaign [S]'] = {option = 24, unlock_mask = 0x0707000, index = 15, past_vw = true},
['Eldieme Necropolis'] = {option = 25, unlock_mask = 0x0706000},
['Eldieme Necropolis [S]'] = {option = 26, unlock_mask = 0x0706000, past_vw = true},
['Crawlers\' Nest'] = {option = 27, unlock_mask = 0x0706000},
['Crawlers\' Nest [S]'] = {option = 28, unlock_mask = 0x0706000, past_vw = true},
['Garlaige Citadel'] = {option = 29, unlock_mask = 0x0706000},
['Garlaige Citadel [S]'] = {option = 30, unlock_mask = 0x0706000, past_vw = true},
['Qufim Island'] = {option = 31, unlock_mask = 0x0704000, index = 16},
['Delkfutt\'s Tower'] = {option = 32, unlock_mask = 0x0704000},
['Behemoth\'s Dominion'] = {option = 33, unlock_mask = 0x0704000},
['Yuhtunga Jungle'] = {option = 34, unlock_mask = 0x0068000, content = 0},
['Ifrit\'s Cauldron'] = {option = 35, unlock_mask = 0x0068000, content = 0},
['Temple of Uggalepih'] = {option = 36, unlock_mask = 0x0068000, content = 0},
['Western Altepa Desert'] = {option = 37, unlock_mask = 0x0070000, content = 0},
['Kuftal Tunnel'] = {option = 38, unlock_mask = 0x0070000, content = 0},
['Quicksand Caves'] = {option = 39, unlock_mask = 0x0070000, content = 0},
['The Sanctuary of Zi\'Tah'] = {option = 40, unlock_mask = 0x0060000, content = 0},
['The Boyahda Tree'] = {option = 41, unlock_mask = 0x0060000, content = 0},
['Ro\'Maeve'] = {option = 42, unlock_mask = 0x0060000, content = 0},
['The Hall of the Gods'] = {option = 43, unlock_mask = 0x0040000, content = 0},
['West Ronfaure'] = {option = 44, unlock_mask = 0x0700000},
['South Gustaberg'] = {option = 45, unlock_mask = 0x0700000},
['East Sarutabaruta'] = {option = 46, unlock_mask = 0x0700000},
['La Theine Plateau'] = {option = 47, unlock_mask = 0x0600000},
['Konschtat Highlands'] = {option = 48, unlock_mask = 0x0600000},
['Tahrongi Canyon'] = {option = 49, unlock_mask = 0x0600000},
['Vunkerl Inlet [S]'] = {option = 50, unlock_mask = 0x0400000, past_vw = true},
['Grauberg [S]'] = {option = 51, unlock_mask = 0x0400000, past_vw = true},
['Fort Karugo-Narugo [S]'] = {option = 52, unlock_mask = 0x0400000, past_vw = true},
['Valkurm Dunes'] = {option = 53, unlock_mask = 0x0400000},
['Buburimu Peninsula'] = {option = 54, unlock_mask = 0x0400000},
['Beaucedine Glacier'] = {option = 55, unlock_mask = 0x0400000},
['Lufaise Meadows'] = {option = 56, unlock_mask = 0x1800000, content = 1},
['Misareaux Coast'] = {option = 57, unlock_mask = 0x1800000, content = 1},
['Uleguerand Range'] = {option = 58, unlock_mask = 0x1800000, content = 1},
['Attohwa Chasm'] = {option = 59, unlock_mask = 0x1800000, content = 1},
['Bibiki Bay'] = {option = 60, unlock_mask = 0x1000000, content = 1},
['Arrapago Reef'] = {option = 61, unlock_mask = 0x6000000, content = 2},
['Mount Zhayolm'] = {option = 62, unlock_mask = 0x6000000, content = 2},
['Mamook'] = {option = 63, unlock_mask = 0x6000000, content = 2},
['Caedarva Mire'] = {option = 64, unlock_mask = 0x6000000, content = 2},
['Aydeewa Subterrane'] = {option = 65, unlock_mask = 0x4000000, content = 2},
}
return {
['Western Adoulin'] = {
{category = 1, point = 1, index = 1, x = 4.8960003852844, z = 0, y = -4.7890000343323, rotation = 33},
{category = 1, point = 2, index = 2, x = -110.50000762939, z = 3.8500001430511, y = -13.482000350952, rotation = 191},
{category = 1, point = 3, index = 3, x = -20.982000350952, z = -0.15000000596046, y = -79.891006469727, rotation = 127},
{category = 1, point = 4, index = 4, x = 91.45100402832, z = -0.15000000596046, y = -49.013000488281, rotation = 0},
{category = 1, point = 5, index = 5, x = -68.099006652832, z = 4, y = -73.672004699707, rotation = 28},
{category = 1, point = 6, index = 6, x = 5.7310004234314, z = 0, y = -123.04300689697, rotation = 127},
{category = 1, point = 7, index = 7, x = 174.78300476074, z = 3.8500001430511, y = -35.78800201416, rotation = 63},
{category = 1, point = 8, index = 8, x = 14.586000442505, z = 0, y = 162.60800170898, rotation = 191},
{category = 1, point = 9, index = 9, x = 51.09400177002, z = 32, y = 126.29900360107, rotation = 191},
},
['Eastern Adoulin'] = {
{category = 2, point = 1, index = 21, x = -101.2740020752, z = -0.15000000596046, y = -10.726000785828, rotation = 191},
{category = 2, point = 2, index = 22, x = -77.944000244141, z = -0.15000000596046, y = -63.926002502441, rotation = 0},
{category = 2, point = 3, index = 23, x = -46.838001251221, z = -0.075000002980232, y = -12.767000198364, rotation = 63},
{category = 2, point = 4, index = 24, x = -57.773002624512, z = -0.15000000596046, y = 85.237007141113, rotation = 127},
{category = 2, point = 5, index = 25, x = -61.865001678467, z = -0.15000000596046, y = -120.81000518799, rotation = 127},
{category = 2, point = 6, index = 26, x = -42.065002441406, z = -0.15000000596046, y = -89.97900390625, rotation = 191},
{category = 2, point = 7, index = 27, x = 11.681000709534, z = -22.150001525879, y = 29.976001739502, rotation = 127},
{category = 2, point = 8, index = 28, x = 27.124000549316, z = -40.150001525879, y = -60.84400177002, rotation = 127},
{category = 2, point = 9, index = 29, x = 95.994003295898, z = -40.150001525879, y = -74.541000366211, rotation = 0},
},
['Ceizak Battlegrounds'] = {
[0]={category = 3, point = 1, index = 41, x = 365.00003051758, z = 0.60000002384186, y = 190.00001525879, rotation = 127},
{category = 3, point = 2, index = 42, x = -6.8790001869202, z = 0, y = -117.51100921631, rotation = 63},
{category = 3, point = 3, index = 43, x = -42.000003814697, z = 0, y = 155, rotation = 191},
{category = 3, point = 4, index = 44, x = -442.00003051758, z = 0, y = -247.00001525879, rotation = 191},
},
['Yahse Hunting Grounds'] = {
[0]={category = 4, point = 1, index = 31, x = 321, z = 0, y = -199.80000305176, rotation = 127},
{category = 4, point = 2, index = 32, x = 86.500007629395, z = 0, y = 1.5000001192093, rotation = 0},
{category = 4, point = 3, index = 33, x = -286.5, z = 0, y = 43.500003814697, rotation = 127},
{category = 4, point = 4, index = 34, x = -162.40000915527, z = 0, y = -272.80001831055, rotation = 191},
},
['Foret de Hennetiel'] = {
[0]={category = 5, point = 1, index = 51, x = 398.11001586914, z = -2, y = 279.11001586914, rotation = 0},
{category = 5, point = 2, index = 52, x = 12.60000038147, z = -2.4000000953674, y = 342.00003051758, rotation = 0},
{category = 5, point = 3, index = 53, x = 505.00003051758, z = -2.25, y = -303.5, rotation = 127},
{category = 5, point = 4, index = 54, x = 103.00000762939, z = -2.2000000476837, y = -92.300003051758, rotation = 63},
{category = 5, point = 5, index = 55, x = -251.80001831055, z = -2.3700001239777, y = -39.25, rotation = 63},
},
['Morimar Basalt Fields'] = {
[0]={category = 6, point = 1, index = 61, x = 443.72802734375, z = -16, y = -325.4280090332, rotation = 191},
{category = 6, point = 2, index = 62, x = 368.00003051758, z = -16, y = 37.5, rotation = 127},
{category = 6, point = 3, index = 63, x = 112.80000305176, z = -0.483000010252, y = 324.40002441406, rotation = 63},
{category = 6, point = 4, index = 64, x = 175.50001525879, z = -15.581000328064, y = -318.20001220703, rotation = 127},
{category = 6, point = 5, index = 65, x = -323.00003051758, z = -32, y = 2, rotation = 63},
{category = 6, point = 6, index = 66, x = -78.200004577637, z = -47.284000396729, y = 303, rotation = 191},
},
['Yorcia Weald'] = {
[0]={category = 7, point = 1, index = 71, x = 353.30001831055, z = 0.20000000298023, y = 153.30000305176, rotation = 223},
{category = 7, point = 2, index = 72, x = -40.499000549316, z = 0.36700001358986, y = 296.36700439453, rotation = 0},
{category = 7, point = 3, index = 73, x = 122.13200378418, z = 0.14600001275539, y = -287.73101806641, rotation = 127},
{category = 7, point = 4, index = 74, x = -274.77600097656, z = 0.3570000231266, y = 85.376007080078, rotation = 127},
{category = 11, point = 3, index = 302}
},
['Marjami Ravine'] = {
[0]={category = 8, point = 1, index = 81, x = 358.00003051758, z = -60.000003814697, y = 165.00001525879, rotation = 63},
{category = 8, point = 2, index = 82, x = 323.00003051758, z = -20, y = -79, rotation = 0},
{category = 8, point = 3, index = 83, x = 6.808000087738, z = 0, y = 78.437004089355, rotation = 191},
{category = 8, point = 4, index = 84, x = -318.7080078125, z = -20, y = -127.27500915527, rotation = 63},
{category = 8, point = 5, index = 85, x = -326.02200317383, z = -40.023002624512, y = 201.09600830078, rotation = 191},
},
['Kamihr Drifts'] = {
[0]={category = 9, point = 1, index = 91, x = 439.40301513672, z = 63.000003814697, y = -272.55401611328, rotation = 63},
{category = 9, point = 2, index = 92, x = -42.574001312256, z = 43.000003814697, y = -71.319000244141, rotation = 0},
{category = 9, point = 3, index = 93, x = 8.2400007247925, z = 43.000003814697, y = -283.01699829102, rotation = 191},
{category = 9, point = 4, index = 94, x = 9.2400007247925, z = 23.000001907349, y = 162.8030090332, rotation = 63},
{category = 9, point = 5, index = 95, x = -228.94201660156, z = 3.5670001506805, y = 364.51202392578, rotation = 127},
},
['Jeuno'] = {{category = 10, point = 0, index = 100}},
['Rala Waterways'] = {{category = 11, point = 1, index = 300}},
['Cirdas Caverns'] = {{category = 11, point = 2, index = 301}},
['Outer Ra\'Kaznar'] = {{category = 11, point = 4, index = 303}},
['Northern San d\'Oria'] = {{category = 12, point = 1, index = 200}},
['Bastok Markets'] = {{category = 12, point = 2, index = 201}},
['Windurst Woods'] = {{category = 12, point = 3, index = 202}},
['Selbina'] = {{category = 12, point = 4, index = 203}},
['Mhaura'] = {{category = 12, point = 5, index = 204}},
['Kazham'] = {{category = 12, point = 6, index = 205}},
['Rabao'] = {{category = 12, point = 7, index = 206}},
['Norg'] = {{category = 12, point = 8, index = 207}},
['Tavnazian Safehold'] = {{category = 12, point = 9, index = 208}},
['Aht Urhgan Whitegate'] = {{category = 12, point = 10, index = 209}},
['Nashmau'] = {{category = 12, point = 11, index = 210}},
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment