diff options
| author | 1029chris <1029chris@gmail.com> | 2016-08-04 17:31:55 -0700 |
|---|---|---|
| committer | 1029chris <1029chris@gmail.com> | 2016-08-04 17:31:55 -0700 |
| commit | 33cce45e067eb3d716ad33b5752a838319125855 (patch) | |
| tree | 59d9fc8561c8ead0b9b8b3d5c1e6a81625ad0fed /virus2.lua | |
| parent | cb5ee7e47850599e51da852c14698fb6135ba4d7 (diff) | |
Added drawVirus2 function
changed playAnimation to follow frames for mask
Added virus2 x,y,r,s
Diffstat (limited to 'virus2.lua')
| -rw-r--r-- | virus2.lua | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -101,3 +101,18 @@ function drawPopups() v2.pop.add = false end end +function drawVirus2() + love.graphics.setColor(255,255,255) + playAnimation(v2.c.idle, true, v2.c.x, v2.c.y, v2.c.r, v2.c.s, 125, 125, 0.5) + love.graphics.stencil(drawVirus2Stencil, "replace", 1) + love.graphics.setStencilTest("greater", 0) + love.graphics.draw(v2.c.pupil, v2.c.x-26+math.random(-0.7,0.7),v2.c.y-57+math.random(-0.7,0.7),v2.c.r,v2.c.s) + love.graphics.draw(v2.c.pupil, v2.c.x+21+math.random(-0.7,0.7),v2.c.y-57+math.random(-0.7,0.7),v2.c.r,v2.c.s) + love.graphics.setStencilTest() + love.graphics.draw(v2.c.idle.hands, v2.c.x, v2.c.y, v2.c.r, v2.c.s, v2.c.s, 125, 125) +end +function drawVirus2Stencil() + love.graphics.setShader(mask_effect) + playAnimation(v2.c.idle.mask, true, v2.c.x, v2.c.y, v2.c.r, v2.c.s, 125, 125, 0.5) + love.graphics.setShader() +end |
