Skip to content

Instantly share code, notes, and snippets.

@benphelps
Last active October 23, 2016 18:50
Show Gist options
  • Select an option

  • Save benphelps/b66c9a220d86ef2ba9577509f99979a8 to your computer and use it in GitHub Desktop.

Select an option

Save benphelps/b66c9a220d86ef2ba9577509f99979a8 to your computer and use it in GitHub Desktop.
function Pixel (x, y, r, g, b)
F = CreateFrame("Frame", WorldFrame)
F.pixel = F:CreateLine()
F.pixel:SetStartPoint('TOPLEFT')
F.pixel:SetEndPoint('BOTTOMRIGHT')
F.pixel:SetColorTexture(r, g, b, 1)
F:SetPoint("TOPLEFT", WorldFrame, "TOPLEFT", x, y)
F:SetPoint("BOTTOMRIGHT", WorldFrame, "TOPLEFT", x + 1, y + 1)
F:Show()
return F
end
Pixel(150, 150, 0, 1, 0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment