http://scratch.mit.edu/projects/Suparing01/3226908
Firstly, please go to options> scene selections > scene on the right, and enter the boss battle. Whenever I'm close to dying, but I kill the boss, a few seconds later he kills ME.
Example:
Tim(8)
Tom(14)
Boss(2)
If I were to kill the boss, he would die, and a few seconds later, the game over screen will come up.
How can I prevent this?
Offline
Suparing01 wrote:
http://scratch.mit.edu/projects/Suparing01/3226908
Firstly, please go to options> scene selections > scene on the right, and enter the boss battle. Whenever I'm close to dying, but I kill the boss, a few seconds later he kills ME.
Example:
Tim(8)
Tom(14)
Boss(2)
If I were to kill the boss, he would die, and a few seconds later, the game over screen will come up.
How can I prevent this?
Did you put this?
when I receive[boss battle] set life to [0]If you did, then that is the source of the problem.
Offline
joshuaho wrote:
Suparing01 wrote:
http://scratch.mit.edu/projects/Suparing01/3226908
Firstly, please go to options> scene selections > scene on the right, and enter the boss battle. Whenever I'm close to dying, but I kill the boss, a few seconds later he kills ME.
Example:
Tim(8)
Tom(14)
Boss(2)
If I were to kill the boss, he would die, and a few seconds later, the game over screen will come up.
How can I prevent this?Did you put this?
when I receive[boss battle] set life to [0]If you did, then that is the source of the problem.
I'm pretty sure he knows better than to kill the player automatically when the battle starts.
What I think is happening is that even though you killed the boss, the boss still has a turn and it kills you. You should have the boss check whether it still has health remaning before attacking I guess.
Offline
Suparing01 wrote:
http://scratch.mit.edu/projects/Suparing01/3226908
Firstly, please go to options> scene selections > scene on the right, and enter the boss battle. Whenever I'm close to dying, but I kill the boss, a few seconds later he kills ME.
Example:
Tim(8)
Tom(14)
Boss(2)
If I were to kill the boss, he would die, and a few seconds later, the game over screen will come up.
How can I prevent this?
There might be another problem. For example, if you have a broadcast message that says boss battle and then you put this:
when I receive[boss battle] broadcast[game over]The broadcast message said game over after boss battle was received. In that case, game over messages will tell the other sprites to hide and the stage switch to game over.
Offline
kayybee wrote:
joshuaho wrote:
Suparing01 wrote:
http://scratch.mit.edu/projects/Suparing01/3226908
Firstly, please go to options> scene selections > scene on the right, and enter the boss battle. Whenever I'm close to dying, but I kill the boss, a few seconds later he kills ME.
Example:
Tim(8)
Tom(14)
Boss(2)
If I were to kill the boss, he would die, and a few seconds later, the game over screen will come up.
How can I prevent this?Did you put this?
when I receive[boss battle] set life to [0]If you did, then that is the source of the problem.I'm pretty sure he knows better than to kill the player automatically when the battle starts.
What I think is happening is that even though you killed the boss, the boss still has a turn and it kills you. You should have the boss check whether it still has health remaning before attacking I guess.
No, I didn't make it so I die automatically, and the part above in bold is the problem, it's just, I'm puzzled on how to fix it. How can I make it so the boss checks if he has health before broadcasting his turn?
Offline
Suparing01 wrote:
kayybee wrote:
joshuaho wrote:
Did you put this?
when I receive[boss battle] set life to [0]If you did, then that is the source of the problem.I'm pretty sure he knows better than to kill the player automatically when the battle starts.
What I think is happening is that even though you killed the boss, the boss still has a turn and it kills you. You should have the boss check whether it still has health remaning before attacking I guess.No, I didn't make it so I die automatically, and the part above in bold is the problem, it's just, I'm puzzled on how to fix it. How can I make it so the boss checks if he has health before broadcasting his turn?
Try this :
when gf clicked forever if <(Boss Health) > [0]> say[ replace this block with the scripts you want to use for the boss attacking] end if <(Boss Health) < [1]> say[ replace this block with the scripts you want to use for the boss being defeated] endhope this helps,
Last edited by topazdragonlord (2013-04-15 16:03:08)
Offline
Suparing01 wrote:
No, I didn't make it so I die automatically, and the part above in bold is the problem, it's just, I'm puzzled on how to fix it. How can I make it so the boss checks if he has health before broadcasting his turn?
Did you put a forever block?
Offline
topazdragonlord wrote:
Suparing01 wrote:
kayybee wrote:
I'm pretty sure he knows better than to kill the player automatically when the battle starts.
What I think is happening is that even though you killed the boss, the boss still has a turn and it kills you. You should have the boss check whether it still has health remaning before attacking I guess.No, I didn't make it so I die automatically, and the part above in bold is the problem, it's just, I'm puzzled on how to fix it. How can I make it so the boss checks if he has health before broadcasting his turn?
Try this :
when gf clicked forever if <(Boss Health) > [0]> say[ replace this block with the scripts you want to use for the boss attacking] end if <(Boss Health) < [1]> say[ replace this block with the scripts you want to use for the boss being defeated] endhope this helps,
topazdragonlord
or you can do:
if boss > 0
he's alive
else
he's dead
end
as you missed the range from 0 to 1, including 0 and 1.
Offline