Skip to content

Commit 70a3f42

Browse files
authored
fix pbombs not being able to trigger other pbombs
1 parent 539c1c3 commit 70a3f42

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tinygamecore.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,14 +199,15 @@ class tgc_pbomb extends tgc_entity {
199199
this.shards = shards;
200200
// console.log("this pbomb gets " + this.shards + " shards");
201201
this.exploded = false;
202+
this.collisionWhitelist = ["shrapnel","drifter"];
202203
}
203204
phys(friction,move) {
204205
if(!this.collidedLast) this.collidedLast = [];
205206
this.oX = this.x;
206207
this.oY = this.y;
207208
super.momentumWithBounds(friction,move);
208209
this.collidingObjects.forEach(e => {
209-
if(e.type === "player" || e.type === "drifter") {
210+
if(e.type === "player" || e.type === "drifter" || e.type === "shrapnel") {
210211
this.xv = e.xv*5;
211212
this.yv = e.yv*5;
212213
e.xv *= -2;

0 commit comments

Comments
 (0)