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
local function CreateDemoModel(numItems) | |
local listModel = {}; | |
for index = 1, numItems do | |
table.insert(listModel, { | |
text = string.format("List Item %1$d", index), | |
icon = string.format([[Interface\Icons\INV_Sword_%1$d]], 30 + (index % 30)), | |
}); | |
end |
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
#!/usr/bin/python3 | |
''' | |
Limited reimplementation of the Lua 5.1 lexer and parser providing utilities | |
for serialization and deserialization of World of Warcraft saved variables | |
files. | |
The grammar supported by the parser is a subset of the Lua 5.1 grammar, | |
any unimplemented features will raise errors if encountered in a source file. | |
''' |
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
#!/usr/bin/lua5.1 | |
--- Async/Await for Lua 5.1 | |
-- This script implements async/await functions for Lua, allowing tasks to | |
-- be queued and scheduled independently. | |
-- | |
-- This is just an example and has a bunch of issues, isn't tested, isn't | |
-- even actually used anywhere; I basically just got bored and had one of | |
-- those "what if?" type ideas 6 hours ago. | |
local co_create = coroutine.create |
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
-- Mapping of all root unit tokens in the game. | |
local UNIT_TOKENS = { | |
["player"] = true, | |
["target"] = true, | |
["mouseover"] = true, | |
["focus"] = true, | |
["pet"] = true, | |
["npc"] = true, | |
["vehicle"] = true, | |
}; |
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
Effect | SpellID | |
---|---|---|
53 | 2832 | |
53 | 2833 | |
53 | 3974 | |
53 | 2831 | |
53 | 2605 | |
53 | 3231 | |
53 | 3975 | |
53 | 3976 | |
53 | 6476 |
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
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/"> | |
<!-- | |
Bug #1: | |
Instantiating a frame ("TestFrame") that has no parent attribute | |
specified and is hidden upon creation seems to cause some issues | |
with the visiblity of child frames. | |
This is quite odd to explain, but running `TestFrame:Show()` ingame | |
causes only the "MagicTexture" Texture element to appear until the | |
frame itself is relocated or resized (click to drag), at which point |
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
<Ui xmlns="http://www.blizzard.com/wow/ui/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.blizzard.com/wow/ui/"> | |
<!-- | |
Upon login, run the following in the chat frame - if taint has | |
occurred both of the following variables will report as being insecure: | |
/dump issecurevariable(PTR_IssueReporter.Data, "CurrentMapID") | |
/dump issecurevariable(PTRIssueReporterAlertFrame, "FrameComponents") | |
It's possible for the first one to spuriously return "true" - there | |
might be an element of luck to it, but the "FrameComponents" key on |
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
local BackdropTemplatePolyfillMixin = {}; | |
function BackdropTemplatePolyfillMixin:OnBackdropLoaded() | |
if not self.backdropInfo then | |
return; | |
end | |
if not self.backdropInfo.edgeFile and not self.backdropInfo.bgFile then | |
self.backdropInfo = nil; | |
return; |
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
local distances = {}; -- Array of 4 distances to TL, TR, BR, BL. | |
local function GetPointToQuery(index) | |
local mapID = C_Map.GetBestMapForUnit("player"); | |
local x, y; | |
if index == 1 then | |
x, y = 0, 0; | |
elseif index == 2 then | |
x, y = 1, 0; |
OlderNewer