diff --git a/.makecode/blocks.png b/.makecode/blocks.png index 7f9c49b..ee4a102 100644 Binary files a/.makecode/blocks.png and b/.makecode/blocks.png differ diff --git a/.makecode/blocksdiff.png b/.makecode/blocksdiff.png index c57af17..4810e58 100644 Binary files a/.makecode/blocksdiff.png and b/.makecode/blocksdiff.png differ diff --git a/main.blocks b/main.blocks index 12550a8..d9a5b3a 100644 --- a/main.blocks +++ b/main.blocks @@ -1,4 +1,4 @@ -0;16;16;00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001;16;16;dddddddddddddddddddddd8ddddddddddddddd8ddddddddddddddd88d8dddddddddd8d8888dddddddddd888888d8dddddd8d88888888dddddd8888688888d8dd88888866868888888888686666888888888866666686888866666666666666666666660666666666666666006066666666600600006606660000000000000060FishChoiceprojectilesharkiemySpritePlayerProjectileFoodEnemy9tiles.createTilemap( +0;16;16;00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001;16;16;dddddddddddddddddddddd8ddddddddddddddd8ddddddddddddddd88d8dddddddddd8d8888dddddddddd888888d8dddddd8d88888888dddddd8888688888d8dd88888866868888888888686666888888888866666686888866666666666666666666660666666666666666006066666666600600006606660000000000000060FishChoiceprojectilesharkiemySpritePlayerProjectileFoodEnemy9tiles.createTilemap( hex`10000c000e0e0e0e0e0e0e0e0e0e0e0e0e0e0e0e00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0f0304040404040404040404040404040600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000`, img` . . . . . . . . . . . . . . . . @@ -33,7 +33,7 @@ . . . f f 3 5 3 3 5 3 f f f f 3 . . . . f f 3 3 3 3 3 3 3 3 3 3 . . . . . . 3 9 3 3 3 3 3 9 3 f -`PlayermySpriteSpriteFlag.StayInScreenmySpritetrue03spritePlayerotherSpriteFood1effects.heartsotherSprite100music.baDingevery half a second spawn a fish500FishChoice002TRUEEQ0FishChoice0projectile0img` +`PlayermySpriteSpriteFlag.StayInScreenmySpritetrue03spritePlayerotherSpriteFood2effects.heartsotherSprite100music.baDingevery half a second spawn a fish500FishChoice002TRUEEQ0FishChoice0projectile0img` . . . . . . . . . . . . . . . . . . . . . . . c c c c c c . . . . . . . . . c 5 5 5 5 5 c c . . @@ -84,7 +84,7 @@ f 4 4 4 4 4 1 4 4 f 4 4 d f f f . . . . . . . . c 5 5 5 c 4 c 5 5 5 c 4 c 5 c . . . . . . . . . c 5 5 5 5 c 5 5 5 5 c 4 c 5 c . . . . . . . . . . c c c c c c c c c . . c c c . -`-500projectile16010120projectileFood1000sharkie0img` +`-500projectile16010120projectileFoodspritePlayerotherSpriteEnemy-1effects.fireotherSprite100music.powerDown1000sharkie0img` . . . . . . . . . . . . . . . . . . . . c c f f f . . . . . . . . . . . . . . . . . . . . . f f f f f f f f f c b b b b f . . . . . . . . . . . . . . . . . . . . f b b b b b b b b b f f f b f . . . . . . . . . . . . diff --git a/main.ts b/main.ts index b4752ca..d0cfed5 100644 --- a/main.ts +++ b/main.ts @@ -39,10 +39,15 @@ d d 8 8 8 8 8 6 8 8 8 8 8 d d d ` } sprites.onOverlap(SpriteKind.Player, SpriteKind.Food, function (sprite, otherSprite) { - info.changeScoreBy(1) + info.changeScoreBy(2) otherSprite.destroy(effects.hearts, 100) music.baDing.play() }) +sprites.onOverlap(SpriteKind.Player, SpriteKind.Enemy, function (sprite, otherSprite) { + info.changeLifeBy(-1) + otherSprite.destroy(effects.fire, 100) + music.powerDown.play() +}) let sharkie: Sprite = null let projectile: Sprite = null let FishChoice = 0