community level run
new community level "run" (by iSuggestedThatAlready / iNoobBoi)!!!!!! try it out by enabling community levels in the settings more training levels: "trainingNailGun", "trainingShotGun", "trainingSuperBall", "trainingMatterWave", "trainingMissile" no power ups check box in experiment mode now disables all types of power ups, not just tech simulation.isNoPowerUps powerUps can no longer move through doors this might lead to problems that I haven't thought about, but let's see adiabatic healing now updates active heal power ups as well as future ones fixed bug with undefined tech not showing up
This commit is contained in:
86
js/bullet.js
86
js/bullet.js
@@ -5391,49 +5391,6 @@ const b = {
|
||||
angle += SPREAD
|
||||
}
|
||||
},
|
||||
}, {
|
||||
name: "mine",
|
||||
description: "toss a <strong>proximity</strong> mine that <strong>sticks</strong> to walls<br>refund <strong>undetonated</strong> mines on <strong>exiting</strong> a level", //fires <strong>nails</strong> at mobs within range
|
||||
ammo: 0,
|
||||
ammoPack: 1.25,
|
||||
have: false,
|
||||
do() {
|
||||
if (!input.field && input.down && !tech.isLaserMine) {
|
||||
const cycles = 60 //30
|
||||
const speed = 40
|
||||
const v = { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) } //m.Vy / 2 + removed to make the path less jerky
|
||||
ctx.strokeStyle = "rgba(68, 68, 68, 0.2)" //color.map
|
||||
ctx.lineWidth = 2
|
||||
ctx.beginPath()
|
||||
for (let i = 1.5, len = 19; i < len + 1; i++) {
|
||||
const time = cycles * i / len
|
||||
ctx.lineTo(m.pos.x + time * v.x, m.pos.y + time * v.y + 0.34 * time * time)
|
||||
}
|
||||
ctx.stroke()
|
||||
}
|
||||
},
|
||||
fire() {
|
||||
if (input.down) {
|
||||
if (tech.isLaserMine) {
|
||||
const speed = 30
|
||||
const velocity = { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) }
|
||||
b.laserMine(m.pos, velocity)
|
||||
m.fireCDcycle = m.cycle + Math.floor(65 * b.fireCDscale); // cool down
|
||||
} else {
|
||||
const pos = { x: m.pos.x + 30 * Math.cos(m.angle), y: m.pos.y + 30 * Math.sin(m.angle) }
|
||||
let speed = 36
|
||||
if (Matter.Query.point(map, pos).length > 0) speed = -2 //don't launch if mine will spawn inside map
|
||||
b.mine(pos, { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) }, 0)
|
||||
m.fireCDcycle = m.cycle + Math.floor(55 * b.fireCDscale); // cool down
|
||||
}
|
||||
} else {
|
||||
const pos = { x: m.pos.x + 30 * Math.cos(m.angle), y: m.pos.y + 30 * Math.sin(m.angle) }
|
||||
let speed = 23
|
||||
if (Matter.Query.point(map, pos).length > 0) speed = -2 //don't launch if mine will spawn inside map
|
||||
b.mine(pos, { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) }, 0)
|
||||
m.fireCDcycle = m.cycle + Math.floor(35 * b.fireCDscale); // cool down
|
||||
}
|
||||
}
|
||||
}, {
|
||||
name: "spores",
|
||||
description: "fire a <strong class='color-p' style='letter-spacing: 2px;'>sporangium</strong> that discharges <strong class='color-p' style='letter-spacing: 2px;'>spores</strong><br><strong class='color-p' style='letter-spacing: 2px;'>spores</strong> seek out nearby mobs",
|
||||
@@ -5981,6 +5938,49 @@ const b = {
|
||||
player.force.y -= recoil.y
|
||||
tech.harpoonDensity = 0.008
|
||||
}
|
||||
}, {
|
||||
name: "mine",
|
||||
description: "toss a <strong>proximity</strong> mine that <strong>sticks</strong> to walls<br>refund <strong>undetonated</strong> mines on <strong>exiting</strong> a level", //fires <strong>nails</strong> at mobs within range
|
||||
ammo: 0,
|
||||
ammoPack: 1.25,
|
||||
have: false,
|
||||
do() {
|
||||
if (!input.field && input.down && !tech.isLaserMine) {
|
||||
const cycles = 60 //30
|
||||
const speed = 40
|
||||
const v = { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) } //m.Vy / 2 + removed to make the path less jerky
|
||||
ctx.strokeStyle = "rgba(68, 68, 68, 0.2)" //color.map
|
||||
ctx.lineWidth = 2
|
||||
ctx.beginPath()
|
||||
for (let i = 1.5, len = 19; i < len + 1; i++) {
|
||||
const time = cycles * i / len
|
||||
ctx.lineTo(m.pos.x + time * v.x, m.pos.y + time * v.y + 0.34 * time * time)
|
||||
}
|
||||
ctx.stroke()
|
||||
}
|
||||
},
|
||||
fire() {
|
||||
if (input.down) {
|
||||
if (tech.isLaserMine) {
|
||||
const speed = 30
|
||||
const velocity = { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) }
|
||||
b.laserMine(m.pos, velocity)
|
||||
m.fireCDcycle = m.cycle + Math.floor(65 * b.fireCDscale); // cool down
|
||||
} else {
|
||||
const pos = { x: m.pos.x + 30 * Math.cos(m.angle), y: m.pos.y + 30 * Math.sin(m.angle) }
|
||||
let speed = 36
|
||||
if (Matter.Query.point(map, pos).length > 0) speed = -2 //don't launch if mine will spawn inside map
|
||||
b.mine(pos, { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) }, 0)
|
||||
m.fireCDcycle = m.cycle + Math.floor(55 * b.fireCDscale); // cool down
|
||||
}
|
||||
} else {
|
||||
const pos = { x: m.pos.x + 30 * Math.cos(m.angle), y: m.pos.y + 30 * Math.sin(m.angle) }
|
||||
let speed = 23
|
||||
if (Matter.Query.point(map, pos).length > 0) speed = -2 //don't launch if mine will spawn inside map
|
||||
b.mine(pos, { x: speed * Math.cos(m.angle), y: speed * Math.sin(m.angle) }, 0)
|
||||
m.fireCDcycle = m.cycle + Math.floor(35 * b.fireCDscale); // cool down
|
||||
}
|
||||
}
|
||||
},
|
||||
// {
|
||||
// name: "railgun",
|
||||
|
||||
1096
js/level.js
1096
js/level.js
File diff suppressed because it is too large
Load Diff
@@ -667,6 +667,7 @@ const mobs = {
|
||||
y: this.position.y + seeRange * Math.sin(this.angle)
|
||||
};
|
||||
vertexCollision(this.position, look, map);
|
||||
vertexCollision(this.position, look, body);
|
||||
if (best.dist2 != Infinity) {
|
||||
this.springTarget.x = best.x;
|
||||
this.springTarget.y = best.y;
|
||||
|
||||
@@ -1103,7 +1103,7 @@ const powerUps = {
|
||||
if (
|
||||
(!tech.isSuperDeterminism || (target !== 'research')) &&
|
||||
!(tech.isEnergyNoAmmo && target === 'ammo') &&
|
||||
(!simulation.isNoPowerUps || (target === 'research' || target === 'heal' || target === 'ammo'))
|
||||
(!simulation.isNoPowerUps)
|
||||
) {
|
||||
powerUps.directSpawn(x, y, target, moving, mode, size)
|
||||
if (Math.random() < tech.duplicationChance()) {
|
||||
|
||||
@@ -1443,6 +1443,7 @@ const spawn = {
|
||||
me.delay = 120 * simulation.CDScale;
|
||||
me.randomHopFrequency = 200 + Math.floor(Math.random() * 150);
|
||||
me.randomHopCD = simulation.cycle + me.randomHopFrequency;
|
||||
Matter.Body.rotate(me, Math.random() * Math.PI);
|
||||
spawn.shield(me, x, y);
|
||||
me.do = function() {
|
||||
this.gravity();
|
||||
|
||||
10
js/tech.js
10
js/tech.js
@@ -16,7 +16,7 @@ const tech = {
|
||||
//remove lore if it's your first time playing since it's confusing
|
||||
//also remove lore if cheating
|
||||
lore.techCount = 0;
|
||||
if (simulation.isCheating || localSettings.runCount > 1) { //simulation.isCommunityMaps ||
|
||||
if (simulation.isCheating || localSettings.runCount < 1) { //simulation.isCommunityMaps ||
|
||||
for (let i = 0, len = tech.tech.length; i < len; i++) {
|
||||
if (tech.tech[i].isLore) {
|
||||
tech.tech[i].frequency = 0;
|
||||
@@ -228,7 +228,7 @@ const tech = {
|
||||
if (tech.isEnergyLoss) dmg *= 1.55;
|
||||
if (tech.isAcidDmg && m.health > 1) dmg *= 1.35;
|
||||
if (tech.restDamage > 1 && player.speed < 1) dmg *= tech.restDamage
|
||||
if (tech.isEnergyDamage) dmg *= 1 + m.energy * 0.1;
|
||||
if (tech.isEnergyDamage) dmg *= 1 + m.energy * 0.11;
|
||||
if (tech.isDamageFromBulletCount) dmg *= 1 + bullet.length * 0.007
|
||||
if (tech.isRerollDamage) dmg *= 1 + 0.037 * powerUps.research.count
|
||||
if (tech.isOneGun && b.inventory.length < 2) dmg *= 1.25
|
||||
@@ -2225,7 +2225,7 @@ const tech = {
|
||||
},
|
||||
{
|
||||
name: "electronegativity",
|
||||
description: "increase <strong class='color-d'>damage</strong> by <strong>1%</strong><br>for every <strong>10</strong> stored <strong class='color-f'>energy</strong>",
|
||||
description: "increase <strong class='color-d'>damage</strong> by <strong>1%</strong><br>for every <strong>9</strong> stored <strong class='color-f'>energy</strong>",
|
||||
maxCount: 1,
|
||||
count: 0,
|
||||
frequency: 1,
|
||||
@@ -2617,6 +2617,10 @@ const tech = {
|
||||
effect() {
|
||||
tech.largerHeals++;
|
||||
this.refundAmount += tech.addJunkTechToPool(0.05)
|
||||
//update current heals
|
||||
for (let i = 0; i < powerUp.length; i++) {
|
||||
if (powerUp[i].name === "heal") powerUp[i].size = powerUps.heal.size()
|
||||
}
|
||||
},
|
||||
refundAmount: 0,
|
||||
remove() {
|
||||
|
||||
Reference in New Issue
Block a user