Update README
This commit is contained in:
@@ -21,7 +21,7 @@ namespace BuildIRD
|
||||
ird1.Write("./test1.ird");
|
||||
ird1.Print();
|
||||
}
|
||||
catch (FileNotFoundException e)
|
||||
catch (FileNotFoundException)
|
||||
{
|
||||
Console.WriteLine("ERROR: File not found");
|
||||
}
|
||||
@@ -33,7 +33,7 @@ namespace BuildIRD
|
||||
ird2.Write("./test2.ird");
|
||||
ird2.Print();
|
||||
}
|
||||
catch (FileNotFoundException e)
|
||||
catch (FileNotFoundException)
|
||||
{
|
||||
Console.WriteLine("ERROR: File not found");
|
||||
}
|
||||
|
||||
@@ -10,13 +10,17 @@
|
||||
<Authors>Deterous</Authors>
|
||||
<Description>Library for ISO Rebuild Data</Description>
|
||||
<Copyright>Copyright (c) Deterous 2023</Copyright>
|
||||
<PackageReadmeFile>README.MD</PackageReadmeFile>
|
||||
<PackageReadmeFile>README.md</PackageReadmeFile>
|
||||
<RepositoryUrl>https://github.com/Deterous/LibIRD</RepositoryUrl>
|
||||
<RepositoryType>git</RepositoryType>
|
||||
<PackageTags>ps3 iso ird</PackageTags>
|
||||
<PackageLicenseExpression>GPL-3.0-only</PackageLicenseExpression>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="../README.md" Pack="true" PackagePath=""/>
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="DiscUtils.Core" Version="0.16.13" />
|
||||
<PackageReference Include="DiscUtils.Iso9660" Version="0.16.13" />
|
||||
|
||||
@@ -1,42 +1,42 @@
|
||||
# Library for ISO Rebuild Data (LibIRD)
|
||||
|
||||
This .NET library provides methods for generating, writing, and reading IRD files. Functionality is provided for deterministically generating IRDs such that a redump ISO and key have a 1-to-1 correspondence with an unique IRD file.
|
||||
.NET library for generating, writing, and reading IRD files. Functionality is provided for deterministically generating IRDs such that a redump ISO and key have a 1-to-1 correspondence with an IRD file.
|
||||
|
||||
## How to use LibIRD
|
||||
|
||||
### Reproducible, redump-style IRDs
|
||||
|
||||
The standard way of generating a reproducible, redump-style IRD with LibIRD is with a redump ISO file and a redump key file (e.g. http://redump.org/disc/28721/key/):
|
||||
```
|
||||
The standard way of generating a reproducible, redump-style IRD is with a redump ISO file and a redump key file (e.g. http://redump.org/disc/28721/key/):
|
||||
```cs
|
||||
byte[] discKey = File.ReadAllBytes("./game.key");
|
||||
IRD ird = new ReIRD("./game.iso", discKey);
|
||||
```
|
||||
alternatively, the disc key can be extracted from a [ManaGunZ](https://github.com/Zarh/ManaGunZ/) .getkey.log file:
|
||||
```
|
||||
Alternatively, the disc key can be extracted from a [ManaGunZ](https://github.com/Zarh/ManaGunZ/) log file:
|
||||
```cs
|
||||
IRD ird = new ReIRD("./game.iso", "./game.getkey.log");
|
||||
```
|
||||
|
||||
### Custom IRDs
|
||||
|
||||
Functionality is also provided for creating custom IRDs, with whatever data you want. One way is to use an ISO with a custom disc key, disc ID, and PIC:
|
||||
```
|
||||
Functionality is also provided for creating IRDs with a custom disc key, disc ID, and PIC:
|
||||
```cs
|
||||
byte[] discKey = new byte[16];
|
||||
byte[] discID = new byte[16];
|
||||
byte[] PIC = new byte[115];
|
||||
// Set vars to desired values
|
||||
IRD ird = new IRD("./game.iso", discKey, discID, discPIC);
|
||||
```
|
||||
As before, a [ManaGunZ](https://github.com/Zarh/ManaGunZ/) log file can also be used with an ISO to create an IRD, with the disc key, disc ID, and PIC all being extracted from the .getkey.log file.
|
||||
```
|
||||
As before, a [ManaGunZ](https://github.com/Zarh/ManaGunZ/) log file can also be used with an ISO to create a custom IRD, with the disc key, disc ID, and PIC all being extracted from the log file (rather than just the key).
|
||||
```cs
|
||||
IRD ird = new IRD("./game.iso", "./game.getkey.log");
|
||||
```
|
||||
Finally, an existing IRD file can be read to create an IRD:
|
||||
```
|
||||
```cs
|
||||
IRD ird = IRD.Read("./game.ird")
|
||||
```
|
||||
|
||||
An IRD can be then be tweaked, its fields printed, and written to a new IRD:
|
||||
```
|
||||
```cs
|
||||
ird.UID = 0x9F1A51D8;
|
||||
ird.Print();
|
||||
ird.Write("game2.ird");
|
||||
|
||||
Reference in New Issue
Block a user