diff --git a/js/bullet.js b/js/bullet.js
index b9f09a3..9d0dbf0 100644
--- a/js/bullet.js
+++ b/js/bullet.js
@@ -801,10 +801,14 @@ const b = {
lockedOn: null,
isFollowMouse: true,
onDmg(who) {
+ console.log(who.alive)
mobs.statusSlow(who, 60)
this.endCycle = game.cycle
- if (mod.isHeavyWater) mobs.statusDoT(who, 0.1, 300)
- if (mod.iceEnergy && !who.shield) mech.energy += mod.iceEnergy //&& mech.energy < mech.maxEnergy
+ if (mod.isHeavyWater) mobs.statusDoT(who, 0.15, 300)
+ if (mod.iceEnergy && !who.shield && !who.isShielded && who.dropPowerUp && !who.alive) {
+ mech.energy += mod.iceEnergy * 0.66
+ mech.addHealth(mod.iceEnergy * 0.03)
+ }
},
onEnd() {},
do() {
@@ -1836,85 +1840,6 @@ const b = {
this.nextFireCycle = mech.cycle + CD * b.fireCD //predict next fire cycle if the fire button is held down
}
mech.fireCDcycle = mech.cycle + Math.floor(CD * b.fireCD); // cool down
-
-
- // const range = 2000
- // const totalBullets = 6
- // const angleStep = (mech.crouch ? 0.06 : 0.25) / totalBullets
- // let dir = mech.angle - angleStep * totalBullets / 2;
- // for (let i = 0; i < totalBullets; i++) {
- // dir += angleStep
- // const vertexCollision = function (v1, v1End, domain) {
- // for (let i = 0; i < domain.length; ++i) {
- // let vertices = domain[i].vertices;
- // const len = vertices.length - 1;
- // for (let j = 0; j < len; j++) {
- // results = game.checkLineIntersection(v1, v1End, vertices[j], vertices[j + 1]);
- // if (results.onLine1 && results.onLine2) {
- // const dx = v1.x - results.x;
- // const dy = v1.y - results.y;
- // const dist2 = dx * dx + dy * dy;
- // if (dist2 < best.dist2 && (!domain[i].mob || domain[i].alive)) {
- // best = {
- // x: results.x,
- // y: results.y,
- // dist2: dist2,
- // who: domain[i],
- // v1: vertices[j],
- // v2: vertices[j + 1]
- // };
- // }
- // }
- // }
- // results = game.checkLineIntersection(v1, v1End, vertices[0], vertices[len]);
- // if (results.onLine1 && results.onLine2) {
- // const dx = v1.x - results.x;
- // const dy = v1.y - results.y;
- // const dist2 = dx * dx + dy * dy;
- // if (dist2 < best.dist2 && (!domain[i].mob || domain[i].alive)) {
- // best = {
- // x: results.x,
- // y: results.y,
- // dist2: dist2,
- // who: domain[i],
- // v1: vertices[0],
- // v2: vertices[len]
- // };
- // }
- // }
- // }
- // };
- // const path = [{
- // x: mech.pos.x,
- // y: mech.pos.y
- // },
- // {
- // x: mech.pos.x + range * Math.cos(dir),
- // y: mech.pos.y + range * Math.sin(dir)
- // }
- // ];
- // let best = {
- // x: null,
- // y: null,
- // dist2: Infinity,
- // who: null,
- // v1: null,
- // v2: null
- // };
- // vertexCollision(path[path.length - 2], path[path.length - 1], mob);
- // vertexCollision(path[path.length - 2], path[path.length - 1], map);
- // vertexCollision(path[path.length - 2], path[path.length - 1], body);
-
- // if (best.dist2 !== Infinity) { //if hitting something
- // b.explosion({
- // x: best.x,
- // y: best.y
- // }, (mech.crouch ? 95 : 75) + (Math.random() - 0.5) * 50);
- // } else {
- // b.explosion(path[path.length - 1], (mech.crouch ? 95 : 75) + (Math.random() - 0.5) * 50);
- // }
- // }
-
const speed = 30 + 6 * Math.random() + 9 * mod.nailInstantFireRate
const angle = mech.angle + (Math.random() - 0.5) * (Math.random() - 0.5) * (mech.crouch ? 1.35 : 3.2) / CD
const dmg = 0.9
@@ -1925,7 +1850,6 @@ const b = {
x: mech.Vx / 2 + speed * Math.cos(angle),
y: mech.Vy / 2 + speed * Math.sin(angle)
}, dmg) //position, velocity, damage
-
if (mod.isIceCrystals) {
bullet[bullet.length - 1].onDmg = function (who) {
mobs.statusSlow(who, 30)
diff --git a/js/level.js b/js/level.js
index a79af99..ad023f8 100644
--- a/js/level.js
+++ b/js/level.js
@@ -23,8 +23,8 @@ const level = {
// mod.giveMod("eddy current brake")
- // level.intro(); //starting level
- level.testing(); //not in rotation
+ level.intro(); //starting level
+ // level.testing(); //not in rotation
// level.template() //not in rotation
// level.testChamber() //less mobs, more puzzle
// level.sewers();
@@ -141,6 +141,7 @@ const level = {
spawn.mapRect(level.exit.x, level.exit.y + 20, 100, 100); //exit bump
// spawn.boost(1500, 0, 900);
+ spawn.starter(1600, -500)
// spawn.bomberBoss(2900, -500)
// spawn.launcherBoss(1200, -500)
// spawn.laserTargetingBoss(1600, -400)
@@ -150,12 +151,11 @@ const level = {
// spawn.sniper(1800, -120)
// spawn.sniper(2200, -120)
// spawn.cellBossCulture(1600, -500)
- // spawn.starter(1600, -500)
// spawn.powerUpBoss(1600, -500)
// spawn.shield(mob[mob.length - 1], 1200, -500, 1);
// spawn.nodeBoss(1200, -500, "launcher")
- spawn.snakeBoss(1200, -500)
+ // spawn.snakeBoss(1200, -500)
// spawn.timeSkipBoss(2900, -500)
// spawn.randomMob(1600, -500)
},
diff --git a/js/mods.js b/js/mods.js
index 1143333..a69c3e7 100644
--- a/js/mods.js
+++ b/js/mods.js
@@ -2208,7 +2208,7 @@ const mod = {
maxCount: 1,
count: 0,
allowed() {
- return mod.haveGunCheck("ice IX") || mod.isIceField
+ return (mod.haveGunCheck("ice IX") || mod.isIceField) && !mod.iceEnergy
},
requires: "ice IX",
effect() {
@@ -2220,15 +2220,15 @@ const mod = {
},
{
name: "thermoelectric effect",
- description: "ice IX bullets give you 7% energy
after they collide with mobs",
- maxCount: 9,
+ description: "killing mobs with ice IX gives 3% health
and overfills your energy by 66%",
+ maxCount: 3,
count: 0,
allowed() {
- return mod.haveGunCheck("ice IX") || mod.isIceField
+ return (mod.haveGunCheck("ice IX") || mod.isIceField) && !mod.isHeavyWater
},
requires: "ice IX",
effect() {
- mod.iceEnergy += 0.07
+ mod.iceEnergy++
},
remove() {
mod.iceEnergy = 0;
diff --git a/todo.txt b/todo.txt
index d07ff0f..444b7ea 100644
--- a/todo.txt
+++ b/todo.txt
@@ -1,14 +1,8 @@
+ice IX mod: thermoelectric effect - when ice IX kills a mob heal 3% and regen 66% energy
************** TODO - n-gon **************
-buff neutron bomb?
- less fire CD?
-
-mod set a max speed cap based on distance from player while field is active
- name: eddy current brake
- who runs the code?
- new bot
- perfect diamagnetism
+all explosions based guns seem weak, buff damage?
vacuum bomb applies status effect to mobs that makes blocks attracted to them
@@ -35,7 +29,6 @@ add a flag to some bullets to indicate that mobs can't learn the player position
2. bullet is less than 4 seconds old
3. damage is nearby player or in line of sight of player
-
add some more computer / AI stuff to the level lore text
mod - mines stun targets nearby when they explode
@@ -78,18 +71,6 @@ standing wave harmonics mod - push things away
or push away at the peak of an oscillation
or always push
-hit scan bullets -> nails
-
-new gun or field - fire 3+ balls in arc
- name: something about energy
- does damage in area, like neutron bomb
- ends on contact with wall, doesn't stick or bounce
- hold fire to charge: increases the size of the balls
- mod: balls are attracted to mobs
-
-rework perfect diamagnetism
- let the shield also do bremsstrahlung radiation
-
map element - player rotates a rotor that makes a platform go up or down
use mac automator to speed up your n-gon -> git sync