diff --git a/js/bullet.js b/js/bullet.js
index c881ee5..51d6db3 100644
--- a/js/bullet.js
+++ b/js/bullet.js
@@ -624,7 +624,7 @@ const b = {
onDmg(who) {
mobs.statusSlow(who, 60)
this.endCycle = game.cycle
- if (mod.isHeavyWater) mobs.statusDoT(who, 0.1, 180)
+ if (mod.isHeavyWater) mobs.statusDoT(who, 0.1, 300)
},
onEnd() {},
do() {
@@ -681,7 +681,7 @@ const b = {
friction: 0.05,
frictionAir: 0,
restitution: 1,
- dmg: 0.28, //damage done in addition to the damage from momentum
+ dmg: 0.24, //damage done in addition to the damage from momentum
lookFrequency: 80 + Math.floor(23 * Math.random()),
endCycle: game.cycle + Math.floor((1100 + 420 * Math.random()) * mod.isBulletsLastLonger),
classType: "bullet",
@@ -794,13 +794,14 @@ const b = {
radius *= Math.sqrt(mod.bulletSize)
const me = bullet.length;
bullet[me] = Bodies.polygon(position.x, position.y, 20, radius, {
- angle: 0,
+ // angle: 0,
density: 0.00005, // 0.001 is normal density
inertia: Infinity,
frictionAir: 0.003,
- friction: 0.2,
- restitution: 0.2,
- dmg: 0.1, //damage done in addition to the damage from momentum
+ // friction: 0.2,
+ // restitution: 0.2,
+ dmg: mod.isFastFoam ? 0.02 : 0.0055, //damage done in addition to the damage from momentum
+ scale: 1 - 0.005 / mod.isBulletsLastLonger * (mod.isFastFoam ? 1.7 : 1),
classType: "bullet",
collisionFilter: {
category: cat.bullet,
@@ -845,31 +846,6 @@ const b = {
onEnd() {},
do() {
if (!mech.isBodiesAsleep) { //if time dilation isn't active
- //check for touching map
-
- // if (Matter.Query.collides(this, map).length > 0) {
- if (Matter.Query.point(map, this.position).length > 0) {
- const slow = 0.85
- Matter.Body.setVelocity(this, {
- x: this.velocity.x * slow,
- y: this.velocity.y * slow
- });
- const SCALE = 0.96
- Matter.Body.scale(this, SCALE, SCALE);
- this.radius *= SCALE;
- // } else if (Matter.Query.collides(this, body).length > 0) {
- } else if (Matter.Query.point(body, this.position).length > 0) {
- const slow = 0.9
- Matter.Body.setVelocity(this, {
- x: this.velocity.x * slow,
- y: this.velocity.y * slow
- });
- const SCALE = 0.96
- Matter.Body.scale(this, SCALE, SCALE);
- this.radius *= SCALE;
- } else {
- this.force.y += this.mass * 0.00008; //gravity
- }
if (this.count < 20) {
this.count++
//grow
@@ -878,9 +854,8 @@ const b = {
this.radius *= SCALE;
} else {
//shrink
- const SCALE = 1 - 0.005 / mod.isBulletsLastLonger
- Matter.Body.scale(this, SCALE, SCALE);
- this.radius *= SCALE;
+ Matter.Body.scale(this, this.scale, this.scale);
+ this.radius *= this.scale;
if (this.radius < 8) this.endCycle = 0;
}
@@ -896,13 +871,13 @@ const b = {
// Matter.Body.setAngularVelocity(this.target, this.target.angularVelocity * 0.9)
if (this.target.isShielded) {
- this.target.damage(b.dmgScale * 0.005, true); //shield damage bypass
+ this.target.damage(b.dmgScale * this.dmg, true); //shield damage bypass
//shrink if mob is shielded
const SCALE = 1 - 0.018 / mod.isBulletsLastLonger
Matter.Body.scale(this, SCALE, SCALE);
this.radius *= SCALE;
} else {
- this.target.damage(b.dmgScale * 0.005);
+ this.target.damage(b.dmgScale * this.dmg);
}
} else if (this.target !== null) { //look for a new target
this.target = null
@@ -931,7 +906,27 @@ const b = {
}
}
}
-
+ } else if (Matter.Query.point(map, this.position).length > 0) { //slow when touching map or blocks
+ const slow = 0.85
+ Matter.Body.setVelocity(this, {
+ x: this.velocity.x * slow,
+ y: this.velocity.y * slow
+ });
+ const SCALE = 0.96
+ Matter.Body.scale(this, SCALE, SCALE);
+ this.radius *= SCALE;
+ // } else if (Matter.Query.collides(this, body).length > 0) {
+ } else if (Matter.Query.point(body, this.position).length > 0) {
+ const slow = 0.9
+ Matter.Body.setVelocity(this, {
+ x: this.velocity.x * slow,
+ y: this.velocity.y * slow
+ });
+ const SCALE = 0.96
+ Matter.Body.scale(this, SCALE, SCALE);
+ this.radius *= SCALE;
+ } else {
+ this.force.y += this.mass * 0.00008; //gravity
}
}
}
@@ -1843,7 +1838,7 @@ const b = {
// check if inside a mob
q = Matter.Query.point(mob, this.position)
for (let i = 0; i < q.length; i++) {
- let dmg = b.dmgScale * 0.40 / Math.sqrt(q[i].mass) * (mod.waveHelix === 1 ? 1 : 0.6) //1 - 0.4 = 0.6 for helix mod 40% damage reduction
+ let dmg = b.dmgScale * 0.36 / Math.sqrt(q[i].mass) * (mod.waveHelix === 1 ? 1 : 0.66) //1 - 0.4 = 0.6 for helix mod 40% damage reduction
q[i].damage(dmg);
q[i].foundPlayer();
game.drawList.push({ //add dmg to draw queue
diff --git a/js/engine.js b/js/engine.js
index 5e9f772..8ee10f2 100644
--- a/js/engine.js
+++ b/js/engine.js
@@ -202,9 +202,7 @@ function collisionChecks(event) {
}
//mob + bullet collisions
if (obj.classType === "bullet" && obj.speed > obj.minDmgSpeed) {
- // const dmg = b.dmgScale * (obj.dmg + 0.15 * obj.mass * Vector.magnitude(Vector.sub(mob[k].velocity, obj.velocity)));
let dmg = b.dmgScale * (obj.dmg + 0.15 * obj.mass * Vector.magnitude(Vector.sub(mob[k].velocity, obj.velocity)))
- // console.log(dmg)
if (mod.isCrit && !mob[k].seePlayer.recall && !mob[k].shield) dmg *= 5
mob[k].foundPlayer();
mob[k].damage(dmg);
@@ -223,7 +221,6 @@ function collisionChecks(event) {
const v = Vector.magnitude(Vector.sub(mob[k].velocity, obj.velocity));
if (v > 9) {
let dmg = 0.06 * b.dmgScale * v * obj.mass * mod.throwChargeRate;
- if (mod.isCrit && !mob[k].seePlayer.recall && !mob[k].shield) dmg *= 5
if (mob[k].isShielded) dmg *= 0.35
mob[k].damage(dmg, true);
if (mob[k].distanceToPlayer2() < 1000000) mob[k].foundPlayer();
diff --git a/js/mods.js b/js/mods.js
index a7ed635..f3b15bf 100644
--- a/js/mods.js
+++ b/js/mods.js
@@ -79,7 +79,7 @@ const mod = {
},
damageFromMods() {
let dmg = 1
- if (mod.isDamageForGuns) dmg *= 1 + 0.066 * b.inventory.length
+ if (mod.isDamageForGuns) dmg *= 1 + 0.07 * b.inventory.length
if (mod.isLowHealthDmg) dmg *= 1 + 0.5 * Math.max(0, 1 - mech.health)
if (mod.isHarmDamage && mech.lastHarmCycle + 600 > mech.cycle) dmg *= 2;
if (mod.isEnergyLoss) dmg *= 1.33;
@@ -175,22 +175,6 @@ const mod = {
mod.isFarAwayDmg = false;
}
},
- {
- name: "fracture analysis",
- description: "increase damage by 400%
for mobs that are unaware of you",
- maxCount: 1,
- count: 0,
- allowed() {
- return true
- },
- requires: "",
- effect() {
- mod.isCrit = true;
- },
- remove() {
- mod.isCrit = false;
- }
- },
{
name: "fluoroantimonic acid",
description: "increase damage by 40%
when your base health is above 100%",
@@ -1068,7 +1052,7 @@ const mod = {
},
{
name: "arsenal",
- description: "increase damage by 6.6%
for each gun in your inventory",
+ description: "increase damage by 7%
for each gun in your inventory",
maxCount: 1,
count: 0,
allowed() {
@@ -1610,7 +1594,7 @@ const mod = {
},
{
name: "wave packet",
- description: "wave beam emits two oscillating particles
decrease wave damage by 40%",
+ description: "wave beam emits two oscillating particles
decrease wave damage by 33%",
maxCount: 1,
count: 0,
allowed() {
@@ -1969,7 +1953,7 @@ const mod = {
},
{
name: "heavy water",
- description: "ice IX is synthesized with an extra neutron
does radioactive damage over 3 seconds",
+ description: "ice IX is synthesized with an extra neutron
does radioactive damage over 5 seconds",
maxCount: 1,
count: 0,
allowed() {
@@ -1999,6 +1983,22 @@ const mod = {
mod.isFoamGrowOnDeath = false;
}
},
+ {
+ name: "colloidal foam",
+ description: "increase foam damage by 200%
foam dissipates 50% faster",
+ maxCount: 1,
+ count: 0,
+ allowed() {
+ return mod.haveGunCheck("foam") || mod.foamBotCount > 2
+ },
+ requires: "foam",
+ effect() {
+ mod.isFastFoam = true
+ },
+ remove() {
+ mod.isFastFoam = false;
+ }
+ },
{
name: "frame-dragging",
description: "slow time while charging the rail gun
charging no longer drains energy",
@@ -2138,7 +2138,7 @@ const mod = {
},
{
name: "timelike world line",
- description: "time dilation doubles your time rate
and makes you immune to harm",
+ description: "time dilation doubles your relative time rate
and makes you immune to harm",
maxCount: 1,
count: 0,
allowed() {
@@ -2156,7 +2156,7 @@ const mod = {
},
{
name: "Lorentz transformation",
- description: "move, jump, and shoot 33% faster",
+ description: "permanently increase your relative time rate
move, jump, and shoot 33% faster",
maxCount: 1,
count: 0,
allowed() {
@@ -2194,7 +2194,7 @@ const mod = {
},
{
name: "plasma-bot",
- description: "a bot uses energy to emit short range plasma
plasma damages and pushes mobs",
+ description: "a bot uses energy to emit short range plasma
that damages and pushes mobs",
maxCount: 1,
count: 0,
allowed() {
@@ -2389,6 +2389,22 @@ const mod = {
mod.superposition = false;
}
},
+ {
+ name: "fracture analysis",
+ description: "bullet impacts do 500% damage
to mobs that are unaware of you or stunned",
+ maxCount: 1,
+ count: 0,
+ allowed() {
+ return mod.isStunField || mech.fieldUpgrades[mech.fieldMode].name === "phase decoherence field"
+ },
+ requires: "phase decoherence field or flux pinning",
+ effect() {
+ mod.isCrit = true;
+ },
+ remove() {
+ mod.isCrit = false;
+ }
+ },
{
name: "Bose Einstein condensate",
description: "mobs in superposition with the pilot wave
are frozen for 2 seconds",
@@ -2420,6 +2436,7 @@ const mod = {
powerUps.spawn(mech.pos.x, mech.pos.y, "heal");
if (Math.random() < mod.bayesian) powerUps.spawn(mech.pos.x, mech.pos.y, "heal");
}
+ this.count--
},
remove() {}
},
@@ -2438,6 +2455,7 @@ const mod = {
powerUps.spawn(mech.pos.x, mech.pos.y, "ammo");
if (Math.random() < mod.bayesian) powerUps.spawn(mech.pos.x, mech.pos.y, "ammo");
}
+ this.count--
},
remove() {}
},
@@ -2457,6 +2475,7 @@ const mod = {
powerUps.spawn(mech.pos.x, mech.pos.y, "reroll");
if (Math.random() < mod.bayesian) powerUps.spawn(mech.pos.x, mech.pos.y, "reroll");
}
+ this.count--
},
remove() {}
},
@@ -2473,6 +2492,7 @@ const mod = {
effect() {
powerUps.spawn(mech.pos.x, mech.pos.y, "gun");
if (Math.random() < mod.bayesian) powerUps.spawn(mech.pos.x, mech.pos.y, "gun");
+ this.count--
},
remove() {}
},
@@ -2489,6 +2509,7 @@ const mod = {
effect() {
powerUps.spawn(mech.pos.x, mech.pos.y, "field");
if (Math.random() < mod.bayesian) powerUps.spawn(mech.pos.x, mech.pos.y, "field");
+ this.count--
},
remove() {}
},
@@ -2610,5 +2631,6 @@ const mod = {
isDroneGrab: null,
isOneGun: null,
isDamageForGuns: null,
- isGunCycle: null
+ isGunCycle: null,
+ isFastFoam: null
}
\ No newline at end of file
diff --git a/js/powerup.js b/js/powerup.js
index 92c458a..3ddfbfc 100644
--- a/js/powerup.js
+++ b/js/powerup.js
@@ -496,8 +496,6 @@ const powerUps = {
if (Math.random() < mod.bayesian) powerUps.spawn(x, y, "gun")
}
}
-
-
},
chooseRandomPowerUp(x, y) { //100% chance to drop a random power up //used in spawn.debris
if (Math.random() < 0.5) {
@@ -526,6 +524,8 @@ const powerUps = {
} else {
powerUps.spawn(x, y, "ammo", false);
powerUps.spawn(x, y, "ammo", false);
+ powerUps.spawn(x, y, "ammo", false);
+ powerUps.spawn(x, y, "ammo", false);
}
} else {
powerUps.spawnRandomPowerUp(x, y);
diff --git a/todo.txt b/todo.txt
index 88bb1f1..53a5d0c 100644
--- a/todo.txt
+++ b/todo.txt
@@ -1,5 +1,10 @@
+
+mods: foam does 200% more damage, but dissolves 50% faster
+
************** TODO - n-gon **************
+
+
Mod: "Instant Acceleration": Minigun instantly starts firing at max fire rate, skipping the accelerated fire rate stage.
level Boss: fractal SierpiĆski triangle