foam charges
apomixis spawns 8 bosses (up from 4) foam gun now charges up until you release the fire button
This commit is contained in:
87
js/bullet.js
87
js/bullet.js
@@ -29,6 +29,7 @@ const b = {
|
|||||||
}
|
}
|
||||||
if (m.holdingTarget) m.drop();
|
if (m.holdingTarget) m.drop();
|
||||||
}
|
}
|
||||||
|
b.guns[b.activeGun].do();
|
||||||
},
|
},
|
||||||
fireNotMove() { //added && player.speed < 0.5 && m.onGround
|
fireNotMove() { //added && player.speed < 0.5 && m.onGround
|
||||||
if (input.fire && m.fireCDcycle < m.cycle && (!input.field || m.fieldFire) && b.inventory.length && player.speed < 0.5 && m.onGround && Math.abs(m.yOff - m.yOffGoal) < 1) {
|
if (input.fire && m.fireCDcycle < m.cycle && (!input.field || m.fieldFire) && b.inventory.length && player.speed < 0.5 && m.onGround && Math.abs(m.yOff - m.yOffGoal) < 1) {
|
||||||
@@ -39,6 +40,7 @@ const b = {
|
|||||||
}
|
}
|
||||||
if (m.holdingTarget) m.drop();
|
if (m.holdingTarget) m.drop();
|
||||||
}
|
}
|
||||||
|
b.guns[b.activeGun].do();
|
||||||
},
|
},
|
||||||
fireNotMoveAlwaysFire() { //added && player.speed < 0.5 && m.onGround //removed input.fire && (!input.field || m.fieldFire)
|
fireNotMoveAlwaysFire() { //added && player.speed < 0.5 && m.onGround //removed input.fire && (!input.field || m.fieldFire)
|
||||||
if (m.fireCDcycle < m.cycle && b.inventory.length && player.speed < 0.5 && m.onGround && Math.abs(m.yOff - m.yOffGoal) < 1) {
|
if (m.fireCDcycle < m.cycle && b.inventory.length && player.speed < 0.5 && m.onGround && Math.abs(m.yOff - m.yOffGoal) < 1) {
|
||||||
@@ -49,6 +51,7 @@ const b = {
|
|||||||
}
|
}
|
||||||
if (m.holdingTarget) m.drop();
|
if (m.holdingTarget) m.drop();
|
||||||
}
|
}
|
||||||
|
b.guns[b.activeGun].do();
|
||||||
},
|
},
|
||||||
fireFloat() { //added && player.speed < 0.5 && m.onGround
|
fireFloat() { //added && player.speed < 0.5 && m.onGround
|
||||||
if (input.fire && (!input.field || m.fieldFire) && b.inventory.length) {
|
if (input.fire && (!input.field || m.fieldFire) && b.inventory.length) {
|
||||||
@@ -67,6 +70,7 @@ const b = {
|
|||||||
player.force.x = 0
|
player.force.x = 0
|
||||||
player.force.y = 0
|
player.force.y = 0
|
||||||
}
|
}
|
||||||
|
b.guns[b.activeGun].do();
|
||||||
},
|
},
|
||||||
fireWithAmmo() { //triggers after firing when you have ammo
|
fireWithAmmo() { //triggers after firing when you have ammo
|
||||||
b.guns[b.activeGun].fire();
|
b.guns[b.activeGun].fire();
|
||||||
@@ -3373,6 +3377,7 @@ const b = {
|
|||||||
ammoPack: 5.5,
|
ammoPack: 5.5,
|
||||||
defaultAmmoPack: 5.5,
|
defaultAmmoPack: 5.5,
|
||||||
have: false,
|
have: false,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
let knock, spread
|
let knock, spread
|
||||||
if (m.crouch) {
|
if (m.crouch) {
|
||||||
@@ -3537,6 +3542,7 @@ const b = {
|
|||||||
ammoPack: 12,
|
ammoPack: 12,
|
||||||
have: false,
|
have: false,
|
||||||
num: 5,
|
num: 5,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
const SPEED = m.crouch ? 43 : 32
|
const SPEED = m.crouch ? 43 : 32
|
||||||
m.fireCDcycle = m.cycle + Math.floor((m.crouch ? 25 : 18) * b.fireCD); // cool down
|
m.fireCDcycle = m.cycle + Math.floor((m.crouch ? 25 : 18) * b.fireCD); // cool down
|
||||||
@@ -3600,6 +3606,7 @@ const b = {
|
|||||||
ammo: 0,
|
ammo: 0,
|
||||||
ammoPack: 70,
|
ammoPack: 70,
|
||||||
have: false,
|
have: false,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
m.fireCDcycle = m.cycle + Math.floor(3 * b.fireCD); // cool down
|
m.fireCDcycle = m.cycle + Math.floor(3 * b.fireCD); // cool down
|
||||||
const dir = m.angle
|
const dir = m.angle
|
||||||
@@ -3712,6 +3719,7 @@ const b = {
|
|||||||
have: false,
|
have: false,
|
||||||
fireCycle: 0,
|
fireCycle: 0,
|
||||||
ammoLoaded: 0,
|
ammoLoaded: 0,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
const countReduction = Math.pow(0.9, tech.missileCount)
|
const countReduction = Math.pow(0.9, tech.missileCount)
|
||||||
if (m.crouch) {
|
if (m.crouch) {
|
||||||
@@ -3826,6 +3834,7 @@ const b = {
|
|||||||
ammo: 0,
|
ammo: 0,
|
||||||
ammoPack: 5,
|
ammoPack: 5,
|
||||||
have: false,
|
have: false,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
m.fireCDcycle = m.cycle + Math.floor((m.crouch ? 40 : 30) * b.fireCD); // cool down
|
m.fireCDcycle = m.cycle + Math.floor((m.crouch ? 40 : 30) * b.fireCD); // cool down
|
||||||
b.grenade()
|
b.grenade()
|
||||||
@@ -3836,6 +3845,7 @@ const b = {
|
|||||||
ammo: 0,
|
ammo: 0,
|
||||||
ammoPack: 2.7,
|
ammoPack: 2.7,
|
||||||
have: false,
|
have: false,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
if (tech.isLaserMine) { //laser mine
|
if (tech.isLaserMine) { //laser mine
|
||||||
const speed = m.crouch ? 50 : 20
|
const speed = m.crouch ? 50 : 20
|
||||||
@@ -3863,6 +3873,7 @@ const b = {
|
|||||||
ammo: 0,
|
ammo: 0,
|
||||||
ammoPack: 3,
|
ammoPack: 3,
|
||||||
have: false,
|
have: false,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
const me = bullet.length;
|
const me = bullet.length;
|
||||||
const dir = m.angle;
|
const dir = m.angle;
|
||||||
@@ -3993,6 +4004,7 @@ const b = {
|
|||||||
ammoPack: 14,
|
ammoPack: 14,
|
||||||
defaultAmmoPack: 14,
|
defaultAmmoPack: 14,
|
||||||
have: false,
|
have: false,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
if (m.crouch) {
|
if (m.crouch) {
|
||||||
b.drone({ x: m.pos.x + 30 * Math.cos(m.angle) + 10 * (Math.random() - 0.5), y: m.pos.y + 30 * Math.sin(m.angle) + 10 * (Math.random() - 0.5) }, 45)
|
b.drone({ x: m.pos.x + 30 * Math.cos(m.angle) + 10 * (Math.random() - 0.5), y: m.pos.y + 30 * Math.sin(m.angle) + 10 * (Math.random() - 0.5) }, 45)
|
||||||
@@ -4009,6 +4021,7 @@ const b = {
|
|||||||
// ammo: 0,
|
// ammo: 0,
|
||||||
// ammoPack: 64,
|
// ammoPack: 64,
|
||||||
// have: false,
|
// have: false,
|
||||||
|
// do() {},
|
||||||
// fire() {
|
// fire() {
|
||||||
// if (m.crouch) {
|
// if (m.crouch) {
|
||||||
// b.iceIX(10, 0.3)
|
// b.iceIX(10, 0.3)
|
||||||
@@ -4026,17 +4039,21 @@ const b = {
|
|||||||
ammo: 0,
|
ammo: 0,
|
||||||
ammoPack: 36,
|
ammoPack: 36,
|
||||||
have: false,
|
have: false,
|
||||||
fire() {
|
charge: 0,
|
||||||
let radius, spread
|
isCharging: false,
|
||||||
if (m.crouch) {
|
do() {
|
||||||
spread = 0.2 * (Math.random() - 0.5)
|
if (this.charge > 0 && !input.fire) {
|
||||||
radius = 10 + 5 * Math.random() + (tech.isAmmoFoamSize && this.ammo < 300) * 12
|
this.charge--
|
||||||
m.fireCDcycle = m.cycle + Math.floor(15 * b.fireCD); // cool down
|
this.fireFoam()
|
||||||
} else {
|
|
||||||
spread = 0.5 * (Math.random() - 0.5)
|
|
||||||
radius = 4 + 6 * Math.random() + (tech.isAmmoFoamSize && this.ammo < 300) * 12
|
|
||||||
m.fireCDcycle = m.cycle + Math.floor(5 * b.fireCD); // cool down
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
fire() {
|
||||||
|
this.charge++
|
||||||
|
m.fireCDcycle = m.cycle + Math.floor((1 + 0.35 * this.charge) * b.fireCD);
|
||||||
|
},
|
||||||
|
fireFoam() {
|
||||||
|
const spread = (m.crouch ? 0.05 : 0.6) * (Math.random() - 0.5)
|
||||||
|
const radius = 5 + 8 * Math.random() + (tech.isAmmoFoamSize && this.ammo < 300) * 12
|
||||||
const SPEED = 18 - radius * 0.4;
|
const SPEED = 18 - radius * 0.4;
|
||||||
const dir = m.angle + 0.15 * (Math.random() - 0.5)
|
const dir = m.angle + 0.15 * (Math.random() - 0.5)
|
||||||
const velocity = {
|
const velocity = {
|
||||||
@@ -4065,12 +4082,52 @@ const b = {
|
|||||||
b.foam(position, Vector.rotate(velocity, spread), radius)
|
b.foam(position, Vector.rotate(velocity, spread), radius)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// fire() {
|
||||||
|
// let radius, spread
|
||||||
|
// if (m.crouch) {
|
||||||
|
// spread = 0.2 * (Math.random() - 0.5)
|
||||||
|
// radius = 10 + 5 * Math.random() + (tech.isAmmoFoamSize && this.ammo < 300) * 12
|
||||||
|
// m.fireCDcycle = m.cycle + Math.floor(15 * b.fireCD); // cool down
|
||||||
|
// } else {
|
||||||
|
// spread = 0.5 * (Math.random() - 0.5)
|
||||||
|
// radius = 4 + 6 * Math.random() + (tech.isAmmoFoamSize && this.ammo < 300) * 12
|
||||||
|
// m.fireCDcycle = m.cycle + Math.floor(5 * b.fireCD); // cool down
|
||||||
|
// }
|
||||||
|
// const SPEED = 18 - radius * 0.4;
|
||||||
|
// const dir = m.angle + 0.15 * (Math.random() - 0.5)
|
||||||
|
// const velocity = {
|
||||||
|
// x: SPEED * Math.cos(dir),
|
||||||
|
// y: SPEED * Math.sin(dir)
|
||||||
|
// }
|
||||||
|
// const position = {
|
||||||
|
// x: m.pos.x + 30 * Math.cos(m.angle),
|
||||||
|
// y: m.pos.y + 30 * Math.sin(m.angle)
|
||||||
|
// }
|
||||||
|
// if (tech.foamFutureFire) {
|
||||||
|
// simulation.drawList.push({ //add dmg to draw queue
|
||||||
|
// x: position.x,
|
||||||
|
// y: position.y,
|
||||||
|
// radius: 5,
|
||||||
|
// color: "rgba(0,0,0,0.1)",
|
||||||
|
// time: 15 * tech.foamFutureFire
|
||||||
|
// });
|
||||||
|
// setTimeout(() => {
|
||||||
|
// if (!simulation.paused) {
|
||||||
|
// b.foam(position, Vector.rotate(velocity, spread), radius)
|
||||||
|
// bullet[bullet.length - 1].damage = (1 + 1.27 * tech.foamFutureFire) * (tech.isFastFoam ? 0.048 : 0.012) //double damage
|
||||||
|
// }
|
||||||
|
// }, 250 * tech.foamFutureFire);
|
||||||
|
// } else {
|
||||||
|
// b.foam(position, Vector.rotate(velocity, spread), radius)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
}, {
|
}, {
|
||||||
name: "rail gun",
|
name: "rail gun",
|
||||||
description: "use <strong class='color-f'>energy</strong> to launch a high-speed <strong>dense</strong> rod<br><strong>hold</strong> left mouse to charge, <strong>release</strong> to fire",
|
description: "use <strong class='color-f'>energy</strong> to launch a high-speed <strong>dense</strong> rod<br><strong>hold</strong> left mouse to charge, <strong>release</strong> to fire",
|
||||||
ammo: 0,
|
ammo: 0,
|
||||||
ammoPack: 3.15,
|
ammoPack: 3.15,
|
||||||
have: false,
|
have: false,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
function pushAway(range) { //push away blocks when firing
|
function pushAway(range) { //push away blocks when firing
|
||||||
for (let i = 0, len = mob.length; i < len; ++i) {
|
for (let i = 0, len = mob.length; i < len; ++i) {
|
||||||
@@ -4425,6 +4482,7 @@ const b = {
|
|||||||
ammoPack: Infinity,
|
ammoPack: Infinity,
|
||||||
have: false,
|
have: false,
|
||||||
nextFireCycle: 0, //use to remember how longs its been since last fire, used to reset count
|
nextFireCycle: 0, //use to remember how longs its been since last fire, used to reset count
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
|
|
||||||
},
|
},
|
||||||
@@ -4443,10 +4501,10 @@ const b = {
|
|||||||
|
|
||||||
// this.fire = this.firePhoton
|
// this.fire = this.firePhoton
|
||||||
},
|
},
|
||||||
firePhoton() {
|
// firePhoton() {
|
||||||
m.fireCDcycle = m.cycle + Math.floor((tech.isPulseAim ? 25 : 50) * b.fireCD); // cool down
|
// m.fireCDcycle = m.cycle + Math.floor((tech.isPulseAim ? 25 : 50) * b.fireCD); // cool down
|
||||||
b.photon({ x: m.pos.x + 23 * Math.cos(m.angle), y: m.pos.y + 23 * Math.sin(m.angle) }, m.angle)
|
// b.photon({ x: m.pos.x + 23 * Math.cos(m.angle), y: m.pos.y + 23 * Math.sin(m.angle) }, m.angle)
|
||||||
},
|
// },
|
||||||
fireLaser() {
|
fireLaser() {
|
||||||
if (m.energy < tech.laserFieldDrain) {
|
if (m.energy < tech.laserFieldDrain) {
|
||||||
m.fireCDcycle = m.cycle + 100; // cool down if out of energy
|
m.fireCDcycle = m.cycle + 100; // cool down if out of energy
|
||||||
@@ -4616,6 +4674,7 @@ const b = {
|
|||||||
lastFireCycle: 0,
|
lastFireCycle: 0,
|
||||||
holdCount: 0,
|
holdCount: 0,
|
||||||
activeGunIndex: null,
|
activeGunIndex: null,
|
||||||
|
do() {},
|
||||||
fire() {
|
fire() {
|
||||||
if (this.lastFireCycle === m.cycle - 1) { //button has been held down
|
if (this.lastFireCycle === m.cycle - 1) { //button has been held down
|
||||||
this.rewindCount += 8;
|
this.rewindCount += 8;
|
||||||
|
|||||||
13
js/level.js
13
js/level.js
@@ -16,11 +16,11 @@ const level = {
|
|||||||
// simulation.zoomScale = 1000;
|
// simulation.zoomScale = 1000;
|
||||||
// simulation.setZoom();
|
// simulation.setZoom();
|
||||||
// m.setField("nano-scale manufacturing")
|
// m.setField("nano-scale manufacturing")
|
||||||
// b.giveGuns("nail gun")
|
// b.giveGuns("foam")
|
||||||
// tech.isExplodeRadio = true
|
// tech.isExplodeRadio = true
|
||||||
// for (let i = 0; i < 1; i++) tech.giveTech("dynamo-bot")
|
// for (let i = 0; i < 1; i++) tech.giveTech("dynamo-bot")
|
||||||
// tech.giveTech("diffraction grating")
|
// tech.giveTech("superfluidity")
|
||||||
// tech.giveTech("pulse")
|
// tech.giveTech("ice crystal nucleation")
|
||||||
// tech.giveTech("needle gun")
|
// tech.giveTech("needle gun")
|
||||||
// tech.giveTech("cardinality")
|
// tech.giveTech("cardinality")
|
||||||
// tech.giveTech("Bayesian statistics")
|
// tech.giveTech("Bayesian statistics")
|
||||||
@@ -111,7 +111,10 @@ const level = {
|
|||||||
simulation.makeTextLog(`simulation.amplitude <span class='color-symbol'>=</span> ${Math.random()}`);
|
simulation.makeTextLog(`simulation.amplitude <span class='color-symbol'>=</span> ${Math.random()}`);
|
||||||
m.switchWorlds()
|
m.switchWorlds()
|
||||||
simulation.trails()
|
simulation.trails()
|
||||||
for (let i = 0; i < 2; i++) powerUps.spawn(player.position.x + Math.random() * 50, player.position.y - Math.random() * 50, "tech", false);
|
powerUps.spawn(player.position.x + Math.random() * 50, player.position.y - Math.random() * 50, "tech", false);
|
||||||
|
powerUps.spawn(player.position.x + Math.random() * 50, player.position.y - Math.random() * 50, "heal", false);
|
||||||
|
powerUps.spawn(player.position.x + Math.random() * 50, player.position.y - Math.random() * 50, "ammo", false);
|
||||||
|
powerUps.spawn(player.position.x + Math.random() * 50, player.position.y - Math.random() * 50, "research", false);
|
||||||
}
|
}
|
||||||
if (tech.isHealLowHealth) {
|
if (tech.isHealLowHealth) {
|
||||||
const len = Math.floor((m.maxHealth - m.health) / 0.5)
|
const len = Math.floor((m.maxHealth - m.health) / 0.5)
|
||||||
@@ -1108,7 +1111,7 @@ const level = {
|
|||||||
|
|
||||||
// simulation.difficulty = 30
|
// simulation.difficulty = 30
|
||||||
spawn.starter(1900, -500, 100) //big boy
|
spawn.starter(1900, -500, 100) //big boy
|
||||||
// spawn.grower(1900, -500)
|
spawn.grower(1900, -500)
|
||||||
// spawn.pulsarBoss(1900, -500)
|
// spawn.pulsarBoss(1900, -500)
|
||||||
// spawn.shooterBoss(1900, -500)
|
// spawn.shooterBoss(1900, -500)
|
||||||
// spawn.launcherBoss(1200, -500)
|
// spawn.launcherBoss(1200, -500)
|
||||||
|
|||||||
46
js/mob.js
46
js/mob.js
@@ -47,51 +47,55 @@ const mobs = {
|
|||||||
applySlow(who)
|
applySlow(who)
|
||||||
//look for mobs near the target
|
//look for mobs near the target
|
||||||
if (tech.isAoESlow) {
|
if (tech.isAoESlow) {
|
||||||
const range = (320 + 150 * Math.random()) ** 2
|
const range2 = (180 + 170 * Math.random()) ** 2
|
||||||
for (let i = 0, len = mob.length; i < len; i++) {
|
for (let i = 0, len = mob.length; i < len; i++) {
|
||||||
if (Vector.magnitudeSquared(Vector.sub(who.position, mob[i].position)) < range) applySlow(mob[i])
|
if (who !== mob[i] && Vector.magnitudeSquared(Vector.sub(who.position, mob[i].position)) < range2 + mob[i].radius) {
|
||||||
|
console.log(mob[i])
|
||||||
|
applySlow(mob[i])
|
||||||
|
}
|
||||||
}
|
}
|
||||||
simulation.drawList.push({
|
simulation.drawList.push({
|
||||||
x: who.position.x,
|
x: who.position.x,
|
||||||
y: who.position.y,
|
y: who.position.y,
|
||||||
radius: Math.sqrt(range),
|
radius: Math.sqrt(range2),
|
||||||
color: "rgba(0,100,255,0.05)",
|
color: "rgba(0,100,255,0.05)",
|
||||||
time: 3
|
time: simulation.drawTime
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
function applySlow() {
|
function applySlow(whom) {
|
||||||
if (!who.shield && !who.isShielded && !m.isBodiesAsleep) {
|
console.log()
|
||||||
if (who.isBoss) cycles = Math.floor(cycles * 0.25)
|
if (!whom.shield && !whom.isShielded && !m.isBodiesAsleep) {
|
||||||
let i = who.status.length
|
if (whom.isBoss) cycles = Math.floor(cycles * 0.25)
|
||||||
|
let i = whom.status.length
|
||||||
while (i--) {
|
while (i--) {
|
||||||
if (who.status[i].type === "slow") who.status.splice(i, 1); //remove other "slow" effects on this mob
|
if (whom.status[i].type === "slow") whom.status.splice(i, 1); //remove other "slow" effects on this mob
|
||||||
}
|
}
|
||||||
who.isSlowed = true;
|
whom.isSlowed = true;
|
||||||
who.status.push({
|
whom.status.push({
|
||||||
effect() {
|
effect() {
|
||||||
const speedCap = 2
|
const speedCap = 2
|
||||||
const drag = 0.95
|
const drag = 0.95
|
||||||
Matter.Body.setVelocity(who, {
|
Matter.Body.setVelocity(whom, {
|
||||||
x: Math.min(speedCap, who.velocity.x) * drag,
|
x: Math.min(speedCap, whom.velocity.x) * drag,
|
||||||
y: Math.min(speedCap, who.velocity.y) * drag
|
y: Math.min(speedCap, whom.velocity.y) * drag
|
||||||
});
|
});
|
||||||
Matter.Body.setAngularVelocity(who, 0);
|
Matter.Body.setAngularVelocity(whom, 0);
|
||||||
ctx.beginPath();
|
ctx.beginPath();
|
||||||
ctx.moveTo(who.vertices[0].x, who.vertices[0].y);
|
ctx.moveTo(whom.vertices[0].x, whom.vertices[0].y);
|
||||||
for (let j = 1, len = who.vertices.length; j < len; ++j) {
|
for (let j = 1, len = whom.vertices.length; j < len; ++j) {
|
||||||
ctx.lineTo(who.vertices[j].x, who.vertices[j].y);
|
ctx.lineTo(whom.vertices[j].x, whom.vertices[j].y);
|
||||||
}
|
}
|
||||||
ctx.lineTo(who.vertices[0].x, who.vertices[0].y);
|
ctx.lineTo(whom.vertices[0].x, whom.vertices[0].y);
|
||||||
ctx.strokeStyle = "rgba(0,100,255,0.8)";
|
ctx.strokeStyle = "rgba(0,100,255,0.8)";
|
||||||
ctx.lineWidth = 15;
|
ctx.lineWidth = 15;
|
||||||
ctx.stroke();
|
ctx.stroke();
|
||||||
ctx.fillStyle = who.fill
|
ctx.fillStyle = whom.fill
|
||||||
ctx.fill();
|
ctx.fill();
|
||||||
},
|
},
|
||||||
endEffect() {
|
endEffect() {
|
||||||
//check to see if there are not other freeze effects?
|
//check to see if there are not other freeze effects?
|
||||||
who.isSlowed = false;
|
whom.isSlowed = false;
|
||||||
},
|
},
|
||||||
type: "slow",
|
type: "slow",
|
||||||
endCycle: simulation.cycle + cycles,
|
endCycle: simulation.cycle + cycles,
|
||||||
|
|||||||
@@ -1660,7 +1660,7 @@ const m = {
|
|||||||
m.holdingMassScale = 0.01; //can hold heavier blocks with lower cost to jumping
|
m.holdingMassScale = 0.01; //can hold heavier blocks with lower cost to jumping
|
||||||
m.fieldMeterColor = "#333"
|
m.fieldMeterColor = "#333"
|
||||||
m.eyeFillColor = m.fieldMeterColor
|
m.eyeFillColor = m.fieldMeterColor
|
||||||
m.fieldHarmReduction = 0.55;
|
m.fieldHarmReduction = 0.45; //55% reduction
|
||||||
m.fieldDrawRadius = 0;
|
m.fieldDrawRadius = 0;
|
||||||
|
|
||||||
m.hold = function() {
|
m.hold = function() {
|
||||||
|
|||||||
@@ -250,10 +250,9 @@ const simulation = {
|
|||||||
ctx.fillStyle = simulation.drawList[i].color;
|
ctx.fillStyle = simulation.drawList[i].color;
|
||||||
ctx.fill();
|
ctx.fill();
|
||||||
if (simulation.drawList[i].time) {
|
if (simulation.drawList[i].time) {
|
||||||
//remove when timer runs out
|
|
||||||
simulation.drawList[i].time--;
|
simulation.drawList[i].time--;
|
||||||
} else {
|
} else {
|
||||||
simulation.drawList.splice(i, 1);
|
if (!m.isBodiesAsleep) simulation.drawList.splice(i, 1); //remove when timer runs out
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
16
js/tech.js
16
js/tech.js
@@ -159,6 +159,10 @@
|
|||||||
spawn.randomLevelBoss(m.pos.x, m.pos.y + range, bossOptions);
|
spawn.randomLevelBoss(m.pos.x, m.pos.y + range, bossOptions);
|
||||||
spawn.randomLevelBoss(m.pos.x - range, m.pos.y, bossOptions);
|
spawn.randomLevelBoss(m.pos.x - range, m.pos.y, bossOptions);
|
||||||
spawn.randomLevelBoss(m.pos.x, m.pos.y - range, bossOptions);
|
spawn.randomLevelBoss(m.pos.x, m.pos.y - range, bossOptions);
|
||||||
|
spawn.randomLevelBoss(m.pos.x + range, m.pos.y + range, bossOptions);
|
||||||
|
spawn.randomLevelBoss(m.pos.x + range, m.pos.y - range, bossOptions);
|
||||||
|
spawn.randomLevelBoss(m.pos.x - range, m.pos.y + range, bossOptions);
|
||||||
|
spawn.randomLevelBoss(m.pos.x - range, m.pos.y - range, bossOptions);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
tech: [{
|
tech: [{
|
||||||
@@ -2399,7 +2403,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "many-worlds",
|
name: "many-worlds",
|
||||||
description: "each new <strong>level</strong> is an <strong>alternate reality</strong><br> find <strong>2</strong> <strong class='color-m'>tech</strong> power ups in that reality",
|
description: "each <strong>level</strong> is an <strong>alternate reality</strong>, where you<br>find a <strong class='color-m'>tech</strong>, <strong class='color-h'>heal</strong>, <strong class='color-g'>ammo</strong>, and <strong class='color-r'>research</strong>",
|
||||||
maxCount: 1,
|
maxCount: 1,
|
||||||
count: 0,
|
count: 0,
|
||||||
frequency: 1,
|
frequency: 1,
|
||||||
@@ -2711,7 +2715,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "parthenogenesis",
|
name: "parthenogenesis",
|
||||||
description: "each level has a chance to spawn a <strong>level boss</strong><br>equal to <strong>double</strong> your <strong class='color-dup'>duplication</strong> chance",
|
description: "levels have a chance to spawn a 2nd <strong>boss</strong><br>equal to <strong>double</strong> your <strong class='color-dup'>duplication</strong> chance",
|
||||||
maxCount: 1,
|
maxCount: 1,
|
||||||
count: 0,
|
count: 0,
|
||||||
frequency: 2,
|
frequency: 2,
|
||||||
@@ -2728,14 +2732,14 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "apomixis",
|
name: "apomixis",
|
||||||
description: "after reaching <strong>100%</strong> <strong class='color-dup'>duplication</strong> chance<br>immediately spawn <strong>4 level bosses</strong>",
|
description: "after reaching <strong>100%</strong> <strong class='color-dup'>duplication</strong> chance<br>immediately spawn <strong>8 bosses</strong>",
|
||||||
maxCount: 1,
|
maxCount: 1,
|
||||||
count: 0,
|
count: 0,
|
||||||
frequency: 2,
|
frequency: 6,
|
||||||
allowed() {
|
allowed() {
|
||||||
return tech.isDuplicateBoss
|
return tech.duplicationChance() > 0.66
|
||||||
},
|
},
|
||||||
requires: "parthenogenesis",
|
requires: "duplication chance above 66%",
|
||||||
effect() {
|
effect() {
|
||||||
tech.is100Duplicate = true;
|
tech.is100Duplicate = true;
|
||||||
tech.maxDuplicationEvent()
|
tech.maxDuplicationEvent()
|
||||||
|
|||||||
47
todo.txt
47
todo.txt
@@ -1,15 +1,13 @@
|
|||||||
******************************************************** NEXT PATCH ********************************************************
|
******************************************************** NEXT PATCH ********************************************************
|
||||||
|
|
||||||
perfect diamagnetism now has a 1/12 of a second cooldown after blocking (1/2 other fields)
|
apomixis spawns 8 bosses (up from 4)
|
||||||
perfect diamagnetism can get bremsstrahlung now
|
|
||||||
|
|
||||||
standing wave harmonic field blocks now block large mobs more reliably
|
foam gun now charges up until you release the fire button
|
||||||
|
|
||||||
tech: triple point - blocking makes iceIX crystals
|
|
||||||
unlocked with: standing wave harmonic field or perfect diamagnetism
|
|
||||||
|
|
||||||
******************************************************** BUGS ********************************************************
|
******************************************************** BUGS ********************************************************
|
||||||
|
|
||||||
|
increase the width on the grid by a few pixels so that very small screens or people with odd fonts don't goto a new line
|
||||||
|
|
||||||
you have to press z once to get copy to work for simulation.enableConstructMode() sometimes
|
you have to press z once to get copy to work for simulation.enableConstructMode() sometimes
|
||||||
not sure how to reproduce, but it happens often on the first draw
|
not sure how to reproduce, but it happens often on the first draw
|
||||||
|
|
||||||
@@ -38,34 +36,10 @@ fix door.isOpen actually meaning isClosed?
|
|||||||
|
|
||||||
******************************************************** TODO ********************************************************
|
******************************************************** TODO ********************************************************
|
||||||
|
|
||||||
tech: pressing the gun switch keys instead cycles through bot upgrades, switching all of your bots accordingly
|
|
||||||
|
|
||||||
import the procedural level generation from one of the older versions of the game as one single level
|
|
||||||
|
|
||||||
tech plasma field - plasma field becomes an aoe damage field with the same radius
|
tech plasma field - plasma field becomes an aoe damage field with the same radius
|
||||||
200% more energy drain, 100% more damage
|
200% more energy drain, 100% more damage
|
||||||
draw a square (or two) that rapidly spins
|
draw a square (or two) that rapidly spins
|
||||||
|
|
||||||
blocking produces ice-IX
|
|
||||||
at the block location?
|
|
||||||
how to get bullets to not hit the blocked mob
|
|
||||||
spawn at player head?
|
|
||||||
only applies to blocking with a cool down
|
|
||||||
nano-scale?
|
|
||||||
standing wave harmonics
|
|
||||||
maybe just a chance to proc for perfect diamagnetism
|
|
||||||
|
|
||||||
tech field: while _____ is active take 100% more harm and do 100% more damage
|
|
||||||
while firing
|
|
||||||
or while plasma field is active
|
|
||||||
|
|
||||||
quantum foam: hold fire to charge up foam, release fire to let go an amount relative to hold long you held fire
|
|
||||||
foam gun fires a bullet that tracks how long mouse is down
|
|
||||||
when mouse is up it streams out a hose of foam based on how long foam was down
|
|
||||||
bullet is small and hidden
|
|
||||||
|
|
||||||
flipflop, but toggles after a kill
|
|
||||||
|
|
||||||
new level: procedural generation
|
new level: procedural generation
|
||||||
several small rooms are linked by portals
|
several small rooms are linked by portals
|
||||||
the portals have a randomized pattern
|
the portals have a randomized pattern
|
||||||
@@ -93,18 +67,9 @@ mob vision: look at player history
|
|||||||
https://abitawake.com/news/articles/enemy-ai-chasing-a-player-without-navigation2d-or-a-star-pathfinding
|
https://abitawake.com/news/articles/enemy-ai-chasing-a-player-without-navigation2d-or-a-star-pathfinding
|
||||||
write find in spawn undo exploder, but commented out
|
write find in spawn undo exploder, but commented out
|
||||||
|
|
||||||
tech: chitin - take 50% less damage, reduce harm reduction by 5% after each collision
|
|
||||||
|
|
||||||
Mob: "Tentacle": Sits on wall. Is a black blob. When you get near it, reaches out and grabs you, similar to wires. Does not deal damage.
|
Mob: "Tentacle": Sits on wall. Is a black blob. When you get near it, reaches out and grabs you, similar to wires. Does not deal damage.
|
||||||
maybe it could be immune to damage? but it is spawned by an actual mob
|
maybe it could be immune to damage? but it is spawned by an actual mob
|
||||||
|
|
||||||
wormhole, or CPT tech: after taking damage teleport in direction of mouse
|
|
||||||
after collision
|
|
||||||
|
|
||||||
mob sniper: draw aim graphics before fire
|
|
||||||
|
|
||||||
tech laser: photon - laser, but it can only move 100 pixels a cycle
|
|
||||||
|
|
||||||
mob - after taking damage
|
mob - after taking damage
|
||||||
attack outwardly
|
attack outwardly
|
||||||
grows
|
grows
|
||||||
@@ -135,10 +100,6 @@ lore: a tutorial / lore intro
|
|||||||
put something on the intro map
|
put something on the intro map
|
||||||
maybe a button triggers something
|
maybe a button triggers something
|
||||||
|
|
||||||
tech: add an eject button for each power up in the pause menu
|
|
||||||
also list all bot types in pause menu
|
|
||||||
with option to eject?
|
|
||||||
|
|
||||||
add back in gamepad support
|
add back in gamepad support
|
||||||
but does anyone care?
|
but does anyone care?
|
||||||
https://github.com/landgreen/landgreen.github.io/search?q=gamepadconnected
|
https://github.com/landgreen/landgreen.github.io/search?q=gamepadconnected
|
||||||
|
|||||||
Reference in New Issue
Block a user