wave bullets end after damage

wave beam bullets now end after hitting mobs
  bullets do more damage, and reduce mob velocity a bit
  more ammo, more fire delay

most wave beam tech has been buffed a bit also
This commit is contained in:
landgreen
2021-05-11 18:10:38 -07:00
parent 0019143124
commit c00199daa7
5 changed files with 53 additions and 54 deletions

View File

@@ -3177,7 +3177,7 @@ const b = {
// **************************************************************************************************
guns: [{
name: "nail gun",
description: "use compressed air to fire a stream of <strong>nails</strong><br><strong>delay</strong> after firing <strong>decreases</strong> as you shoot",
description: "use compressed air to fire a stream of <strong>nails</strong><br><strong><em>delay</em></strong> after firing <strong>decreases</strong> as you shoot",
ammo: 0,
ammoPack: 45,
defaultAmmoPack: 45,
@@ -3608,12 +3608,12 @@ const b = {
}
}, {
name: "wave beam",
description: "emit a <strong>wave packet</strong> of <strong>oscillating</strong> particles<br>that propagate through <strong>solids</strong>",
description: "emit a <strong>wave packet</strong> of oscillating particles<br>that propagates through <strong>solids</strong>",
ammo: 0,
ammoPack: 80,
ammoPack: 100,
have: false,
wavePacketCycle: 0,
delay: 40,
delay: 60,
do() {
if (this.wavePacketCycle && !input.fire) {
this.wavePacketCycle = 0;
@@ -3659,18 +3659,19 @@ const b = {
}
q = Matter.Query.point(mob, this.position) // check if inside a mob
for (let i = 0; i < q.length; i++) {
let dmg = this.dmg / Math.min(10, q[i].mass)
let dmg = this.dmg // / Math.min(10, q[i].mass)
q[i].damage(dmg);
q[i].foundPlayer();
Matter.Body.setVelocity(q[i], Vector.mult(q[i].velocity, 0.9))
//this draw circle had to be remove to reduce lag
// simulation.drawList.push({ //add dmg to draw queue
// x: this.position.x,
// y: this.position.y,
// radius: Math.log(2 * dmg + 1.1) * 40,
// color: 'rgba(0,0,0,0.4)',
// time: simulation.drawTime
// });
this.endCycle = 0; //bullet ends cycle after doing damage
simulation.drawList.push({ //add dmg to draw queue
x: this.position.x,
y: this.position.y,
radius: Math.log(2 * dmg + 1.1) * 40,
color: 'rgba(0,0,0,0.4)',
time: simulation.drawTime
});
}
},
wiggle() {

View File

@@ -16,7 +16,7 @@ const level = {
// simulation.zoomScale = 1000;
// simulation.setZoom();
// m.setField("metamaterial cloaking")
b.giveGuns("wave beam")
// b.giveGuns("wave beam")
// b.giveGuns("laser")
// tech.isExplodeRadio = true
// tech.giveTech("pulse")
@@ -25,7 +25,7 @@ const level = {
// for (let i = 0; i < 3; i++) tech.giveTech("propagation")
// for (let i = 0; i < 3; i++) tech.giveTech("bound state")
// for (let i = 0; i < 9; i++) tech.giveTech("slow light")
tech.giveTech("metastability")
// tech.giveTech("metastability")
level.intro(); //starting level
// level.testing(); //not in rotation

View File

@@ -1738,7 +1738,7 @@
frequency: 4,
frequencyDefault: 4,
allowed() {
return tech.isFlipFlopEnergy || tech.isFlipFlopDamage || tech.isFlipFlopHarm
return tech.isFlipFlopEnergy || tech.isFlipFlopDamage || tech.isFlipFlopHarm || tech.relayIce
},
requires: "2 ON/OFF techs",
effect() {
@@ -1965,9 +1965,9 @@
count: 0,
frequency: 2,
allowed() {
return (tech.iceEnergy || tech.isWormholeEnergy || tech.isPiezo || tech.isRailEnergyGain) && tech.energyRegen !== 0.004 && !tech.isEnergyHealth
return (tech.iceEnergy || tech.isWormholeEnergy || tech.isPiezo || tech.isRailEnergyGain || tech.energySiphon || tech.isEnergyRecovery || tech.dynamoBotCount || tech.isFlipFlopEnergy) && tech.energyRegen !== 0.004 && !tech.isEnergyHealth
},
requires: "piezoelectricity, Penrose, half-wave, or thermoelectric, but not time crystals",
requires: "a way to regen extra energy, but not time crystals",
effect: () => {
tech.energyRegen = 0;
m.fieldRegen = tech.energyRegen;
@@ -2012,7 +2012,7 @@
description: "each <strong class='color-h'>heal</strong> <strong>power up</strong> you collect<br>increases your <strong>maximum</strong> <strong class='color-f'>energy</strong> by <strong>5</strong>",
maxCount: 1,
count: 0,
frequency: 2,
frequency: 3,
allowed() {
return tech.isEnergyHealth && !tech.isNoHeals
},
@@ -3686,25 +3686,7 @@
},
{
name: "bound state",
description: "instead of dissipating normally<br>wave packets <strong>reflect</strong> backwards <strong>1</strong> times",
isGunTech: true,
maxCount: 9,
count: 0,
frequency: 2,
allowed() {
return tech.haveGunCheck("wave beam")
},
requires: "wave beam",
effect() {
tech.waveReflections++
},
remove() {
tech.waveReflections = 1
}
},
{
name: "packet length",
description: "wave packet <strong>length</strong> and <strong>duration</strong><br>is increased by <strong>40%</strong>", // description: "holding fire allows the <strong>wave beam</strong> to emits a second <strong>packet</strong><br>at zero ammo cost",
description: "instead of dissipating normally<br>wave packets <strong>reflect</strong> backwards <strong>2</strong> times",
isGunTech: true,
maxCount: 3,
count: 0,
@@ -3714,7 +3696,25 @@
},
requires: "wave beam",
effect() {
const scale = 1.4 - 0.025 * this.count
tech.waveReflections += 2
},
remove() {
tech.waveReflections = 1
}
},
{
name: "packet length",
description: "wave packet <strong>length</strong> and <strong>duration</strong><br>is increased by <strong>50%</strong>", // description: "holding fire allows the <strong>wave beam</strong> to emits a second <strong>packet</strong><br>at zero ammo cost",
isGunTech: true,
maxCount: 3,
count: 0,
frequency: 2,
allowed() {
return tech.haveGunCheck("wave beam")
},
requires: "wave beam",
effect() {
const scale = 1.5 - 0.025 * this.count
tech.wavePacketLength *= scale
tech.wavePacketFrequency /= scale
tech.waveLengthRange *= Math.sqrt(scale)
@@ -3727,7 +3727,7 @@
},
{
name: "amplitude",
description: "wave packet <strong>amplitude</strong> is <strong>33%</strong> higher<br>wave <strong class='color-d'>damage</strong> is increased by <strong>33%</strong>",
description: "wave packet <strong>amplitude</strong> is <strong>33%</strong> higher<br>wave <strong class='color-d'>damage</strong> is increased by <strong>50%</strong>",
isGunTech: true,
maxCount: 3,
count: 0,
@@ -3747,7 +3747,7 @@
},
{
name: "propagation",
description: "wave packet propagation <strong>speed</strong> is <strong>30%</strong> slower<br>wave <strong class='color-d'>damage</strong> is increased by <strong>50%</strong>",
description: "wave packet propagation <strong>speed</strong> is <strong>25%</strong> slower<br>wave <strong class='color-d'>damage</strong> is increased by <strong>50%</strong>",
isGunTech: true,
maxCount: 9,
count: 0,
@@ -3757,7 +3757,7 @@
},
requires: "wave beam",
effect() {
tech.waveBeamSpeed *= 0.7;
tech.waveBeamSpeed *= 0.75;
tech.waveBeamDamage += 1.3 * 0.5
},
remove() {
@@ -6025,7 +6025,7 @@
},
{
name: "diegesis",
description: "indicate gun fire delay<br>through a rotation of your head",
description: "indicate gun fire <strong><em>delay</em></strong><br>through a rotation of your head",
maxCount: 1,
count: 0,
frequency: 0,