mirror of
https://github.com/crskycode/GARbro.git
synced 2026-07-08 01:30:18 +08:00
(IResource.GetDefaultExtension): new method.
This commit is contained in:
@@ -95,10 +95,19 @@ namespace GameRes
|
|||||||
|
|
||||||
protected IResource ()
|
protected IResource ()
|
||||||
{
|
{
|
||||||
Extensions = new string[] { Tag.ToLowerInvariant() };
|
Extensions = new string[] { GetDefaultExtension() };
|
||||||
Signatures = new uint[] { this.Signature };
|
Signatures = new uint[] { this.Signature };
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected string GetDefaultExtension ()
|
||||||
|
{
|
||||||
|
var ext = Tag.ToLowerInvariant();
|
||||||
|
int slash = ext.IndexOf ('/');
|
||||||
|
if (slash != -1)
|
||||||
|
ext = ext.Substring (0, slash);
|
||||||
|
return ext;
|
||||||
|
}
|
||||||
|
|
||||||
public virtual ResourceOptions GetDefaultOptions ()
|
public virtual ResourceOptions GetDefaultOptions ()
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
Reference in New Issue
Block a user