src: replace all mention of "utils.draw" by "utils.graphics"

This commit is contained in:
Kazhnuz 2019-02-04 08:50:54 +01:00
parent 49a8700400
commit 421e92f80a
5 changed files with 18 additions and 18 deletions

View file

@ -107,9 +107,9 @@ function Font:print(text, x, y, align, r, sx, sy, ox, oy, kx, ky)
self:set()
if (self.spacing.active) then
utils.draw.printWithSpacing(text, self.spacing.size, align, x, y, r, sx, sy, ox, oy, kx, ky)
utils.graphics.printWithSpacing(text, self.spacing.size, align, x, y, r, sx, sy, ox, oy, kx, ky)
else
utils.draw.print(text, align, x, y, r, sx, sy, ox, oy, kx, ky)
utils.graphics.print(text, align, x, y, r, sx, sy, ox, oy, kx, ky)
end
end
@ -138,7 +138,7 @@ end
function Font:applyFilterShadow(text, x, y, limit, align, r, sx, sy, ox, oy, kx, ky)
love.graphics.setColor(0, 0, 0, 1)
self:printf(text, x+1, y+1, limit, align, align, r, sx, sy, ox, oy, kx, ky)
utils.draw.resetColor()
utils.graphics.resetColor()
end
function Font:applyFilterBorder(text, x, y, limit, align, r, sx, sy, ox, oy, kx, ky)
@ -155,7 +155,7 @@ function Font:applyFilterBorder(text, x, y, limit, align, r, sx, sy, ox, oy, kx,
self:printf(text, x , y+1, limit, align, r, sx, sy, ox, oy, kx, ky)
self:printf(text, x+1, y+1, limit, align, r, sx, sy, ox, oy, kx, ky)
utils.draw.resetColor()
utils.graphics.resetColor()
end
function Font:applyFilterDoubleBorder(text, x, y, limit, align, r, sx, sy, ox, oy, kx, ky)
@ -172,7 +172,7 @@ function Font:applyFilterDoubleBorder(text, x, y, limit, align, r, sx, sy, ox, o
self:printf(text, x , y+2, limit, align, r, sx, sy, ox, oy, kx, ky)
self:printf(text, x+2, y+2, limit, align, r, sx, sy, ox, oy, kx, ky)
utils.draw.resetColor()
utils.graphics.resetColor()
end
return Font

View file

@ -154,7 +154,7 @@ function ParentEntity:drawEcho()
end
function ParentEntity:drawSprite(tx, ty)
utils.draw.resetColor()
utils.graphics.resetColor()
local x, y, z = self:getSpritePosition()
@ -185,16 +185,16 @@ function ParentEntity:drawHitBox()
local r, g, b, a = self.debugColor.r, self.debugColor.g, self.debugColor.b, self.debugColor.a
--utils.draw.box(self.x, self.y + self.z + self.h, self.w, self.d, self.h, r, g, b, a)
--utils.draw.box(x - (self.w/2), y - (self.w/2) - self.z, self.w, self.h, r, g, b, a)
--utils.draw.box(x - (self.w/2), y - (self.w/2) - self.z, self.w, self.d, r, g, b, a)
--utils.draw.box(x - (self.w/2), y + (self.w/2) - self.z - self.d, self.w, self.d, r, g, b, a)
--utils.draw.box(x - (self.w/2), y - (self.w/2) - self.z - self.d, self.w, self.h, r, g, b, a)
--utils.draw.box(x - (self.w/2), y + (self.w/2) - self.z - self.d, self.w, self.d, r, g, b, a)
--utils.graphics.box(self.x, self.y + self.z + self.h, self.w, self.d, self.h, r, g, b, a)
--utils.graphics.box(x - (self.w/2), y - (self.w/2) - self.z, self.w, self.h, r, g, b, a)
--utils.graphics.box(x - (self.w/2), y - (self.w/2) - self.z, self.w, self.d, r, g, b, a)
--utils.graphics.box(x - (self.w/2), y + (self.w/2) - self.z - self.d, self.w, self.d, r, g, b, a)
--utils.graphics.box(x - (self.w/2), y - (self.w/2) - self.z - self.d, self.w, self.h, r, g, b, a)
--utils.graphics.box(x - (self.w/2), y + (self.w/2) - self.z - self.d, self.w, self.d, r, g, b, a)
utils.draw.box(x - (self.w/2), y - (self.h/2), self.w, self.h, r/5, g/5, b/5, 1)
utils.graphics.box(x - (self.w/2), y - (self.h/2), self.w, self.h, r/5, g/5, b/5, 1)
utils.draw.box(x - (self.w/2), y - z - self.d, self.w, self.d, r, g, b, 1)
utils.graphics.box(x - (self.w/2), y - z - self.d, self.w, self.d, r, g, b, 1)
end

View file

@ -15,12 +15,12 @@ function Rail:new(world, x, y, z, id)
end
function Rail:draw()
utils.draw.resetColor( )
utils.graphics.resetColor( )
love.graphics.draw(self.world.textures.rail, self.world.quads.rails[self.railid], self.x + math.floor(self.y / 2), self.y - self.z -(self.d / 2))
end
function Rail:drawEcho()
utils.draw.resetColor( )
utils.graphics.resetColor( )
love.graphics.draw(self.world.textures.rail, self.world.quads.rails[self.railid], self.x + math.floor(self.y / 2) + self.world.width, self.y - self.z -(self.d / 2))
end

View file

@ -147,7 +147,7 @@ function Controller:draw()
self.world:draw()
self.camera.view:detach()
utils.draw.resetColor()
utils.graphics.resetColor()
self.hud:draw()
if self.pause == true then

View file

@ -166,7 +166,7 @@ function World:drawChunk(x, y, chunkid, turn)
love.graphics.setColor(.75, .75, .75, 1)
end
self:drawTile(tilex, tiley, tileid, variant)
utils.draw.resetColor()
utils.graphics.resetColor()
end
end
end