Does anyone know how to edit Mog_chronoengine.js to edit the offsetX and offsetY of the sprite for the treasure icon that appears on the map?
If using an enemy sprite that has an offset, the treasure that spawns has the same offset as an issue.
I found this in chrono engine code but i don't know what script to add for the offset:
Sprite_Character.prototype.setCharacterBitmapTreasure = function() {
if (!this._imgIcon) {this._imgIcon = ImageManager.loadSystem("IconSet")};
this.removeChild(this._upperBody);
this.removeChild(this._lowerBody);
this.bitmap = this._imgIcon;
var iconIndex = this._character._user.treasure[0].iconIndex;
var sx = iconIndex % 16 * 32;
var sy = Math.floor(iconIndex / 16) * 32;
this.setFrame(sx,sy,32,32);
this.scale.x = 1.0;
this.scale.y = 1.00;
this.scale.rotation = 0;
this._character._through = true;
};
I tried to add for example "this.y = 64;" but it's not working and i'm out of ideas
Thank you very much in advance to any lifesaver there.
-----------
If using an enemy sprite that has an offset, the treasure that spawns has the same offset as an issue.
I found this in chrono engine code but i don't know what script to add for the offset:
Sprite_Character.prototype.setCharacterBitmapTreasure = function() {
if (!this._imgIcon) {this._imgIcon = ImageManager.loadSystem("IconSet")};
this.removeChild(this._upperBody);
this.removeChild(this._lowerBody);
this.bitmap = this._imgIcon;
var iconIndex = this._character._user.treasure[0].iconIndex;
var sx = iconIndex % 16 * 32;
var sy = Math.floor(iconIndex / 16) * 32;
this.setFrame(sx,sy,32,32);
this.scale.x = 1.0;
this.scale.y = 1.00;
this.scale.rotation = 0;
this._character._through = true;
};
I tried to add for example "this.y = 64;" but it's not working and i'm out of ideas
Thank you very much in advance to any lifesaver there.
-----------