vaccum bomb grenade mod

gun: vacuum bomb is removed
mod: vacuum bomb - grenades fire slower, explode bigger and, suck everything towards them

laser and diffuse laser graphics are better
mod: output coupler - diffuse laser beam is 30% wider and does 30% more damage
      requires diffuse beam

level number doesn't increase if you skip the boss (in the late game)
This commit is contained in:
landgreen
2020-10-23 16:03:27 -07:00
parent 5bbac02f88
commit e0131fcea1
8 changed files with 219 additions and 193 deletions

View File

@@ -1104,7 +1104,7 @@ const mobs = {
//replace dead mob with a regular body
replace(i) {
//if there are too many bodies don't turn into blocks to help performance
if (this.leaveBody && body.length < 60 && this.mass < 200) {
if (this.leaveBody && body.length < 60 && this.mass < 200 && this.radius > 18) {
const len = body.length;
const v = Matter.Vertices.hull(Matter.Vertices.clockwiseSort(this.vertices)) //might help with vertex collision issue, not sure
body[len] = Matter.Bodies.fromVertices(this.position.x, this.position.y, v);