images back

images are back as an option due to public outcry

bug fixes
  getting a power up quickly after warp, difficulty or instructions power ups was making the screen go blank
  heuristics resets on death properly now
This commit is contained in:
landgreen
2024-10-09 18:53:18 -07:00
parent a8c6c0ea0e
commit 9c2c9be4ed
6 changed files with 21 additions and 18 deletions

View File

@@ -53,9 +53,9 @@
<details id = 'settings-details'> <details id = 'settings-details'>
<summary>settings</summary> <summary>settings</summary>
<div style="line-height: 150%;" class="details-div"> <div style="line-height: 150%;" class="details-div">
<!-- <input onclick="build.showImages('settings')" type="checkbox" id="hide-images" name="hide-images" style="width:17px; height:17px;"> <input onclick="build.showImages('settings')" type="checkbox" id="hide-images" name="hide-images" style="width:17px; height:17px;">
<label for="hide-images" title="hide images for fields, guns, and tech">hide images</label> <label for="hide-images" title="hide images for fields, guns, and tech">hide images</label>
<br> --> <br>
<input onclick="build.hideHUD('settings')" type="checkbox" id="hide-hud" name="hide-hud" style="width:17px; height:17px;"> <input onclick="build.hideHUD('settings')" type="checkbox" id="hide-hud" name="hide-hud" style="width:17px; height:17px;">
<label for="hide-hud" title="hide: tech, damage taken, damage, in game console, new level animation">minimal HUD</label> <label for="hide-hud" title="hide: tech, damage taken, damage, in game console, new level animation">minimal HUD</label>
<br> <br>

View File

@@ -1830,9 +1830,9 @@ if (localSettings.isAllowed && !localSettings.isEmpty) {
localSettings.loreCount = 0; //this sets what conversation is heard localSettings.loreCount = 0; //this sets what conversation is heard
if (localSettings.isAllowed) localStorage.setItem("localSettings", JSON.stringify(localSettings)); //update local storage if (localSettings.isAllowed) localStorage.setItem("localSettings", JSON.stringify(localSettings)); //update local storage
} }
// if (localSettings.isHideImages === undefined) localSettings.isHideImages = true //default to hide images if (localSettings.isHideImages === undefined) localSettings.isHideImages = true //default to hide images
// document.getElementById("hide-images").checked = localSettings.isHideImages document.getElementById("hide-images").checked = localSettings.isHideImages
localSettings.isHideImages = true //no images // localSettings.isHideImages = true //no images
if (localSettings.isHideHUD === undefined) localSettings.isHideHUD = true if (localSettings.isHideHUD === undefined) localSettings.isHideHUD = true
document.getElementById("hide-hud").checked = localSettings.isHideHUD document.getElementById("hide-hud").checked = localSettings.isHideHUD
@@ -1877,7 +1877,7 @@ if (localSettings.isAllowed && !localSettings.isEmpty) {
if (localSettings.isAllowed) localStorage.setItem("localSettings", JSON.stringify(localSettings)); //update local storage if (localSettings.isAllowed) localStorage.setItem("localSettings", JSON.stringify(localSettings)); //update local storage
document.getElementById("community-maps").checked = localSettings.isCommunityMaps document.getElementById("community-maps").checked = localSettings.isCommunityMaps
simulation.isCommunityMaps = localSettings.isCommunityMaps simulation.isCommunityMaps = localSettings.isCommunityMaps
// document.getElementById("hide-images").checked = localSettings.isHideImages document.getElementById("hide-images").checked = localSettings.isHideImages
document.getElementById("fps-select").value = localSettings.fpsCapDefault document.getElementById("fps-select").value = localSettings.fpsCapDefault
document.getElementById("banned").value = localSettings.banList document.getElementById("banned").value = localSettings.banList
} }

View File

@@ -727,9 +727,9 @@ const level = {
simulation.isChoosing = false; //stops p from un pausing on key down simulation.isChoosing = false; //stops p from un pausing on key down
build.unPauseGrid() build.unPauseGrid()
document.getElementById("choose-grid").style.opacity = "0" document.getElementById("choose-grid").style.opacity = "0"
setTimeout(() => {
document.getElementById("choose-grid").style.visibility = "hidden" document.getElementById("choose-grid").style.visibility = "hidden"
}, 1000); // setTimeout(() => {
// }, 1000);
}, },
populateLevels() { //run a second time if URL is loaded populateLevels() { //run a second time if URL is loaded
if (document.getElementById("banned").value) { //remove levels from ban list in settings if (document.getElementById("banned").value) { //remove levels from ban list in settings

View File

@@ -381,6 +381,7 @@ const powerUps = {
b.giveGuns("name") //nail gun shotgun super balls wave missiles grenades spores drones foam harpoon mine laser b.giveGuns("name") //nail gun shotgun super balls wave missiles grenades spores drones foam harpoon mine laser
tech.damage *= 2 //2x damage tech.damage *= 2 //2x damage
m.immuneCycle = Infinity //immune to damage m.immuneCycle = Infinity //immune to damage
m.coyoteCycles = Infinity //air jumps
m.energy = 0 //set energy m.energy = 0 //set energy
m.health = 1 //set health m.health = 1 //set health
m.maxHealth = 1 //set max health m.maxHealth = 1 //set max health

View File

@@ -1287,13 +1287,14 @@ const tech = {
}, },
refundAmount: 0, refundAmount: 0,
remove() { remove() {
if (this.count && m.alive) { if (this.count) {
for (let i = 0; i < this.totalRate.length; i++) tech.fireRate *= this.totalRate[i] // for (let i = 0; i < this.totalRate.length; i++) tech.fireRate *= this.totalRate[i]
if (this.refundAmount > 0) { if (this.refundAmount > 0) {
tech.removeJunkTechFromPool(this.refundAmount) tech.removeJunkTechFromPool(this.refundAmount)
this.refundAmount = 0 this.refundAmount = 0
} }
} }
tech.fireRate = 1
this.totalRate.length = 0 this.totalRate.length = 0
b.setFireCD(); b.setFireCD();
} }

View File

@@ -1,17 +1,18 @@
******************************************************** NEXT PATCH ************************************************** ******************************************************** NEXT PATCH **************************************************
images have been disabled images are back as an option due to public outcry
I think they don't fit stylistically
new power up: level WARP bug fixes
it shows up when you enter testing mode on the initial level getting a power up quickly after warp, difficulty or instructions power ups was making the screen go blank
interferometer horizontal laser now moves with the elevator heuristics resets on death properly now
LaunchSite community map updated
some minor bug fixes
******************************************************** BUGS ******************************************************** ******************************************************** BUGS ********************************************************
can't consistenly reproduce, but it happened several times this way
on initial level I press T and took the warp and exited it, then I too a field and the screen went blank
figure out why seeded random isn't making runs the same: figure out why seeded random isn't making runs the same:
shuffle is being used for a wide variety of things that don't need a seeded random shuffle is being used for a wide variety of things that don't need a seeded random
make two shuffle functions? make two shuffle functions?