Last active
February 22, 2019 18:26
-
-
Save bidaumm/5d7fa85c6dcb39cb98e2318cd871fced to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Options.DisabledTriggers = { | |
'UWU Titan Gaols': true, | |
}; | |
Options.Triggers = [ | |
{ | |
zoneRegex: /^(The Weapon's Refrain \(Ultimate\)|Unknown Zone \(309\))$/, | |
triggers: [ | |
{ | |
id: 'UWU Titan Gaols /w Priority', | |
regex: / 15:\y{ObjectId}:(?:Garuda:2B6C|Titan:2B6B):Rock Throw:\y{ObjectId}:(\y{Name}):/, | |
regexDe: / 15:\y{ObjectId}:(?:Garuda:2B6C|Titan:2B6B):Granitgefängnis:\y{ObjectId}:(\y{Name}):/, | |
regexFr: / 15:\y{ObjectId}:(?:Garuda:2B6C|Titan:2B6B):Jeté De Rocs:\y{ObjectId}:(\y{Name}):/, | |
regexJa: / 15:\y{ObjectId}:(?:ガルーダ:2B6C|タイタン:2B6B):グラナイト・ジェイル:\y{ObjectId}:(\y{Name}):/, | |
regexKo: / 15:\y{ObjectId}:(?:가루다:2B6C|타이탄:2B6B):화강암 감옥:\y{ObjectId}:(\y{Name}):/, | |
preRun: function(data, matches) { | |
data.priorityGaols = data.priorityGaols || []; | |
data.priorityGaols.push(matches[1]); | |
// List of people to call out in order (top of the list called out first). | |
// This list can have more or fewer than eight people. | |
// These should be full in game names, and not nicknames. | |
// People not listed will come first. | |
var priorityOrder = [ | |
'Player One', | |
'Player Two', | |
'Player Three', | |
'Player Four', | |
'Player Five', | |
'Player Six',, | |
'Player Seven', | |
]; | |
if (data.priorityGaols.length == 3) | |
data.priorityGaols.sort((a, b) => { | |
return priorityOrder.indexOf(a) - priorityOrder.indexOf(b); | |
}); | |
}, | |
alertText: function(data, matches) { | |
if (data.priorityGaols.length != 3) | |
return; | |
let idx = data.priorityGaols.indexOf(data.me); | |
if (idx < 0) | |
return; | |
// Just return your number. | |
return idx + 1; | |
}, | |
infoText: function(data, matches) { | |
if (data.priorityGaols.length != 3) | |
return; | |
// Return all the people in order. | |
return data.priorityGaols.map(function(n) { | |
return data.ShortName(n); | |
}).join(', '); | |
}, | |
}, | |
], | |
}, | |
]; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment