If this topic is not in the correct place, move it please.
Sorry for my bad english.
This is the thing:
I want that when one image reach the floor, that image disappear, and another image appear. But I dont know how to do it, because with the script I have done, the second image (the explotion) just is on the first image (the face), and I want that the face disappear and the explotion stays. I leave images about the .lua script and the image of the game. Thanks.
---------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------
I need help, the image doesn't disappear.
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
-
- Prole
- Posts: 7
- Joined: Tue Oct 28, 2014 5:18 am
I need help, the image doesn't disappear.
Pollo Rostizado
New in the programation world
Old in the learning world
New in the programation world
Old in the learning world
- HugoBDesigner
- Party member
- Posts: 403
- Joined: Mon Feb 24, 2014 6:54 pm
- Location: Above the Pocket Dimension
- Contact:
Re: I need help, the image doesn't disappear.
You're drawing the same image twice:
But you don't need the first time since you have it already in the "if-else" statement:
So just remove the line 103 and you should be fine.
Also, I'd recommend you paste the code here using [code][/code] tabs instead of images, it makes things easier
Code: Select all
love.graphics.draw(teemo, posX, posY) --First time
if (haValidoQueso) then
love.graphics.draw(explosion, posX, posY, -40)
else
love.graphics.draw(teemo, posX, posY) --Second time
end
Code: Select all
if haValidoQueso then
love.graphics.draw(explosion, posX, posY, -40)
else
love.graphics.draw(teemo, posX, posY) --Second time
end
Also, I'd recommend you paste the code here using [code][/code] tabs instead of images, it makes things easier
-
- Prole
- Posts: 7
- Joined: Tue Oct 28, 2014 5:18 am
Re: I need help, the image doesn't disappear.
Oooooooh, that makes a lot of sense. Thaaaaanks.
Oh, that new for me (Im new in the forum). Thanks HugoBDesigner (:
Oh, that new for me (Im new in the forum). Thanks HugoBDesigner (:
Pollo Rostizado
New in the programation world
Old in the learning world
New in the programation world
Old in the learning world
-
- Prole
- Posts: 7
- Joined: Tue Oct 28, 2014 5:18 am
Re: I need help, the image doesn't disappear.
Worked perfectly now. Thread may be closed.
Pollo Rostizado
New in the programation world
Old in the learning world
New in the programation world
Old in the learning world
Who is online
Users browsing this forum: Ahrefs [Bot], DarkblooM, Google [Bot] and 4 guests