needle ice
tech: needle ice - needles make 1-2 ice 9 after they impact a wall needle shot gun fires 1 less needle most harpoon tech are about 5% better JUNK tech: negative friction - you speed up when you touch walls no-cloning theorem: 42% -> 38% dup chance symbiosis: 2 tech -> 1-2 tech after a boss dies quenching gives 10% less max health for over heal
This commit is contained in:
12
js/bullet.js
12
js/bullet.js
@@ -3099,6 +3099,10 @@ const b = {
|
||||
this.do = function() {
|
||||
if (!Matter.Query.collides(this, map).length) this.force.y += this.mass * 0.001;
|
||||
}
|
||||
if (tech.isNeedleIce) {
|
||||
b.iceIX(5 + 5 * Math.random(), 2 * Math.PI * Math.random(), this.position) // iceIX(speed = 0, dir = m.angle + Math.PI * 2 * Math.random(), where = { x: m.pos.x + 30 * Math.cos(m.angle), y: m.pos.y + 30 * Math.sin(m.angle) }) {
|
||||
if (0.5 < Math.random()) b.iceIX(5 + 5 * Math.random(), 2 * Math.PI * Math.random(), this.position)
|
||||
}
|
||||
} else if (this.speed < 30) {
|
||||
this.force.y += this.mass * 0.001; //no gravity until it slows down to improve aiming
|
||||
}
|
||||
@@ -4332,7 +4336,7 @@ const b = {
|
||||
b.foam(where, { x: SPEED * Math.cos(angle), y: SPEED * Math.sin(angle) }, 5 + 8 * Math.random())
|
||||
}
|
||||
} else if (tech.isNeedleShot) {
|
||||
const number = 11 * (tech.isShotgunReversed ? 1.6 : 1)
|
||||
const number = 9 * (tech.isShotgunReversed ? 1.6 : 1)
|
||||
const spread = (input.down ? 0.03 : 0.05)
|
||||
let angle = m.angle - (number - 1) * spread * 0.5
|
||||
for (let i = 0; i < number; i++) {
|
||||
@@ -5187,8 +5191,8 @@ const b = {
|
||||
}
|
||||
//look for closest mob in player's LoS
|
||||
const dir = { x: Math.cos(m.angle), y: Math.sin(m.angle) }; //make a vector for the player's direction of length 1; used in dot product
|
||||
const length = tech.isLargeHarpoon ? 1 + 0.09 * Math.sqrt(this.ammo) : 1
|
||||
const totalCycles = 7 * (tech.isFilament ? 1 + 0.009 * Math.min(100, this.ammo) : 1) * Math.sqrt(length)
|
||||
const length = tech.isLargeHarpoon ? 1 + 0.1 * Math.sqrt(this.ammo) : 1
|
||||
const totalCycles = 7 * (tech.isFilament ? 1 + 0.01 * Math.min(110, this.ammo) : 1) * Math.sqrt(length)
|
||||
if (input.down) {
|
||||
// if (true) {
|
||||
// if (m.immuneCycle < m.cycle + 60) m.immuneCycle = m.cycle + tech.collisionImmuneCycles; //player is immune to damage for 30 cycles
|
||||
@@ -5214,7 +5218,7 @@ const b = {
|
||||
m.fireCDcycle = m.cycle + 50 * b.fireCDscale; // cool down
|
||||
// }
|
||||
} else if (tech.extraHarpoons) {
|
||||
const range = 450 * (tech.isFilament ? 1 + Math.min(100, this.ammo) / 100 : 1)
|
||||
const range = 450 * (tech.isFilament ? 1 + 0.005 * Math.min(110, this.ammo) : 1)
|
||||
let targetCount = 0
|
||||
for (let i = 0, len = mob.length; i < len; ++i) {
|
||||
if (mob[i].alive && !mob[i].isBadTarget && !mob[i].shield && Matter.Query.ray(map, m.pos, mob[i].position).length === 0) {
|
||||
|
||||
@@ -16,8 +16,8 @@ const level = {
|
||||
// level.difficultyIncrease(30) //30 is near max on hard //60 is near max on why
|
||||
// simulation.isHorizontalFlipped = true
|
||||
// m.setField("plasma torch")
|
||||
// b.giveGuns("railgun")
|
||||
// tech.giveTech("aerodynamic heating")
|
||||
// b.giveGuns("nail gun")
|
||||
// tech.giveTech("negative friction")
|
||||
// for (let i = 0; i < 2; i++) tech.giveTech("refractory metal")
|
||||
// tech.giveTech("all-stars")
|
||||
// for (let i = 0; i < 3; i++) tech.giveTech("overcharge")
|
||||
|
||||
@@ -1139,7 +1139,8 @@ const mobs = {
|
||||
}
|
||||
if (tech.isAddRemoveMaxHealth) {
|
||||
if (this.isBoss && this.isDropPowerUp) {
|
||||
for (let i = 0; i < 2; i++) powerUps.spawn(this.position.x, this.position.y, "tech", false) //exit
|
||||
powerUps.spawn(this.position.x, this.position.y, "tech", false)
|
||||
if (0.5 < Math.random()) powerUps.spawn(this.position.x, this.position.y, "tech", false)
|
||||
} else {
|
||||
const amount = 0.01
|
||||
if (tech.isEnergyHealth) {
|
||||
|
||||
@@ -424,10 +424,9 @@ const powerUps = {
|
||||
simulation.makeTextLog(`<span class='color-var'>m</span>.health <span class='color-symbol'>+=</span> ${(healOutput).toFixed(3)}`) // <br>${m.health.toFixed(3)}
|
||||
|
||||
if (tech.isOverHeal && overHeal > 0) { //tech quenching
|
||||
const scaledOverHeal = overHeal * 0.8
|
||||
const scaledOverHeal = overHeal * 0.7
|
||||
m.damage(scaledOverHeal);
|
||||
simulation.makeTextLog(`<span class='color-var'>m</span>.health <span class='color-symbol'>-=</span> ${(scaledOverHeal).toFixed(3)}`) // <br>${m.health.toFixed(3)}
|
||||
|
||||
//draw damage
|
||||
simulation.drawList.push({ //add dmg to draw queue
|
||||
x: m.pos.x,
|
||||
|
||||
52
js/tech.js
52
js/tech.js
@@ -3700,6 +3700,25 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
name: "needle ice",
|
||||
description: `when <strong>needles</strong> impact walls<br>they chip off <strong>1-2</strong> freezing <strong class='color-s'>ice IX</strong> crystals`,
|
||||
isGunTech: true,
|
||||
maxCount: 1,
|
||||
count: 0,
|
||||
frequency: 2,
|
||||
frequencyDefault: 2,
|
||||
allowed() {
|
||||
return tech.isNeedles || tech.isNeedleShot
|
||||
},
|
||||
requires: "needle gun, needle-shot",
|
||||
effect() {
|
||||
tech.isNeedleIce = true
|
||||
},
|
||||
remove() {
|
||||
tech.isNeedleIce = false
|
||||
}
|
||||
},
|
||||
{
|
||||
name: "ceramics",
|
||||
description: `<strong>needles</strong> and <strong>harpoons</strong> pierce <strong>shields</strong><br>directly <strong class='color-d'>damaging</strong> shielded mobs`,
|
||||
@@ -5088,7 +5107,7 @@
|
||||
},
|
||||
{
|
||||
name: "surfactant",
|
||||
description: "gain <strong>3</strong> <strong class='color-bot'>foam-bots</strong> and <strong>upgrade</strong> bots to foam<br>remove your <strong>foam gun</strong>",
|
||||
description: "trade your <strong>foam gun</strong> for <strong>2</strong> <strong class='color-bot'>foam-bots</strong><br>and <strong>upgrade</strong> all bots to foam<br>",
|
||||
isGunTech: true,
|
||||
maxCount: 1,
|
||||
count: 0,
|
||||
@@ -5099,11 +5118,11 @@
|
||||
isNonRefundable: true,
|
||||
requires: "NOT EXPERIMENT MODE, foam gun",
|
||||
allowed() {
|
||||
return tech.haveGunCheck("foam", false) && !tech.isFoamBotUpgrade
|
||||
return tech.haveGunCheck("foam", false) && !b.hasBotUpgrade()
|
||||
},
|
||||
effect() {
|
||||
tech.giveTech("foam-bot upgrade")
|
||||
for (let i = 0; i < 3; i++) {
|
||||
for (let i = 0; i < 2; i++) {
|
||||
b.foamBot()
|
||||
tech.foamBotCount++;
|
||||
}
|
||||
@@ -6221,7 +6240,7 @@
|
||||
},
|
||||
{
|
||||
name: "no-cloning theorem",
|
||||
description: `<strong>42%</strong> chance to <strong class='color-dup'>duplicate</strong> spawned <strong>power ups</strong><br>after a <strong>mob</strong> <strong>dies</strong>, lose <strong>1%</strong> <strong class='color-dup'>duplication</strong> chance`,
|
||||
description: `<strong>38%</strong> chance to <strong class='color-dup'>duplicate</strong> spawned <strong>power ups</strong><br>after a <strong>mob</strong> <strong>dies</strong>, lose <strong>1%</strong> <strong class='color-dup'>duplication</strong> chance`,
|
||||
isFieldTech: true,
|
||||
maxCount: 1,
|
||||
count: 0,
|
||||
@@ -6232,9 +6251,9 @@
|
||||
},
|
||||
requires: "cloaking, wormhole or time dilation and below 100% duplication chance",
|
||||
effect() {
|
||||
tech.cloakDuplication = 0.42
|
||||
tech.cloakDuplication = 0.38
|
||||
powerUps.setDupChance(); //needed after adjusting duplication chance
|
||||
if (!build.isExperimentSelection) simulation.circleFlare(0.42);
|
||||
if (!build.isExperimentSelection) simulation.circleFlare(0.38);
|
||||
},
|
||||
remove() {
|
||||
tech.cloakDuplication = 0
|
||||
@@ -6243,7 +6262,7 @@
|
||||
},
|
||||
{
|
||||
name: "symbiosis",
|
||||
description: "after a <strong>mob</strong> <strong>dies</strong>, lose <strong>1</strong> max <strong class='color-h'>health</strong><br><strong>bosses</strong> spawn <strong>2</strong> extra <strong class='color-m'>tech</strong> after they <strong>die</strong>",
|
||||
description: "after a <strong>mob</strong> <strong>dies</strong>, lose <strong>1</strong> max <strong class='color-h'>health</strong><br><strong>bosses</strong> spawn <strong>1-2</strong> extra <strong class='color-m'>tech</strong> after they <strong>die</strong>",
|
||||
isFieldTech: true,
|
||||
maxCount: 1,
|
||||
count: 0,
|
||||
@@ -6770,6 +6789,25 @@
|
||||
// },
|
||||
// remove() {}
|
||||
// },
|
||||
{
|
||||
name: "negative friction",
|
||||
description: "when you touch walls you speed up instead of slowing down. It's actually pretty cool, seriously.",
|
||||
maxCount: 1,
|
||||
count: 0,
|
||||
frequency: 0,
|
||||
isExperimentHide: true,
|
||||
isJunk: true,
|
||||
allowed() {
|
||||
return true
|
||||
},
|
||||
requires: "",
|
||||
effect() {
|
||||
player.friction = -0.5
|
||||
},
|
||||
remove() {
|
||||
if (this.count) player.friction = 0.002
|
||||
}
|
||||
},
|
||||
{
|
||||
name: "bounce",
|
||||
description: "you bounce off things. It's annoying, but not that bad.",
|
||||
|
||||
Reference in New Issue
Block a user