Jump to content


Photo

[5.1] PatchFailedException in bgmain.exe


  • Please log in to reply
1 reply to this topic

#1 Orions_Stardom

Orions_Stardom
  • Gibberlings
  • 206 posts

Posted 11 February 2007 - 11:25 PM

Now that I got exception reporting working again, I've convinced 5.1.2 to give me the following error:

PatchFailedException in BGMain.exe expected hd0:\dialog.tlk got .\dialog.tlk


Which is strange, because I've already coded around the situation where the exe looks to already be patched - FileSystem.copy() has the following:
if(Arrays.equals(buff, oldVal) || Arrays.equals(buff, newVal)){
	out.write(
		newVal, 
		0, 
		buff.length
	);
	currentOffset += buff.length;
}
else{
	throw new PatchFailedException(
		source.getName(),
		oldVal,
		newVal
	);
}


#2 Orions_Stardom

Orions_Stardom
  • Gibberlings
  • 206 posts

Posted 12 February 2007 - 07:48 PM

Ok, the odd error was due to a stupid error in FileSystem.java whereby it reported that it found the required new value, instead of what it actually found. This bug was because I had mistranscribed the values for BG2 in CloneData.java .




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users