From d520ccca1d2a937d63f5743f364c1b165115f626 Mon Sep 17 00:00:00 2001 From: Baptiste Date: Tue, 17 Dec 2024 18:36:19 +0100 Subject: [PATCH] feat(cheat) : adding 2 new functions from hell --- public_html/assets/phone/webview/lester.html | 2 + public_html/js/global.js | 42 ++++++++++++++++++-- 2 files changed, 40 insertions(+), 4 deletions(-) diff --git a/public_html/assets/phone/webview/lester.html b/public_html/assets/phone/webview/lester.html index 67e8a1e..0900196 100644 --- a/public_html/assets/phone/webview/lester.html +++ b/public_html/assets/phone/webview/lester.html @@ -54,6 +54,8 @@ COLLISIONS FULL LIFE GOD MOD +AK-47 +TP sur clique gauche SAFE ZONE MAP 0 MAP 1 diff --git a/public_html/js/global.js b/public_html/js/global.js index 57905fc..30590e3 100644 --- a/public_html/js/global.js +++ b/public_html/js/global.js @@ -198,12 +198,40 @@ function Donjon() { } -god_mode = false; +cheat_god_mode = false; +cheat_tp = false; +cheat_ak_47 = false; setInterval(() => { - if(god_mode) { + if(cheat_god_mode) { player.health = 10; } }, 20); +setInterval(() => { + if(cheat_ak_47) { + for(let i=0;i { + if(tp) { + e.preventDefault(); + let bounds = this.canvas.getBoundingClientRect(); + player.x=(e.clientX - bounds.x)*document.getElementById("canvas").width/bounds.width; + player.y=(e.clientY - bounds.y)*document.getElementById("canvas").height/bounds.height; + net.update(player); + return false; + } +},false); function Lester(type, data) { switch(type) { case 1: @@ -235,8 +263,14 @@ function Lester(type, data) { drawCollisions=true; } break; - case 6: - if(god_mode) { god_mode = false; } else { god_mode = true; } + case 6: // god mode + if(cheat_god_mode) { cheat_god_mode = false; } else { cheat_god_mode = true; } + break; + case 7: // AK-47 + if(cheat_ak_47) { cheat_ak_47 = false; } else { cheat_ak_47 = true; } + break; + case 8: // TP right_click + if(cheat_tp) { cheat_tp = false; } else { cheat_tp = true; } break; } } \ No newline at end of file