finalBoss has a bit less health

laser lens has a glow effect
slow light has 11->7 unique beams
  slow light has 38% more damage per beam
infrared diode 50->60% energy efficiency
dye laser 20->25% energy efficiency
          20->25% laser damage
free-electron laser 190->200% laser damage
crit angle is smaller for iridescence and stress concentration on large mobs
ordnance has +5% JUNK
CPT uses 25% less energy and leaves you with about 10-20 energy

JUNK tech: placebo -  +777% damage +777% defense

bug fixes
This commit is contained in:
landgreen
2022-10-15 08:16:01 -07:00
parent 3c860797b3
commit d996c4f2a2
8 changed files with 306 additions and 139 deletions

View File

@@ -28,19 +28,20 @@ const level = {
// m.setField("standing wave") //molecular assembler standing wave time dilation perfect diamagnetism metamaterial cloaking wormhole negative mass pilot wave
// simulation.molecularMode = 2
// m.damage(0.1);
// b.giveGuns("nail gun") //0 nail gun 1 shotgun 2 super balls 3 wave 4 missiles 5 grenades 6 spores 7 drones 8 foam 9 harpoon 10 mine 11 laser
// b.giveGuns("laser") //0 nail gun 1 shotgun 2 super balls 3 wave 4 missiles 5 grenades 6 spores 7 drones 8 foam 9 harpoon 10 mine 11 laser
// b.guns[0].ammo = 10000
// for (let i = 0; i < 1; ++i) tech.giveTech("needle gun")
// tech.giveTech("pressure vessel")
// tech.giveTech("quintessence")
// for (let i = 0; i < 1; ++i) tech.giveTech("freezer burn")
// for (let i = 0; i < 1; i++) tech.giveTech("reaction inhibitor")
// tech.giveTech("lens")
// for (let i = 0; i < 9; ++i) tech.giveTech("compound lens")
// tech.giveTech("dye laser")
// for (let i = 0; i < 1; ++i) tech.giveTech("iridescence")
// for (let i = 0; i < 1; i++) tech.giveTech("slow light")
// for (let i = 0; i < 10; i++) powerUps.directSpawn(450, -50, "tech");
// for (let i = 0; i < 10; i++) powerUps.directSpawn(1750, -500, "boost");
// for (let i = 0; i < 10; i++) powerUps.directSpawn(1750, -500, "coupling");
// level.final();
// level.testing();
// spawn.starter(1900, -500, 200)
// spawn.starter(1900, -500)
// spawn.timeBoss(2538, -950)
// for (let i = 0; i < 33; ++i) spawn.sniper(1000 + 5000 * Math.random(), -500 + 300 * Math.random())
@@ -1088,7 +1089,7 @@ const level = {
if (!m.isBodiesAsleep) {
if (this.isClosing) {
if (this.position.y < y) { //try to close
if (
if ( //if clear of stuff
Matter.Query.collides(this, [player]).length === 0 &&
Matter.Query.collides(this, body).length < 2 &&
Matter.Query.collides(this, mob).length === 0
@@ -1100,6 +1101,25 @@ const level = {
Matter.Body.setPosition(this, position)
}
}
// else {
// const blocks = Matter.Query.collides(this, body)
// console.log(blocks.length)
// for (let i = 0; i < blocks.length; i++) {
// // console.log(blocks[i])
// if (blocks[i].bodyA) {
// if (touching[i].bodyB !== m.holdingTarget) {
// for (let j = 0, len = body.length; j < len; j++) {
// if (body[j] === touching[i].bodyB) {
// body.splice(j, 1);
// len--
// Matter.Composite.remove(engine.world, touching[i].bodyB);
// break;
// }
// }
// }
// }
// }
// }
} else {
if (this.position.y > y - distance) { //try to open
const position = {
@@ -2955,6 +2975,12 @@ const level = {
if (!doorOut.isClosed() || !doorIn.isClosed()) {
doorIn.isClosing = true
doorOut.isClosing = true
//block caught in a door
if (Matter.Query.collides(doorOut, body).length > 1 || Matter.Query.collides(doorIn, body).length > 1) {
button.isUp = true
doorIn.isClosing = false
doorOut.isClosing = false
}
} else {
isSpawnedBoss = true
isDoorsLocked = true
@@ -3039,6 +3065,12 @@ const level = {
if (!doorOut.isClosed() || !doorIn.isClosed()) {
doorIn.isClosing = true
doorOut.isClosing = true
//block caught in a door
if (Matter.Query.collides(doorOut, body).length > 1 || Matter.Query.collides(doorIn, body).length > 1) {
button.isUp = true
doorIn.isClosing = false
doorOut.isClosing = false
}
} else {
isSpawnedBoss = true
isDoorsLocked = true