mirror of
https://github.com/billsonnn/nitro-converter.git
synced 2025-01-18 14:36:26 +01:00
Fix palettes
This commit is contained in:
parent
96825fb963
commit
38fb354711
@ -67,6 +67,7 @@ export class AssetMapper extends Mapper
|
||||
if(assetXML.y !== undefined) asset.y = assetXML.y;
|
||||
if(assetXML.flipH !== undefined) asset.flipH = assetXML.flipH;
|
||||
if(assetXML.flipV !== undefined) asset.flipV = assetXML.flipV;
|
||||
if(assetXML.usesPalette !== undefined) asset.usesPalette = assetXML.usesPalette;
|
||||
|
||||
output[assetXML.name] = asset;
|
||||
}
|
||||
|
@ -6,7 +6,7 @@ export class AssetXML
|
||||
private readonly _y: number;
|
||||
private readonly _flipH: boolean;
|
||||
private readonly _flipV: boolean;
|
||||
private readonly _usesPalette: number;
|
||||
private readonly _usesPalette: boolean;
|
||||
|
||||
constructor(asset: any)
|
||||
{
|
||||
@ -20,7 +20,7 @@ export class AssetXML
|
||||
if(attributes.x !== undefined) this._y = parseInt(attributes.y);
|
||||
if(attributes.flipH !== undefined) this._flipH = (attributes.flipH === '1');
|
||||
if(attributes.flipV !== undefined) this._flipV = (attributes.flipV === '1');
|
||||
if(attributes.usesPalette !== undefined) this._usesPalette = parseInt(attributes.usesPalette);
|
||||
if(attributes.usesPalette !== undefined) this._usesPalette = (attributes.usesPalette === '1');
|
||||
}
|
||||
}
|
||||
|
||||
@ -54,7 +54,7 @@ export class AssetXML
|
||||
return this._flipV;
|
||||
}
|
||||
|
||||
public get usesPalette(): number
|
||||
public get usesPalette(): boolean
|
||||
{
|
||||
return this._usesPalette;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user