mirror of https://github.com/LDDestroier/CC/
Update trash.lua
This commit is contained in:
parent
7b332be1bc
commit
10636ba026
16
trash.lua
16
trash.lua
|
@ -32,14 +32,6 @@ local images = {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for k,v in pairs(images) do
|
|
||||||
for y = 1, #v do
|
|
||||||
for x = 1, #v[y] do
|
|
||||||
images[k][y][x] = v[y][x]:gsub(" ", "f")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
-- start up lddterm
|
-- start up lddterm
|
||||||
local lddterm = {}
|
local lddterm = {}
|
||||||
lddterm.alwaysRender = false -- renders after any and all screen-changing functions.
|
lddterm.alwaysRender = false -- renders after any and all screen-changing functions.
|
||||||
|
@ -163,7 +155,7 @@ lddterm.render = function(transformation, drawFunction)
|
||||||
else
|
else
|
||||||
for y = 1, #image[1] do
|
for y = 1, #image[1] do
|
||||||
lddterm.baseTerm.setCursorPos(1 + lddterm.adjustX, y + lddterm.adjustY)
|
lddterm.baseTerm.setCursorPos(1 + lddterm.adjustX, y + lddterm.adjustY)
|
||||||
lddterm.baseTerm.blit(image[1][y], image[2][y], image[3][y])
|
lddterm.baseTerm.blit(image[1][y], image[2][y]:gsub(" ", "f"), image[3][y]:gsub(" ", "f"))
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
fixCursorPos()
|
fixCursorPos()
|
||||||
|
@ -896,9 +888,9 @@ nfte.rotateImage = function(image, angle, originX, originY)
|
||||||
output[3][y] = {}
|
output[3][y] = {}
|
||||||
for x = 1, (maxX - minX) + 1 do
|
for x = 1, (maxX - minX) + 1 do
|
||||||
tx, ty = rotatePoint(x + minX - 1, y + minY - 1, -angle, originX, originY)
|
tx, ty = rotatePoint(x + minX - 1, y + minY - 1, -angle, originX, originY)
|
||||||
output[1][y][x] = "f"
|
output[1][y][x] = " "
|
||||||
output[2][y][x] = "f"
|
output[2][y][x] = " "
|
||||||
output[3][y][x] = "f"
|
output[3][y][x] = " "
|
||||||
if image[1][ty] then
|
if image[1][ty] then
|
||||||
if tx >= 1 and tx <= #image[1][ty] then
|
if tx >= 1 and tx <= #image[1][ty] then
|
||||||
output[1][y][x] = image[1][ty]:sub(tx,tx)
|
output[1][y][x] = image[1][ty]:sub(tx,tx)
|
||||||
|
|
Loading…
Reference in New Issue