neige d'aoust

knowledge, art, and other stuff

User Tools

Site Tools


mozaic

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
mozaic [2025/03/18 01:28] Yukimozaic [2025/03/20 01:28] (current) Yuki
Line 3: Line 3:
 Some game distributed with lottery tickets from Loto-Québec Some game distributed with lottery tickets from Loto-Québec
  
-Download and install instructions: [[https://www.youtube.com/watch?v=YygmFM3qP8w]] (also hacked to bypass ticket validity checks)+Download: [[https://archive.org/details/mozaic_202207]] (also hacked to bypass ticket validity checks) 
 + 
 +See also: [[https://www.youtube.com/watch?v=YygmFM3qP8w]]
  
 ===== Install on Wine ===== ===== Install on Wine =====
  
-This game makes heavy use of Indeo 5 and other DirectShow codecs so make sure to install it. Ideally, use a 32-bit prefix and pretend you're Windows XP.+This game makes heavy use of Indeo 5 and other DirectShow codecs so make sure to install it. Use a 32-bit prefixand ideally pretend you're Windows XP and enable windowed mode.
  
 <code bash> <code bash>
 # mount the ISO # mount the ISO
 +# the game won't run without it
 sudo mount MOZAIC.iso /mnt/cdrom sudo mount MOZAIC.iso /mnt/cdrom
  
-# create a new 32-bit prefix, and optionally pretend you're on Windows XP +# create a new 32-bit prefix 
-# it currently won't work in a 64-bit prefix like the one that is created by default+# it currently won't work in a 64-bit prefix due to the codecs 
 +# also make sure the CD-ROM is detected as such
 export WINEARCH=win32 export WINEARCH=win32
 export WINEPREFIX=~/.wine32 export WINEPREFIX=~/.wine32
Line 35: Line 39:
 |magic|string|0|4 bytes|"PACK"| |magic|string|0|4 bytes|"PACK"|
 |size|u32|4|4 bytes|Number of entries| |size|u32|4|4 bytes|Number of entries|
-|???| |8|32 bytes|Unknown|+|???| |8|32 bytes|Seems unused, can be used as a comment field|
 |filelist|File|40|size * (12 + name)| | |filelist|File|40|size * (12 + name)| |
  
Line 43: Line 47:
 |filesize|u32|0|4 bytes| | |filesize|u32|0|4 bytes| |
 |offset|u32|4|4 bytes|Byte offset from the beginning of the file| |offset|u32|4|4 bytes|Byte offset from the beginning of the file|
-|???|u32|8|4 bytes|Unknown|+|???|u32|8|4 bytes|Unknown, the game crashes right away if it's not what it expected|
 |name|Null-terminated string|12| |File path and name| |name|Null-terminated string|12| |File path and name|
  
Line 65: Line 69:
 </code> </code>
  
-===== Hacking =====+===== Tools ===== 
 + 
 +<html><details><summary>Node.js pak extractor</summary></html> 
 +<code javascript extractpak.js> 
 +const fs = require('node:fs'); 
 +const path = require('node:path'); 
 + 
 +if(process.argv.length < 3) 
 +
 +    console.log("error: no input file"); 
 +    process.exit(1); 
 +
 + 
 +var f = fs.readFileSync(process.argv[2]); 
 + 
 +var magic = f.toString('hex', 0, 4); 
 +if(magic != "5041434b"
 +
 +    console.log("error: invalid file"); 
 +    process.exit(1); 
 +
 + 
 +var size = f.readUInt32LE(4); 
 +var offset = 40; 
 + 
 +for(var i = 0; i < size; i++) 
 +
 +    var filesize = f.readUint32LE(offset); offset+=4; 
 +    var fileoffset = f.readUint32LE(offset); offset+=4; 
 +    var mystery = f.readUint32LE(offset); offset+=4; 
 +    var next = f.indexOf(0, offset, 'ascii'); 
 +    var name = f.toString('ascii', offset, next).replaceAll("\\", "/"); 
 +    offset = next+1; 
 +    console.log("%s; %s", name, mystery); 
 + 
 +    fs.mkdirSync(path.dirname(name), { recursive: true }); 
 +    var data = fs.createWriteStream(name, 'binary'); 
 +    data.end(f.slice(fileoffset, fileoffset+filesize)); 
 +
 +</code> 
 +<html></details></html>
  
-soon+[[https://a39.dev/yuki/mpar|mpar]] - extractor and archiver
mozaic.1742275695.txt.gz · Last modified: 2025/03/18 01:28 by Yuki