Spaces:
Paused
Paused
File size: 3,355 Bytes
69f226e | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 | FROM oven/bun:latest
WORKDIR /app
RUN apt-get update && apt-get install -y git
RUN git clone https://github.com/VillainsRule/CrackedShell.git .
# High-performance config without artificial limits
RUN echo 'export default { \
port: 7860, \
host: "0.0.0.0", \
whitelist: ["*"], \
corsOrigins: ["*"], \
blockAds: true, \
blockTracking: true, \
performanceMode: "aggressive" \
}' > config.ts
# Performance optimization without quality reduction
RUN mkdir -p scripts && echo '\
// Maximum performance without quality loss \
window.addEventListener("load", () => { \
// Remove FPS cap - let it run as fast as possible \
window.targetFPS = 144; \
window.unlockFPS = true; \
\
// Keep high quality but optimize rendering \
const canvas = document.querySelector("canvas"); \
if (canvas) { \
const ctx = canvas.getContext("webgl2", { \
antialias: true, \
powerPreference: "high-performance", \
desynchronized: true, \
preserveDrawingBuffer: false, \
failIfMajorPerformanceCaveat: false \
}); \
} \
\
// Maximum network update rate for smooth gameplay \
window.networkUpdateRate = 60; \
window.clientPrediction = true; \
window.interpolationDelay = 50; \
\
// Keep full quality settings \
window.textureQuality = 1.0; \
window.shadowQuality = "high"; \
window.particleCount = "normal"; \
window.renderDistance = "far"; \
\
// Enable GPU acceleration flags \
window.gpuAcceleration = true; \
window.useWebGL2 = true; \
\
// Optimize JavaScript execution \
window.optimizeAnimationLoop = true; \
window.useRequestIdleCallback = false; \
}); \
\
// Performance monitoring \
let lastTime = performance.now(); \
let frames = 0; \
\
function checkFPS() { \
frames++; \
const currentTime = performance.now(); \
if (currentTime >= lastTime + 1000) { \
console.log(`FPS: ${frames}`); \
frames = 0; \
lastTime = currentTime; \
} \
requestAnimationFrame(checkFPS); \
} \
checkFPS();' > scripts/performance.js
# Add Chrome flags optimization script
RUN echo '\
// Chromebook-specific optimizations without quality loss \
if (/CrOS/.test(navigator.userAgent)) { \
// Enable GPU rasterization \
chrome.gpuRasterization = true; \
\
// Use hardware acceleration \
document.body.style.transform = "translateZ(0)"; \
\
// Enable ANGLE graphics backend for better WebGL performance \
window.angleBackend = "opengl"; \
\
// Optimize canvas rendering \
CanvasRenderingContext2D.prototype.imageSmoothingEnabled = true; \
CanvasRenderingContext2D.prototype.imageSmoothingQuality = "high"; \
} \
\
// Optimize network for minimal latency \
if (window.RTCPeerConnection) { \
window.RTCPeerConnection.prototype.createDataChannel = new Proxy( \
window.RTCPeerConnection.prototype.createDataChannel, { \
apply(target, thisArg, args) { \
if (args[1]) { \
args[1].ordered = false; \
args[1].maxRetransmits = 0; \
} \
return target.apply(thisArg, args); \
} \
} \
); \
}' > scripts/chromebook-optimize.js
RUN bun install
EXPOSE 7860
CMD ["bun", "."] |