https://pvzm.net/ to play [Read-only GitHub mirror] pvzm.net
modded vs pvz plants-vs-zombies plantsvszombies javascript online zombie noads jspvz pvzm game plants plant
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ClaytonTDM - saving levels as files Original commit: https://github.com/ROBlNET13/pvz/commit/c3279f9228cee40ee5f77ad9361bd1cfc2f9f1be

+19 -14
+1 -1
game/images/Zombies/CX/v.html
··· 1 - ac9a32aefdc8f1a2de0bbbbbdbdf83fd57771edd 1 + c3279f9228cee40ee5f77ad9361bd1cfc2f9f1be
+8 -7
game/js/CFP_Beta.js
··· 50 50 } 51 51 52 52 function decompressStringNoBase64(compressed) { 53 - compressed = Uint8Array.from(compressed, (c) => 54 - c.charCodeAt(0) 55 - ); 53 + compressed = Uint8Array.from(compressed, (c) => c.charCodeAt(0)); 56 54 const decompressed = pako.inflate(compressed); 57 55 const decompressedString = new TextDecoder().decode(decompressed); 58 56 return decompressedString; ··· 75 73 a.click(); 76 74 document.body.removeChild(a); 77 75 URL.revokeObjectURL(url); 78 - } 79 - 76 + } 80 77 81 78 async function openAndLoadFileAsBytes() { 82 79 return new Promise((resolve, reject) => { ··· 101 98 } 102 99 103 100 async function fileToLevelData() { 104 - return "=" + compressString(decompressStringFromBytes(await openAndLoadFileAsBytes())); // i hate this and want to fix it but its 4 am and i need to sleep. fuck text encoding 101 + return ( 102 + "=" + 103 + compressString( 104 + decompressStringFromBytes(await openAndLoadFileAsBytes()) 105 + ) 106 + ); // i hate this and want to fix it but its 4 am and i need to sleep. fuck text encoding 105 107 } 106 - 107 108 108 109 function cloneFromPlants(name, sun, screenshot) { 109 110 name = name
+1 -1
game/level/izombiecustommenu.js
··· 58 58 let levelData = await fileToLevelData(); 59 59 inputDataElement.value = levelData; 60 60 buttonElement.click(); 61 - } 61 + }; 62 62 $("dAll").appendChild(buttonElementUpload); 63 63 buttonElement.onclick = function () { 64 64 // store the input value and disable it, then make it say "Loading..."
+9 -5
game/level/izombieleveleditor.js
··· 307 307 ); 308 308 closeButton.id = "btnNextLevel"; // not actually a next level button, but it's the same style 309 309 closeButton.style.top = "60%"; 310 - closeButton.style.left = "calc(50% - 120px)"; // "calc(33.333% - 56.5px)"; 310 + closeButton.style.left = 311 + "calc(50% - 120px)"; // "calc(33.333% - 56.5px)"; 311 312 closeButton.onclick = function () { 312 313 $("dAll").style.zIndex = ""; 313 314 let oldLv = oS.Lvl; ··· 332 333 ); 333 334 uploadButton.id = "btnNextLevel"; // not actually a next level button, but it's the same style 334 335 uploadButton.style.top = "60%"; 335 - uploadButton.style.left = "calc(50% - 56.5px)"; 336 + uploadButton.style.left = 337 + "calc(50% - 56.5px)"; 336 338 uploadButton.onclick = function () { 337 339 // nothing for now 338 340 }; ··· 351 353 ); 352 354 downloadButton.id = "btnNextLevel"; // not actually a next level button, but it's the same style 353 355 downloadButton.style.top = "60%"; 354 - downloadButton.style.left = "calc(50% + 5px)"; // "calc(66.666% - 56.5px)"; 356 + downloadButton.style.left = 357 + "calc(50% + 5px)"; // "calc(66.666% - 56.5px)"; 355 358 downloadButton.onclick = function () { 356 359 downloadBytesAsFile( 357 360 compressStringAsBytes( 358 361 tinyifyClone( 359 362 cloneFromPlants(l, f) 360 363 ) 361 - ), l + ".izl2" 362 - ) 364 + ), 365 + l + ".izl2" 366 + ); 363 367 }; 364 368 downloadButton.style.zIndex = "1000"; 365 369