- // ${game.SVGleftMouse} fire gun
- // ${game.SVGrightMouse} use field
- //
+ `;
+
let countGuns = 0
let countMods = 0
for (let i = 0, len = b.guns.length; i < len; i++) {
@@ -212,10 +206,10 @@ const build = {
+
+ share
+
+
starting level:
diff --git a/js/level.js b/js/level.js
index 7c2f692..6d930b4 100644
--- a/js/level.js
+++ b/js/level.js
@@ -147,7 +147,7 @@ const level = {
spawn.mapRect(level.exit.x, level.exit.y + 20, 100, 100); //exit bump
// spawn.laserBoss(2900, -500)
- spawn.springer(3200, -500)
+ spawn.beamer(1200, -500)
// spawn.timeSkipBoss(2900, -500)
// spawn.randomMob(3200, -500)
@@ -701,7 +701,7 @@ const level = {
//spawn.mapRect(-700, 0, 6250, 100); //ground
spawn.mapRect(3400, 0, 2150, 100); //ground
- spawn.mapRect(-700, -2000, 2100, 50); //Top left ledge
+ spawn.mapRect(-700, -2000, 2110, 50); //Top left ledge
spawn.bodyRect(1300, -2125, 50, 125, 0.8);
spawn.bodyRect(1307, -2225, 50, 100, 0.8);
spawn.mapRect(-700, -2350, 50, 400); //far left starting left wall
@@ -715,6 +715,7 @@ const level = {
spawn.mapRect(1850, -2000, 650, 50);
spawn.bodyRect(200, -2150, 200, 220, 0.8);
spawn.mapRect(700, -2275, 600, 50);
+ spawn.mapRect(1000, -1350, 410, 50);
spawn.bodyRect(1050, -2350, 30, 30, 0.8);
// spawn.boost(1800, -1000, 1200);
spawn.bodyRect(1625, -1100, 100, 75);
@@ -938,7 +939,7 @@ const level = {
spawn.randomBoss(4000, -350, 0.6);
spawn.randomBoss(2750, -550, 0.1);
if (game.difficulty > 2) {
- if (Math.random() < 0.3) { // tether ball
+ if (Math.random() < 0.1) { // tether ball
spawn.tetherBoss(4250, 0)
cons[cons.length] = Constraint.create({
pointA: {
diff --git a/js/mobs.js b/js/mobs.js
index ee16ba8..0123e3d 100644
--- a/js/mobs.js
+++ b/js/mobs.js
@@ -7,11 +7,6 @@ const mobs = {
while (i--) {
if (mob[i].alive) {
mob[i].do();
- // let j = mob[i].status.length;
- // while (j--) {
- // mob[i].status[j].effect();
- // if (mob[i].status[j].endCycle > game.cycle) mob[i].status.splice(j, 0);
- // }
} else {
mob[i].replace(i); //removing mob and replace with body, this is done here to avoid an array index bug with drawing I think
}
@@ -49,6 +44,8 @@ const mobs = {
}
},
statusSlow(who, cycles = 60) {
+ console.log('slow')
+
if (!who.shield && !who.isShielded) {
//remove other "slow" effects on this mob
let i = who.status.length
@@ -788,7 +785,6 @@ const mobs = {
if (this.seePlayer.recall && this.cd < game.cycle) {
const dist = Vector.sub(this.seePlayer.position, this.position);
const distMag = Vector.magnitude(dist);
- console.log(this.seePlayer.recall)
if (distMag < 400) {
this.cd = game.cycle + this.delay;
ctx.beginPath();
diff --git a/js/player.js b/js/player.js
index b129cf4..32f1068 100644
--- a/js/player.js
+++ b/js/player.js
@@ -564,7 +564,7 @@ const mech = {
// freeze game and display a full screen red color
if (dmg > 0.05) {
- if (dmg > 0.07 && mech.holdingMassScale > 0.2) mech.drop(); //drop block if holding
+ if (dmg > 0.15 * mech.holdingMassScale) mech.drop(); //drop block if holding
game.fpsCap = 4 //40 - Math.min(25, 100 * dmg)
game.fpsInterval = 1000 / game.fpsCap;
} else {
diff --git a/js/spawn.js b/js/spawn.js
index d5a3af9..68bb254 100644
--- a/js/spawn.js
+++ b/js/spawn.js
@@ -80,7 +80,7 @@ const spawn = {
},
randomLevelBoss(x, y) {
// suckerBoss, laserBoss, tetherBoss, snakeBoss all need a particular level to work so they are not included
- const options = ["shooterBoss", "cellBossCulture", "bomberBoss"]
+ const options = ["shooterBoss", "cellBossCulture", "bomberBoss", "timeSkipBoss"]
spawn[options[Math.floor(Math.random() * options.length)]](x, y)
},
//mob templates *********************************************************************************************
@@ -638,34 +638,40 @@ const spawn = {
}
}
},
- timeSkipBoss(x, y, radius = 80) {
+ timeSkipBoss(x, y, radius = 60) {
mobs.spawn(x, y, 6, radius, '#000');
let me = mob[mob.length - 1];
// me.stroke = "transparent"; //used for drawSneaker
me.timeSkipLastCycle = 0
- me.eventHorizon = 1300; //required for black hole
- me.seeAtDistance2 = (me.eventHorizon + 1000) * (me.eventHorizon + 1000); //vision limit is event horizon
- me.accelMag = 0.00013 * game.accelScale;
+ me.eventHorizon = 1500; //required for black hole
+ me.seeAtDistance2 = (me.eventHorizon + 2000) * (me.eventHorizon + 2000); //vision limit is event horizon + 2000
+ me.accelMag = 0.00022 * game.accelScale;
// me.frictionAir = 0.005;
// me.memory = 1600;
- Matter.Body.setDensity(me, 0.018); //extra dense //normal is 0.001 //makes effective life much larger
+ Matter.Body.setDensity(me, 0.02); //extra dense //normal is 0.001 //makes effective life much larger
me.onDeath = function () {
//applying forces to player doesn't seem to work inside this method, not sure why
powerUps.spawnBossPowerUp(this.position.x, this.position.y)
};
me.do = function () {
//keep it slow, to stop issues from explosion knock backs
+ if (this.speed > 2) {
+ Matter.Body.setVelocity(this, {
+ x: this.velocity.x * 0.99,
+ y: this.velocity.y * 0.99
+ });
+ }
this.seePlayerCheck();
this.checkStatus();
this.attraction()
if (!game.isTimeSkipping) {
- const compress = 3
+ const compress = 2
if (this.timeSkipLastCycle < game.cycle - compress &&
Vector.magnitude(Vector.sub(this.position, player.position)) < this.eventHorizon) {
this.timeSkipLastCycle = game.cycle
game.timeSkip(compress)
- this.fill = `rgba(0,0,0,${0.1+0.1*Math.random()})`
+ this.fill = `rgba(0,0,0,${0.1+0.4*Math.random()})`
this.stroke = "#000"
this.isShielded = false;
this.dropPowerUp = true;
@@ -673,7 +679,7 @@ const spawn = {
ctx.beginPath();
ctx.arc(this.position.x, this.position.y, this.eventHorizon, 0, 2 * Math.PI);
- ctx.fillStyle = `rgba(255,255,255,${mech.energy*0.5})`;
+ ctx.fillStyle = "#fff";
ctx.globalCompositeOperation = "destination-in"; //in or atop
ctx.fill();
ctx.globalCompositeOperation = "source-over";
@@ -703,7 +709,7 @@ const spawn = {
this.collisionFilter.mask = cat.player | cat.map | cat.body | cat.mob; //can't touch bullets
ctx.beginPath();
ctx.arc(this.position.x, this.position.y, this.eventHorizon, 0, 2 * Math.PI);
- ctx.fillStyle = `rgba(0,0,0,${0.1*Math.random()})`;
+ ctx.fillStyle = `rgba(0,0,0,${0.05*Math.random()})`;
ctx.fill();
}
}
diff --git a/todo.txt b/todo.txt
index f23f278..3c4040d 100644
--- a/todo.txt
+++ b/todo.txt
@@ -5,7 +5,24 @@ boss mob - just a faster and larger version of a springer mob
always shielded
consider combining with time skipper field?
-pulse and time dilation only ones left with no dedicated mod
+pulse and time dilation only upgrades left with no dedicated mod
+
+mob - time skipper: sends a pulse wave out that will cause time to jump forward 1 second.
+
+mob stabber - extends one vector like the shooter, but quickly in order to stab
+
+mob sniper - targeting laser, then a high speed, no gravity bullet
+
+mod - nails do poison damage
+
+mod - increase laser bot range, and reduce energy drain
+
+mod - mines become a turret that fires nails
+ it could float to the mouse location on fire
+
+mod - blocks stun mobs
+
+settings - custom keys binding
lore - a robot (the player) gains self awareness
each mod/gun/field is a new tech
@@ -16,46 +33,6 @@ lore - a robot (the player) gains self awareness
you get immortality and Infinity damage
the next level is the final level
when you die with Quantum Immortality there is a chance of lore text
- make a global variable that goes up by one every time you play
- show text at start, loading simulation #...
-
-mod - status effects last 1 second longer
- cryonics : a mod that increases the freezing time of mobs.
- wait until you have more status effects written
-
-mob Boss - time skipper: sends a pulse wave out that will cause time to jump forward 1 second.
- what about a series of short time skips forward 10 cycles at a time
-
-MOB stabber - extends one vector like the shooter, but quickly in order to stab
-
-work on burn status effect
- graphics don't look right
- how is it different from the chemical dot
-
-mod - nails do poison damage
-
-mod - increase laser bot range, and reduce energy drain
-
-mod - mines become a turret that fires nails
- it could float to the mouse location on fire
-
-dash - mod when pressing left or right on the ground, teleport to the right until you find an obstruction
- do repeated horizontal zone queries until they hit map or block
- up to a max range of like 10 player widths
- this didn't work as a field, but maybe as a gun?
-
-mod - blocks stun mobs
-
-mod or field - turn blocks into spores or drones
-
-mod - robot that attack nearby mobs, and delivers a stun status effect
- use laser bot code for the attack
- large and 5 sided?
-
-settings - auto aim at nearest mob
-settings - custom keys binding
-
-mod - energy recharges faster when not moving
atmosphere levels: change the pace, give the user a rest between combat
low or no combat, but more graphics
@@ -71,11 +48,9 @@ atmosphere levels: change the pace, give the user a rest between combat
in the final level you see your self at the starting level, with the wires
you shoot your self to wake up?
-MOB sniper - targeting laser, then a high speed, no gravity bullet
-
css transition for pause menu
-mod: do extra damage based on your speed
+mod - do extra damage based on your speed
do more damage when not moving?
take less damage when not moving?
@@ -88,15 +63,6 @@ weekly random challenge where everyone playing each week gets the same random se
The randomness would be determined by the date so it would sync everyone.
power ups still drop, but the drops are determined by a preset list that changes each week.
-mod: do something at the end of each level
- heal to full
- should still be effected by the heal reduction at higher difficulty
- give ammo to current gun
- give goals/quests for each level
- how to track goals?
- take no damage
- don't shoot
-
gun: Spirit Bomb (singularity)
use charge up like rail gun
electricity graphics like plasma torch
@@ -105,7 +71,7 @@ gun: Spirit Bomb (singularity)
uses energy
hold above the player's head
-Boss levels
+small Boss levels
sensor that locks you in after you enter the boss room
boss that eats other mobs and gains stats from them
chance to spawn on any level (past level 5)
@@ -116,12 +82,6 @@ make power ups keep moving to player if the pickup field is turned off before th
not sure how to do this without adding a constant check
animate new level spawn by having the map aspects randomly fly into place
-
-new map with repeating endlessness
- get ideas from Manifold Garden game
- if falling, get teleported above the map
- I tried it, but had trouble getting the camera to adjust to the teleportation
- this can apply to blocks mobs, and power ups as well
give mobs more animal-like behaviors
like rain world