summaryrefslogtreecommitdiff
path: root/PE/pe-hack.lua
diff options
context:
space:
mode:
Diffstat (limited to 'PE/pe-hack.lua')
-rw-r--r--PE/pe-hack.lua59
1 files changed, 50 insertions, 9 deletions
diff --git a/PE/pe-hack.lua b/PE/pe-hack.lua
index 3148cb9..de19586 100644
--- a/PE/pe-hack.lua
+++ b/PE/pe-hack.lua
@@ -1,8 +1,8 @@
-- Parasite Eve's french patch
--- $Id: pe-hack.lua,v 1.6 2003-12-25 15:35:09 pixel Exp $
+-- $Id: pe-hack.lua,v 1.7 2003-12-26 19:05:30 pixel Exp $
function mainpatch()
- local dirent, pvd, root, is_cd1, is_cd2, slusname, fmvdir, systemcnfstring, inslus, slus, peimg, pesect, tim, startsect, fmvdirtree, xadirtree, falsesect, i
+ local dirent, pvd, root, is_cd1, is_cd2, slusname, fmvdir, systemcnfstring, inslus, slus, peimg, pesect, tim, startsect, fmvdirtree, xadirtree, falsesect, i, picts, pict
dirent = cdutil:findpath "/SLUS_006.62;1" or cdutil:findpath "/SLUS_006.68;1" or error "Not a Parasite Eve CD"
@@ -38,8 +38,8 @@ STACK=801fff00
iso:createfile(root, "SYSTEM.CNF", systemcnf, dirent)
print "Reading CD's slus file"
--- inslus = cdfile(cdutil, dirent)
- inslus = Input("PE-SLUS00662-patched-debug-room.exe")
+ inslus = cdfile(cdutil, dirent)
+-- inslus = Input("PE-SLUS00662-patched-debug-room.exe")
slus = Buffer(true)
slus:copyfrom(inslus)
apply_hacks(slus_hacks, slus)
@@ -77,8 +77,19 @@ STACK=801fff00
print "Finalizing CD"
iso:createfile(root, "README.TXT", Input("readme.txt")):setbasicsxa()
+ iso:createfile(root, "DIVERS.HTM", Input("divers.htm")):setbasicsxa()
+ picts = iso:createdir(root, "PICTS")
+ picts:setbasicsxa()
+ for i, pict in ipairs(picts_files) do
+ iso:createfile(picts, string.upper(pict), Input("picts/" .. pict)):setbasicsxa()
+ end
falsesect = {}
+
+ for i = 1, 13500, 1 do
+ iso:createsector(falsesect, MODE2_FORM1)
+ end
+
for i = 1, 150, 1 do
iso:createsector(falsesect, MODE2)
end
@@ -169,7 +180,7 @@ function do_img_file(slus, startsect, pesect)
if (file3) then
if (groups[i] ~= nil) then
str = string.format("%02i", groups[i])
- file3 = patch_room(file3, Input("scripts/c/" .. str .. ".out"), i)
+ file3 = patch_room(file3, Input("scripts/" .. str .. ".bin"), i)
end
iso:putfile(file3)
end
@@ -359,10 +370,8 @@ function buffer_pad(buffer)
end
files = {
--- [1] = "various.bin",
--- [2] = "menus.bin",
- [1] = "scripts/c/various.out"
- [2] = "scripts/c/menus.bin"
+ [1] = "various.bin",
+ [2] = "menus.bin",
[10] = "font.tim",
[70] = "mainmenu.bin",
[72] = patch_map,
@@ -446,6 +455,9 @@ slus_hacks = {
-- PE.BIN filename extension
[0x01b4c] = { 0x54, 0x49, 0x4d },
+-- savefile filename
+ [0x016e5] = { 0x38 },
+
-- Debug room
-- [0x2f888] = { },
}
@@ -534,4 +546,33 @@ groups = {
[435] = 19, [436] = 19, [437] = 19,
}
+picts_files = {
+ "foe.jpg",
+ "tune-up1.jpg",
+ "tune-up2.jpg",
+ "tuto1.jpg",
+ "tuto10.jpg",
+ "tuto11.jpg",
+ "tuto12.jpg",
+ "tuto13.jpg",
+ "tuto14.jpg",
+ "tuto15.jpg",
+ "tuto16.jpg",
+ "tuto17.jpg",
+ "tuto18.jpg",
+ "tuto19.jpg",
+ "tuto2.jpg",
+ "tuto20.jpg",
+ "tuto21.jpg",
+ "tuto22.jpg",
+ "tuto23.jpg",
+ "tuto3.jpg",
+ "tuto4.jpg",
+ "tuto5.jpg",
+ "tuto6.jpg",
+ "tuto7.jpg",
+ "tuto8.jpg",
+ "tuto9.jpg",
+}
+
mainpatch()