shipMode
added 2 new testing keys: J = clear mobs, H = infinity health added junk tech: ship (it's hard to control, but you get better with practice) m.shipMode() in console
This commit is contained in:
29
js/index.js
29
js/index.js
@@ -318,6 +318,9 @@ const build = {
|
||||
<div class="circle-grid gun" style="position:absolute; top:0; left:10px; opacity:0.65;"></div>
|
||||
</span>
|
||||
${tech.tech[i].name} ${isCount}</div>${tech.tech[i].description}</div>`
|
||||
} else if (tech.tech[i].isJunk) {
|
||||
// text += `<div class="pause-grid-module"><div class="grid-title"><div class="circle-grid junk"></div> ${tech.tech[i].name} ${isCount}</div>${tech.tech[i].description}</div></div>`
|
||||
techID.innerHTML = `<div class="grid-title"><div class="circle-grid junk"></div> ${tech.tech[i].name} ${isCount}</div>${tech.tech[i].description}</div>`
|
||||
} else {
|
||||
techID.innerHTML = `<div class="grid-title"><div class="circle-grid tech"></div> ${tech.tech[i].name} ${isCount}</div>${tech.tech[i].description}</div>`
|
||||
}
|
||||
@@ -741,11 +744,6 @@ window.addEventListener("keydown", function(event) {
|
||||
if (simulation.testing) {
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -785,6 +783,10 @@ window.addEventListener("keydown", function(event) {
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='key-input-pause'>H</td>
|
||||
<td class='key-used'>infinite health</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='key-input-pause'>N</td>
|
||||
<td class='key-used'>fill health, energy</td>
|
||||
</tr>
|
||||
<tr>
|
||||
@@ -795,6 +797,10 @@ window.addEventListener("keydown", function(event) {
|
||||
<td class='key-input-pause'>U</td>
|
||||
<td class='key-used'>next level</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='key-input-pause'>J</td>
|
||||
<td class='key-used'>clear mobs</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class='key-input-pause'>I/O</td>
|
||||
<td class='key-used'>zoom in / out</td>
|
||||
@@ -866,8 +872,14 @@ window.addEventListener("keydown", function(event) {
|
||||
b.giveGuns("all", 1000)
|
||||
break
|
||||
case "h":
|
||||
m.health = Infinity
|
||||
// m.energy = Infinity
|
||||
document.getElementById("health").style.display = "none"
|
||||
document.getElementById("health-bg").style.display = "none"
|
||||
break
|
||||
case "n":
|
||||
m.addHealth(Infinity)
|
||||
m.energy = m.maxEnergy;
|
||||
m.energy = m.maxEnergy
|
||||
break
|
||||
case "y":
|
||||
tech.giveTech()
|
||||
@@ -896,6 +908,11 @@ window.addEventListener("keydown", function(event) {
|
||||
case "u":
|
||||
level.nextLevel();
|
||||
break
|
||||
case "j":
|
||||
for (let i = 0, len = mob.length; i < len; ++i) mob[i].damage(Infinity, true)
|
||||
setTimeout(() => { for (let i = 0, len = mob.length; i < len; ++i) mob[i].damage(Infinity, true) }, 100);
|
||||
setTimeout(() => { for (let i = 0, len = mob.length; i < len; ++i) mob[i].damage(Infinity, true) }, 200);
|
||||
break
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user