laser pulse balance
This commit is contained in:
@@ -191,18 +191,18 @@ const b = {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "overcharge",
|
name: "overcharge",
|
||||||
description: "charge <strong class='color-f'>energy</strong> <strong>25%</strong> beyond your <strong>maximum</strong>",
|
description: "charge <strong class='color-f'>energy</strong> <strong>33%</strong> beyond your <strong>maximum</strong>",
|
||||||
have: false, //16
|
have: false, //16
|
||||||
effect: () => {
|
effect: () => {
|
||||||
mech.fieldEnergyMax = 1.25
|
mech.fieldEnergyMax = 1.33
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "supersaturation",
|
name: "supersaturation",
|
||||||
description: "<strong class='color-h'>heal</strong> <strong>25%</strong> beyond your <strong>max health</strong>",
|
description: "<strong class='color-h'>heal</strong> <strong>33%</strong> beyond your <strong>max health</strong>",
|
||||||
have: false, //17
|
have: false, //17
|
||||||
effect: () => {
|
effect: () => {
|
||||||
mech.maxHealth = 1.25
|
mech.maxHealth = 1.33
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -215,7 +215,7 @@ const b = {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "mass-energy equivalence",
|
name: "mass-energy equivalence",
|
||||||
description: "convert the mass of <strong>power ups</strong> into <strong class='color-f'>energy</strong><br>power ups fill your <strong class='color-f'>energy</strong> and <strong class='color-h'>heal</strong> for +3%",
|
description: "convert the mass of <strong>power ups</strong> into <strong class='color-f'>energy</strong><br>power ups fill your <strong class='color-f'>energy</strong> and <strong class='color-h'>heal</strong> for +5%",
|
||||||
have: false, //19
|
have: false, //19
|
||||||
effect: () => {
|
effect: () => {
|
||||||
b.isModMassEnergy = true // used in mech.usePowerUp
|
b.isModMassEnergy = true // used in mech.usePowerUp
|
||||||
@@ -1830,12 +1830,11 @@ const b = {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "pulse", //15
|
name: "pulse", //15
|
||||||
description: "emit a pulse of collimation coherent light<br>use <strong class='color-f'>energy</strong> to induce an <strong class='color-e'>explosion</strong>",
|
description: "emit an <strong class='color-e'>explosive</strong> laser pulse<br>each pulse uses 20% of your <strong class='color-f'>energy</strong>",
|
||||||
ammo: 0,
|
ammo: 0,
|
||||||
ammoPack: Infinity,
|
ammoPack: Infinity,
|
||||||
have: false,
|
have: false,
|
||||||
isStarterGun: true,
|
isStarterGun: true,
|
||||||
count: 0,
|
|
||||||
fire() {
|
fire() {
|
||||||
//calculate laser collision
|
//calculate laser collision
|
||||||
let best;
|
let best;
|
||||||
@@ -1910,28 +1909,24 @@ const b = {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
//draw blowtorch laser beam
|
//draw laser beam
|
||||||
ctx.strokeStyle = "rgba(255,0,0,0.15)"
|
ctx.strokeStyle = "rgba(255,0,0,0.2)"
|
||||||
ctx.lineWidth = 16
|
ctx.lineWidth = 25
|
||||||
ctx.beginPath();
|
ctx.beginPath();
|
||||||
ctx.moveTo(path[0].x, path[0].y);
|
ctx.moveTo(path[0].x, path[0].y);
|
||||||
ctx.lineTo(path[1].x, path[1].y);
|
ctx.lineTo(path[1].x, path[1].y);
|
||||||
ctx.stroke();
|
ctx.stroke();
|
||||||
ctx.strokeStyle = "#f00";
|
ctx.strokeStyle = "#f00";
|
||||||
ctx.lineWidth = 2.5
|
ctx.lineWidth = 4
|
||||||
ctx.beginPath();
|
ctx.beginPath();
|
||||||
ctx.moveTo(path[0].x, path[0].y);
|
ctx.moveTo(path[0].x, path[0].y);
|
||||||
ctx.lineTo(path[1].x, path[1].y);
|
ctx.lineTo(path[1].x, path[1].y);
|
||||||
ctx.stroke();
|
ctx.stroke();
|
||||||
|
|
||||||
this.count++
|
const energy = mech.fieldMeter * 0.2
|
||||||
if (this.count > 2) {
|
mech.fieldMeter -= energy
|
||||||
this.count = 0;
|
if (best.who) b.explosion(path[1], 1300 * energy)
|
||||||
mech.fireCDcycle = mech.cycle + Math.floor(30 * b.modFireRate); // cool down
|
mech.fireCDcycle = mech.cycle + Math.floor(20 * b.modFireRate); // cool down
|
||||||
const energy = Math.min(0.2, mech.fieldMeter * 0.3)
|
|
||||||
if (best.who) b.explosion(path[1], 1300 * energy)
|
|
||||||
mech.fieldMeter -= energy
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ const level = {
|
|||||||
start() {
|
start() {
|
||||||
if (level.levelsCleared === 0) {
|
if (level.levelsCleared === 0) {
|
||||||
// game.difficulty = 6; //for testing to simulate possible mobs spawns
|
// game.difficulty = 6; //for testing to simulate possible mobs spawns
|
||||||
b.giveGuns(15)
|
// b.giveGuns(15)
|
||||||
// mech.fieldUpgrades[2].effect();
|
// mech.fieldUpgrades[2].effect();
|
||||||
// b.giveMod(21)
|
// b.giveMod(21)
|
||||||
|
|
||||||
|
|||||||
@@ -522,7 +522,7 @@ const mech = {
|
|||||||
powerUp.splice(i, 1);
|
powerUp.splice(i, 1);
|
||||||
if (b.isModMassEnergy) {
|
if (b.isModMassEnergy) {
|
||||||
mech.fieldMeter = mech.fieldEnergyMax;
|
mech.fieldMeter = mech.fieldEnergyMax;
|
||||||
mech.addHealth(0.03);
|
mech.addHealth(0.05);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
drawLeg(stroke) {
|
drawLeg(stroke) {
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ const powerUps = {
|
|||||||
target = b.guns[Math.floor(Math.random() * b.guns.length)];
|
target = b.guns[Math.floor(Math.random() * b.guns.length)];
|
||||||
}
|
}
|
||||||
if (target.ammo === Infinity) {
|
if (target.ammo === Infinity) {
|
||||||
mech.fieldMeter = 1;
|
mech.fieldMeter = mech.fieldEnergyMax;
|
||||||
if (!game.lastLogTime) game.makeTextLog("<span style='font-size:115%;'><span class='color-f'>+energy</span></span>", 300);
|
if (!game.lastLogTime) game.makeTextLog("<span style='font-size:115%;'><span class='color-f'>+energy</span></span>", 300);
|
||||||
} else {
|
} else {
|
||||||
//ammo given scales as mobs take more hits to kill
|
//ammo given scales as mobs take more hits to kill
|
||||||
|
|||||||
Reference in New Issue
Block a user