stun and burn balance

This commit is contained in:
landgreen
2020-03-09 06:05:41 -07:00
parent 99f36288a9
commit 014ffdab8f
6 changed files with 97 additions and 65 deletions

View File

@@ -89,7 +89,7 @@ const b = {
},
{
name: "fluoroantimonic acid",
description: "each <strong>bullet</strong> does instant <strong class='color-d'>damage</strong><br><strong>active</strong> when you are above <strong>80%</strong> base health",
description: "each <strong>bullet</strong> does instant <strong class='color-p'>acid</strong> <strong class='color-d'>damage</strong><br><strong>active</strong> when you are above <strong>80%</strong> base health",
maxCount: 1,
count: 0,
allowed() {
@@ -1459,7 +1459,7 @@ const b = {
mob[i].force.y += knock.y;
radius *= 0.93 //reduced range for each additional explosion target
damageScale *= 0.8 //reduced damage for each additional explosion target
// mobs.statusBlind(mob[i])
mobs.statusStun(mob[i])
// if (isBurn) mobs.statusBurn(mob[i], 0.4) // (2.2) * 1.3 * 30/180 // 6 ticks (3 seconds)
} else if (!mob[i].seePlayer.recall && dist < alertRange) {
mob[i].locatePlayer();
@@ -1720,7 +1720,7 @@ const b = {
friction: 0,
frictionAir: 0.025,
thrust: b.isModFastSpores ? 0.0008 : 0.0004,
dmg: 0, //2.2, //damage done in addition to the damage from momentum
dmg: 2.2, //damage done in addition to the damage from momentum
classType: "bullet",
collisionFilter: {
category: cat.bullet,
@@ -1728,8 +1728,8 @@ const b = {
},
endCycle: game.cycle + Math.floor((660 + Math.floor(Math.random() * 240)) * b.isModBulletsLastLonger),
minDmgSpeed: 0,
onDmg(who) {
mobs.statusPoison(who, 0.5, 180) // (2.2) * 1.3 * 30/180 // 6 ticks (3 seconds)
onDmg() {
// mobs.statusPoison(who, 0.5, 180) // (2.2) * 1.3 * 30/180 // 6 ticks (3 seconds)
this.endCycle = 0; //bullet ends cycle after doing damage
},
onEnd() {},
@@ -2104,8 +2104,6 @@ const b = {
isEasyToAim: false,
fire() {
const me = bullet.length;
b.muzzleFlash(15);
// if (Math.random() > 0.2) mobs.alert(500);
const dir = mech.angle + (Math.random() - 0.5) * ((mech.crouch) ? 0.03 : 0.1);
bullet[me] = Bodies.rectangle(mech.pos.x + 30 * Math.cos(mech.angle), mech.pos.y + 30 * Math.sin(mech.angle), 20 * b.modBulletSize, 6 * b.modBulletSize, b.fireAttributes(dir));
b.fireProps(mech.crouch ? 8 : 4, mech.crouch ? 52 : 38, dir, me); //cd , speed
@@ -2114,8 +2112,15 @@ const b = {
bullet[me].frictionAir = mech.crouch ? 0.007 : 0.01;
if (b.isModIceCrystals) {
bullet[me].onDmg = function (who) {
if (!who.shield) mobs.statusSlow(who, 60)
mobs.statusSlow(who, 60)
};
//ice muzzleFlash
ctx.fillStyle = "rgb(0,100,255)";
ctx.beginPath();
ctx.arc(mech.pos.x + 35 * Math.cos(mech.angle), mech.pos.y + 35 * Math.sin(mech.angle), 15, 0, 2 * Math.PI);
ctx.fill();
} else {
b.muzzleFlash(15);
}
bullet[me].do = function () {
this.force.y += this.mass * 0.0005;
@@ -2163,7 +2168,7 @@ const b = {
name: "super balls", //2
description: "fire <strong>four</strong> balls in a wide arc<br>balls <strong>bounce</strong> with no momentum loss",
ammo: 0,
ammoPack: 10,
ammoPack: 12,
have: false,
num: 5,
isStarterGun: true,
@@ -2198,10 +2203,10 @@ const b = {
},
{
name: "fléchettes", //3
description: "fire a <strong>precise</strong> volley of <strong>high velocity</strong> needles<br>needles deliver <strong class='color-p'>chemical</strong> damage over 3 seconds",
description: "fire a <strong>precise</strong> volley of <strong>high velocity</strong> needles<br>needles deliver <strong class='color-p'>chemical</strong> <strong class='color-d'>damage</strong> over 3 seconds",
ammo: 0,
ammoPack: 22,
defaultAmmoPack: 22,
ammoPack: 23,
defaultAmmoPack: 23,
have: false,
isStarterGun: true,
isEasyToAim: false,
@@ -2222,14 +2227,16 @@ const b = {
function makeFlechette(angle = mech.angle) {
const me = bullet.length;
bullet[me] = Bodies.rectangle(mech.pos.x + 40 * Math.cos(mech.angle), mech.pos.y + 40 * Math.sin(mech.angle), 45 * b.modBulletSize, 1.4 * b.modBulletSize, b.fireAttributes(angle));
Matter.Body.setDensity(bullet[me], 0.0001); //0.001 is normal
// Matter.Body.setDensity(bullet[me], 0.0001); //0.001 is normal
bullet[me].endCycle = game.cycle + 180;
bullet[me].dmg = 0;
bullet[me].onDmg = function (who) {
if (b.isModDotFlechette) {
mobs.statusPoison(who, 0.38, 360) // (2.3) * 2 / 14 ticks (2x damage over 7 seconds)
} else {
mobs.statusPoison(who, 0.38, 180) // (2.3) / 6 ticks (3 seconds)
if (!who.isShielded) {
if (b.isModDotFlechette) {
mobs.statusPoison(who, 0.33, 360) // (2.3) * 2 / 14 ticks (2x damage over 7 seconds)
} else {
mobs.statusPoison(who, 0.33, 180) // (2.3) / 6 ticks (3 seconds)
}
}
};
@@ -2590,7 +2597,7 @@ const b = {
},
{
name: "spores", //10
description: "fire <strong>sporangiums</strong> that discharge <strong class='color-p' style='letter-spacing: 2px;'>spores</strong><br><strong class='color-p' style='letter-spacing: 2px;'>spores</strong> do <strong class='color-d'>damage</strong> over <strong>3</strong> seconds",
description: "fire a <strong>sporangium</strong> that discharges <strong class='color-p' style='letter-spacing: 2px;'>spores</strong>",
ammo: 0,
ammoPack: (game.difficultyMode > 3) ? 3 : 4,
have: false,