Change Bomb Implementation

- L and T shapes are no longer considered a match
- Bomb explodes WITH gems
- Bomb will  have a small sprite of the creating gem
This commit is contained in:
2025-12-17 00:44:23 +08:00
parent 9f9bf9a3f5
commit 85b9767201
3 changed files with 37 additions and 203 deletions

View File

@@ -306,6 +306,14 @@ namespace Services {
Gem currentGem = this.gameBoard.GetGemAt(new Vector2Int(x,y));
if (currentGem == null) {
int gemToUse = RandomUtils.RandomGemTypeAsInt();
int iterations = 0;
while (this.matchService.MatchesAt(new Vector2Int(x, y), (GemType)gemToUse) && iterations < 100)
{
gemToUse = RandomUtils.RandomGemTypeAsInt();
iterations++;
}
SpawnGem(new Vector2Int(x, y), (GemType)gemToUse);
}
}