brick breaker question >?????
![PhilipNewzealand](http://forums.gamesalad.com/applications/dashboard/design/images/defaulticon.png)
Hi guys, playing with the brick breaker code for a completely unrelated game.
Was wondering if any one had idea to make different bricks have several strength levels and changes image to signify it being broken????
Any clues people ?
Was wondering if any one had idea to make different bricks have several strength levels and changes image to signify it being broken????
Any clues people ?
Comments
Then make several rules in the brick(s) - When 85<self.health<95 change image to ____
When 75<self.health<85 change image to ____
Get it?
Matt
_________________________________________________________________________________
Next Gen Entertainment Store
GameSalad Community Project
Quality Game Making Service
1 On 1 Project Help
Free Pong Remix Template!
Game Creation Log - B.S.
you just give each on a self attribute (you can call it hit count) with its value set to 0, add one each time its hit,then base your damages and the damaged images off that.
Example:
You want a brick that it takes damage the first and second hit, then gets destroyed the 3rd. You would have your 2 damaged brick images. and you would give it a self attribute called hit count
make a rule in the brick when it collides with whatever your shooting at it, change self attribute hit count to hit count+1. So every time it gets hit it adds one to that
Then have a rule when attribute hit count=1 change image to first damage image
a rule when attribute hit count=2 change image to second damage image
then one last rule when attribute hit count=3 destroy actor