mirror of
https://github.com/osmarks/website
synced 2025-09-01 18:27:55 +00:00
Actually remember to publish changes
Updates, caching mechanism, new article, changes to stack and problem-solving, GUIHacker betterness, UUIDs on RSS
This commit is contained in:
BIN
assets/images/rote.jpg
Normal file
BIN
assets/images/rote.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 8.7 KiB |
@@ -242,6 +242,9 @@ function GuiHacker(){
|
||||
this.consoleOutput();
|
||||
}
|
||||
|
||||
var progressBar = document.querySelector(".progress")
|
||||
var barProgress = 1
|
||||
|
||||
GuiHacker.prototype.render = function(){
|
||||
var ctx = settings.ctx,
|
||||
canvas = settings.canvas,
|
||||
@@ -291,6 +294,15 @@ GuiHacker.prototype.render = function(){
|
||||
ctxBars.fillRect(i+5,canvasBars.height,15,-barVal.val);
|
||||
}
|
||||
|
||||
barProgress += 0.0001
|
||||
if (barProgress < 1) {
|
||||
progressBar.style.display = "block"
|
||||
progressBar.style.backgroundImage = `linear-gradient(to right, green, green ${barProgress * 100}%, black ${barProgress * 100}%, black 100%)`
|
||||
progressBar.innerHTML = `${Math.floor(barProgress * 100)}%`
|
||||
} else {
|
||||
progressBar.style.display = "none"
|
||||
}
|
||||
|
||||
var self = this;
|
||||
requestAnimationFrame(function(){self.render();});
|
||||
};
|
||||
@@ -423,6 +435,10 @@ window.addEventListener("keydown", ev => {
|
||||
accessDenied.style.display = accessDenied.style.display === "none" ? "block" : "none"
|
||||
ev.preventDefault()
|
||||
}
|
||||
if (ev.key === "p" && ev.altKey) {
|
||||
console.log("activating ominous progress bar")
|
||||
barProgress = 0
|
||||
}
|
||||
else if (Math.random() > 0.8) {
|
||||
guiHacker.consoleOutput(true)
|
||||
}
|
||||
|
Reference in New Issue
Block a user