Meissner effect

perfect diamagnetism can maintain after you deactivate the field with out tech: Lenz's law
  starting perfect diamagnetism is a bit smaller
tech: Meissner effect - makes perfect diamagnetism much bigger

plasma-bot removes plasma field
  plasma-bot uses much less energy and does a bit more damage
plasma jet requires 1 research, increases range 50% (was 30%)
tech microextruder does 30% more damage and uses 10% more energy
This commit is contained in:
landgreen
2021-08-16 06:05:37 -07:00
parent 37d31ffb76
commit 03d97f75b2
7 changed files with 78 additions and 50 deletions

BIN
.DS_Store vendored

Binary file not shown.

View File

@@ -1211,7 +1211,7 @@ const b = {
didExtruderDrain: false,
canExtruderFire: true,
extruder() {
const DRAIN = 0.0007 + m.fieldRegen
const DRAIN = 0.0008 + m.fieldRegen
if (m.energy > DRAIN && b.canExtruderFire) {
m.energy -= DRAIN
if (m.energy < 0) {
@@ -1230,7 +1230,7 @@ const b = {
frictionAir: 0,
isInHole: true, //this keeps the bullet from entering wormholes
minDmgSpeed: 0,
dmg: b.dmgScale * 1.4, //damage also changes when you divide by mob.mass on in .do()
dmg: b.dmgScale * 1.8, //damage also changes when you divide by mob.mass on in .do()
classType: "bullet",
isBranch: false,
restitution: 0,
@@ -3403,7 +3403,7 @@ const b = {
cd: 0,
acceleration: 0.009,
endCycle: Infinity,
drainThreshold: tech.isEnergyHealth ? 0.5 : 0.33,
drainThreshold: tech.isEnergyHealth ? 0.5 : 0.05,
classType: "bullet",
collisionFilter: {
category: cat.bullet,
@@ -3443,7 +3443,7 @@ const b = {
const DIST = Vector.magnitude(sub);
const unit = Vector.normalise(sub)
if (DIST < tech.isPlasmaRange * 450 && m.energy > this.drainThreshold) {
m.energy -= 0.005;
m.energy -= 0.0003 + m.fieldRegen //0.004; //normal plasma field is 0.00008 + m.fieldRegen = 0.00108
// if (m.energy < 0) {
// m.fieldCDcycle = m.cycle + 120;
// m.energy = 0;
@@ -3518,7 +3518,7 @@ const b = {
y: best.y
};
if (best.who.alive) {
const dmg = 0.6 * b.dmgScale; //********** SCALE DAMAGE HERE *********************
const dmg = 0.65 * b.dmgScale; //********** SCALE DAMAGE HERE *********************
best.who.damage(dmg);
best.who.locatePlayer();
//push mobs away

View File

@@ -17,7 +17,7 @@ const level = {
// tech.isFieldFree = true
// m.setField("perfect diamagnetism")
// b.giveGuns("drones")
// tech.giveTech("laser-bot")
// tech.giveTech("Meissner effect")
// b.giveGuns("nail gun")
// tech.giveTech("Lenz's law")
// for (let i = 0; i < 9; i++) tech.giveTech("MIRV")
@@ -2316,7 +2316,7 @@ const level = {
// spawn.randomSmallMob(1300, -70);
// spawn.randomMob(2650, -975, 0.8);
// spawn.randomGroup(1700, -900, 0.4);
// if (simulation.difficulty > 3) spawn.randomLevelBoss(2200, -1300);
// if (simulation.difficulty > 1) spawn.randomLevelBoss(2200, -1300);
powerUps.addResearchToLevel() //needs to run after mobs are spawned
},
final() {
@@ -3091,7 +3091,7 @@ const level = {
spawn.randomMob(3600, 1725, 0.9);
spawn.randomMob(4100, 1225, 0.9);
spawn.randomMob(2825, 400, 0.9);
if (simulation.difficulty > 3) spawn.randomLevelBoss(6000, 2300, ["spiderBoss", "launcherBoss", "laserTargetingBoss", "streamBoss", "historyBoss", "orbitalBoss", "grenadierBoss"]);
if (simulation.difficulty > 1) spawn.randomLevelBoss(6000, 2300, ["spiderBoss", "launcherBoss", "laserTargetingBoss", "streamBoss", "historyBoss", "orbitalBoss", "grenadierBoss"]);
powerUps.addResearchToLevel() //needs to run after mobs are spawned
spawn.secondaryBossChance(7725, 2275)
@@ -3266,7 +3266,7 @@ const level = {
spawn.randomGroup(2700, -1600, 0.1);
spawn.randomGroup(1600, -100, 0);
spawn.randomGroup(5000, -3900, -0.3);
if (simulation.difficulty > 3) {
if (simulation.difficulty > 1) {
if (Math.random() < 0.25) {
spawn.randomLevelBoss(2800, -1400);
} else if (Math.random() < 0.25) {
@@ -3449,7 +3449,7 @@ const level = {
spawn.randomGroup(600, -1575, 0);
spawn.randomGroup(2225, -1325, 0.4);
spawn.randomGroup(4900, -1200, 0);
if (simulation.difficulty > 3) spawn.randomLevelBoss(3200, -1900);
if (simulation.difficulty > 1) spawn.randomLevelBoss(3200, -1900);
powerUps.addResearchToLevel() //needs to run after mobs are spawned
spawn.secondaryBossChance(2175, -2425)
@@ -3643,7 +3643,7 @@ const level = {
spawn.randomMob(3575, -2425, 0.5);
spawn.randomMob(3975, -3900, 0.5);
spawn.randomMob(1725, 125, 0.5);
if (simulation.difficulty > 3) {
if (simulation.difficulty > 1) {
if (Math.random() < 0.33) {
spawn.randomLevelBoss(4250, -250);
spawn.debris(-250, 50, 1650, 2); //16 debris per level
@@ -3834,7 +3834,7 @@ const level = {
spawn.randomMob(-100, -1700, -0.2);
spawn.randomGroup(3700, -1500, 0.4);
spawn.randomGroup(1700, -900, 0.4);
if (simulation.difficulty > 3) spawn.randomLevelBoss(2600, -2300);
if (simulation.difficulty > 1) spawn.randomLevelBoss(2600, -2300);
powerUps.addResearchToLevel() //needs to run after mobs are spawned
spawn.secondaryBossChance(3075, -2050)
@@ -4076,7 +4076,7 @@ const level = {
spawn.randomGroup(-3250, -2700, 0.2);
spawn.randomGroup(-2450, -1100, 0);
if (simulation.difficulty > 3) spawn.randomLevelBoss(-2400, -2650);
if (simulation.difficulty > 1) spawn.randomLevelBoss(-2400, -2650);
powerUps.addResearchToLevel() //needs to run after mobs are spawned
spawn.secondaryBossChance(-1825, -1975)
@@ -4386,7 +4386,7 @@ const level = {
spawn.randomSmallMob(-2325, 800);
spawn.randomSmallMob(-900, 825);
if (simulation.difficulty > 3) {
if (simulation.difficulty > 1) {
if (Math.random() < 0.33) {
spawn.randomLevelBoss(-800, -1300)
} else {
@@ -4615,7 +4615,7 @@ const level = {
spawn.randomMob(950, -1150, -0.1);
spawn.randomGroup(1800, -800, -0.2);
spawn.randomGroup(4150, -1000, 0.6);
if (simulation.difficulty > 3) {
if (simulation.difficulty > 1) {
if (Math.random() < 0.5) {
spawn.tetherBoss(2850, -80, { x: 2500, y: -500 })
//chance to spawn a ring of exploding mobs around this boss
@@ -4836,7 +4836,9 @@ const level = {
spawn.randomGroup(2350, -850, 1);
spawn.randomGroup(100, -450, 0.9);
if (simulation.difficulty > 3) spawn.randomLevelBoss(1850, -1400);
if (simulation.difficulty > 1) spawn.randomLevelBoss(1850, -1400);
spawn.secondaryBossChance(1850, -1400)
powerUps.addResearchToLevel() //needs to run after mobs are spawned
},
basement() { // player made level by Francois 👑 from discord
@@ -5063,22 +5065,22 @@ const level = {
spawn.mapRect(2050, -1225, 75, 100); //Plateforme over acid
// MOBS
if (isLevelReversed === false) { ///Normal spawn
if (simulation.difficulty > 2) {
if (simulation.difficulty > 1) {
if (Math.random() < 0.2) {
// tether ball
spawn.tetherBoss(7000, -3300, { x: 7300, y: -3300 })
if (simulation.difficulty > 4) spawn.nodeGroup(7000, -3300, "spawns", 8, 20, 105);
} else if (simulation.difficulty > 3) {
} else {
spawn.randomLevelBoss(6100, -3600, ["shooterBoss", "launcherBoss", "laserTargetingBoss", "spiderBoss", "laserBoss", "pulsarBoss"]);
}
}
} else { /// Reversed spawn
if (simulation.difficulty > 2) {
if (simulation.difficulty > 1) {
if (Math.random() < 0.2) {
// tether ball
spawn.tetherBoss(2300, -1300, { x: 2300, y: -1750 })
if (simulation.difficulty > 4) spawn.nodeGroup(2350, -1300, "spawns", 8, 20, 105);
} else if (simulation.difficulty > 3) {
} else {
spawn.randomLevelBoss(2300, -1400, ["shooterBoss", "launcherBoss", "laserTargetingBoss", "spiderBoss", "laserBoss", "snakeBoss", "pulsarBoss"]);
}
}
@@ -5136,8 +5138,9 @@ const level = {
spawn.mapRect(3300, 1075, 1500, 1800); //Mur droite salle trésor
// tether ball
spawn.tetherBoss(2330, 1850, { x: 2330, y: 1425 })
spawn.secondaryBossChance(2330, 1850)
//chance to spawn a ring of exploding mobs around this boss
if (simulation.difficulty > 4) spawn.nodeGroup(2330, 1850, "spawns", 8, 20, 105);
if (simulation.difficulty > 1) spawn.nodeGroup(2330, 1850, "spawns", 8, 20, 105);
powerUps.chooseRandomPowerUp(3100, 1630);
},
detours() { //by Francois from discord
@@ -5419,6 +5422,7 @@ const level = {
// if (simulation.difficulty > 4) spawn.nodeGroup(8000, 630, "spawns", 8, 20, 105);
// } else {
spawn.randomLevelBoss(8000, 630, ["shooterBoss", "launcherBoss", "laserTargetingBoss", "spiderBoss", "laserBoss", "bomberBoss", "orbitalBoss", "pulsarBoss"]);
spawn.secondaryBossChance(8000, 630)
//find level boss index
let me
for (let i = 0, len = mob.length; i < len; i++) {
@@ -5918,6 +5922,7 @@ const level = {
spawn.randomGroup(630, -1300, -0.1);
spawn.randomGroup(3450, -2880, -0.2)
if (simulation.difficulty > 3) {
spawn.secondaryBossChance(3380, -1775)
if (Math.random() < 0.16) {
spawn.tetherBoss(3380, -1775, { x: 3775, y: -1775 })
if (simulation.difficulty > 4) spawn.nodeGroup(3380, -1775, "spawns", 8, 20, 105); //chance to spawn a ring of exploding mobs around this boss

View File

@@ -1577,7 +1577,7 @@ const m = {
},
{
name: "perfect diamagnetism",
description: "<strong>attract</strong> power ups from <strong>far away</strong><br><strong>deflecting</strong> does not drain <strong class='color-f'>energy</strong><br><strong>deflecting</strong> has <strong>90%</strong> less <strong>recoil</strong>",
description: "<strong>attract</strong> power ups from <strong>far away</strong><br><strong>deflecting</strong> does not drain <strong class='color-f'>energy</strong><br>maintains <strong>functionality</strong> while <strong>inactive</strong>",
// description: "<strong>attract</strong> power ups from <strong>far away</strong><br><strong>deflecting</strong> doesn't drain <strong class='color-f'>energy</strong><br>thrown <strong class='color-block'>blocks</strong> have",
// description: "gain <strong class='color-f'>energy</strong> when <strong>blocking</strong><br>no <strong>recoil</strong> when <strong>blocking</strong>",
effect: () => {
@@ -1681,8 +1681,8 @@ const m = {
}
m.hold = function() {
const wave = Math.sin(m.cycle * 0.022);
m.fieldRange = 190 + 12 * wave
m.fieldArc = 0.36 + 0.04 * wave //run calculateFieldThreshold after setting fieldArc, used for powerUp grab and mobPush with lookingAt(mob)
m.fieldRange = 160 + 12 * wave + 100 * tech.isBigField
m.fieldArc = 0.34 + 0.04 * wave + 0.065 * tech.isBigField //run calculateFieldThreshold after setting fieldArc, used for powerUp grab and mobPush with lookingAt(mob)
m.calculateFieldThreshold();
if (m.isHolding) {
m.drawHold(m.holdingTarget);
@@ -1722,7 +1722,7 @@ const m = {
m.pickUp();
} else {
m.holdingTarget = null; //clears holding target (this is so you only pick up right after the field button is released and a hold target exists)
if (!input.field) { //tech.isFieldFre
if (!input.field) { //&& tech.isFieldFree
//draw field free of player
ctx.fillStyle = "rgba(110,170,200," + (0.27 + 0.2 * Math.random() - 0.1 * wave) + ")";
ctx.strokeStyle = "rgba(110, 200, 235, " + (0.4 + 0.5 * Math.random()) + ")"

View File

@@ -98,6 +98,7 @@ const spawn = {
} else {
tech.addJunkTechToPool(49)
}
console.log('hi')
spawn.randomLevelBoss(x, y);
}
},

View File

@@ -5373,8 +5373,8 @@
}
},
{
name: "Lenz's law",
description: "after deactivation <strong>perfect diamagnetism</strong><br>maintains at the <strong>location</strong> you left it",
name: "Meissner effect",
description: "increase <strong>perfect diamagnetism</strong> field<br><strong>radius</strong> by <strong>55%</strong> and circular <strong>arc</strong> by <strong>22°</strong>",
isFieldTech: true,
maxCount: 1,
count: 0,
@@ -5385,10 +5385,10 @@
},
requires: "perfect diamagnetism",
effect() {
tech.isFieldFree = true;
tech.isBigField = true;
},
remove() {
tech.isFieldFree = false;
tech.isBigField = false;
}
},
{
@@ -5708,7 +5708,7 @@
// },
{
name: "plasma-bot",
description: "use <strong>1</strong> <strong class='color-r'>research</strong> to build a <strong class='color-bot'>bot</strong><br>that uses <strong class='color-f'>energy</strong> to emit <strong class='color-plasma'>plasma</strong>",
description: "remove your <strong>field</strong> to build a <strong class='color-bot'>bot</strong><br>that uses <strong class='color-f'>energy</strong> to emit <strong class='color-plasma'>plasma</strong>",
isFieldTech: true,
maxCount: 1,
count: 0,
@@ -5717,40 +5717,52 @@
isBot: true,
isBotTech: true,
allowed() {
return m.fieldUpgrades[m.fieldMode].name === "plasma torch" && (build.isExperimentSelection || powerUps.research.count > 0)
return !tech.isExtruder && m.fieldUpgrades[m.fieldMode].name === "plasma torch" && (build.isExperimentSelection || powerUps.research.count > 0)
},
requires: "plasma torch",
requires: "plasma torch, not micro-extruder",
effect() {
tech.plasmaBotCount++;
b.plasmaBot();
for (let i = 0; i < 1; i++) {
if (powerUps.research.count > 0) powerUps.research.changeRerolls(-1)
if (build.isExperimentSelection) {
document.getElementById("field-" + m.fieldMode).classList.remove("build-field-selected");
document.getElementById("field-0").classList.add("build-field-selected");
}
m.setField("field emitter")
},
remove() {
if (this.count > 0) {
tech.plasmaBotCount = 0;
b.clearPermanentBots();
b.respawnBots();
if (this.count > 0) powerUps.research.changeRerolls(1)
if (m.fieldMode === 0) {
m.setField("plasma torch")
if (build.isExperimentSelection) {
document.getElementById("field-0").classList.remove("build-field-selected");
document.getElementById("field-" + m.fieldMode).classList.add("build-field-selected");
}
}
}
}
},
{
name: "plasma jet",
description: "increase <strong class='color-plasma'>plasma</strong> <strong>torch's</strong> range by <strong>30%</strong>",
description: "use <strong>1</strong> <strong class='color-r'>research</strong> to <br>increase <strong class='color-plasma'>plasma</strong> <strong>torch's</strong> range by <strong>50%</strong>",
isFieldTech: true,
maxCount: 9,
maxCount: 3,
count: 0,
frequency: 2,
frequencyDefault: 2,
allowed() {
return m.fieldUpgrades[m.fieldMode].name === "plasma torch" && !tech.isExtruder
return (tech.plasmaBotCount || (m.fieldUpgrades[m.fieldMode].name === "plasma torch" && !tech.isExtruder)) && (build.isExperimentSelection || powerUps.research.count > 0)
},
requires: "plasma torch, not micro-extruder",
effect() {
tech.isPlasmaRange += 0.3;
tech.isPlasmaRange += 0.5;
if (powerUps.research.count > 0) powerUps.research.changeRerolls(-1)
},
remove() {
tech.isPlasmaRange = 1;
if (this.count > 0) powerUps.research.changeRerolls(this.count)
}
},
{
@@ -5781,9 +5793,9 @@
frequency: 2,
frequencyDefault: 2,
allowed() {
return m.fieldUpgrades[m.fieldMode].name === "plasma torch" && tech.isPlasmaRange === 1
return m.fieldUpgrades[m.fieldMode].name === "plasma torch" && tech.isPlasmaRange === 1 && tech.plasmaBotCount === 0
},
requires: "plasma torch, not plasma jet",
requires: "plasma torch, not plasma jet, plasma-bot",
effect() {
tech.isExtruder = true;
},
@@ -7865,5 +7877,6 @@
isZeno: null,
isFieldFree: null,
wormSurviveDmg: null,
isExtraGunField: null
isExtraGunField: null,
isBigField: null
}

View File

@@ -1,14 +1,23 @@
******************************************************** NEXT PATCH ********************************************************
relativistic momentum: laser pushes harder and slows mobs a bit to give a more predictable effect
laserBombingBoss targets faster at higher levels
you can now block shielded mobs, but your shield gets disabled for a bit
perfect diamagnetism can maintain after you deactivate the field with out tech: Lenz's law
starting perfect diamagnetism is a bit smaller
tech: Meissner effect - makes perfect diamagnetism much bigger
fixed bug that made perfect diamagnetism have trouble blocking too many things at once
and more small bug fixes, of course
plasma-bot removes plasma field
plasma-bot uses much less energy and does a bit more damage
plasma jet requires 1 research, increases range 50% (was 30%)
tech microextruder does 30% more damage and uses 10% more energy
******************************************************** TODO ********************************************************
plasma bot removes your field
buff plasma bot? (not sure you need to)
spawn a field power up?
no need it will show up on next boss
requires not plasma wire tech
can tokamak work outside plasma field?
mob: spawning seekers on death
drones can combine with other drones to get bigger?