RPG Maker MV

RPG Maker MV

PE Mar 26, 2019 @ 3:29pm
Changing the MOG_ChronoEngine.js Default Font to SFont
I am currently using MOGHUNTER’s Chrono Engine[atelierrgss.wordpress.com] ABS plugin in my project, as well as Victor Engine’s SFont[victorenginescripts.wordpress.com] plugin.

But, as displayed in the screen capture below, the Chrono Engine seems to still be using RPG Maker MV’s default font.

Screen Capture[media.giphy.com]

In the last paragraph of Victor Engine’s SFont Help text, he mentions:

To add SFonts on non-window objects that uses the drawText, you have to add it manually (requires some scripting knowledge). You need to call bitmap.changeSFont(index). The index must be one of the values you setup on the plugin parameters and the bitmap must be a valid bitmap object.

The only thing I understand from this is, based on my VE_SFont.js parameters, the call would be:

bitmap.changeSFont(0)

VE_SFont Parameters[i66.tinypic.com]

But I am still not sure where in MOG_ChronoEngine.js I would place this.

A combing of Google yielded a discussion[forums.rpgmakerweb.com] on the rpgmakerweb.com forums (from 2017), where a user named Sixth[forums.rpgmakerweb.com] shed a little more insight on the matter:

It is actually very easy to change the draw methods in every script. If something is using the default draw method for texts, that will use either the draw_text or draw_text_ex method. The only thing you need to do is to search for these methods in your custom scripts and replace them with the drawing method from Victor's script. You have to set the correct argument values at the correct argument positions, but aside from that, it is not much of a hassle to do.

They were discussing Victor Engine’s SFont plugin for RPG Maker VX ACE, but I thought I might look into it anyway. So I went into the MOG_ChronoEngine.js file and searched for all instances of “drawText” (without the “_”, since this is JavaScript).

I came up with the following results:


Lines 7254-7260:
//============================== // * refresh Name //============================== ToolCursor.prototype.refreshName = function(target) { this._name.bitmap.clear(); this._name.bitmap.drawText(target.battler().name(),0,0,200,48,"center") };

Lines 8926-8941:
//============================== // * draw Item Number //============================== Window_ToolSkill.prototype.drawItemNumber = function(item, x, y, width) { if (item.tool.itemCost) { var itemCost = $dataItems[item.tool.itemCost]; if (itemCost) { this.drawText(':', x, y, width - this.textWidth('00'), 'right'); this.drawText($gameParty.numItems(itemCost), x, y, width, 'right'); }; } else if (item.tool.mpCost > 0) { this.drawText(TextManager.mpA + ' ' + item.tool.mpCost, x, y, width, 'right'); } else if (item.tool.tpCost > 0) { this.drawText(TextManager.tpA + ' ' + item.tool.tpCost, x, y, width, 'right'); }; };

Lines 9183-9198:
//============================== // * draw Item Number //============================== Window_ToolList.prototype.drawItemNumber = function(item, x, y, width) { if (item.tool.itemCost) { var itemCost = $dataItems[item.tool.itemCost]; if (itemCost) { this.drawText(':', x, y, width - this.textWidth('00'), 'right'); this.drawText($gameParty.numItems(itemCost), x, y, width, 'right'); }; } else if (item.tool.mpCost > 0) { this.drawText(TextManager.mpA + ' ' + item.tool.mpCost, x, y, width, 'right'); } else if (item.tool.tpCost > 0) { this.drawText(TextManager.tpA + ' ' + item.tool.tpCost, x, y, width, 'right'); }; };

Lines 11093-11108:
//============================== // * refresh Result CR //============================== Spriteset_Map.prototype.refreshResultCR = function() { $gameTemp._chrono.victory[1] = false; this._resultCR.opacity = 0; this._resultCRExp.opacity = 0; this._resultCRGold.opacity = 0; this._resultCR.x = this._resultCR.org[0] - 50; this._resultCRExp.bitmap.clear(); this._resultCRGold.bitmap.clear() var text = $gameTemp._chrono.exp; this._resultCRExp.bitmap.drawText(text,0,0,190,32,"center"); var text = $gameTemp._chrono.gold; this._resultCRGold.bitmap.drawText(text,0,0,190,32,"center"); };


I looked in VE_SFont.js to see if I could deduce the “drawing method” that Sixth mentioned, but was not able to do so.

Based on this information, does anybody know how I can go about changing the default font that MOG_ChronoEngine.js uses?

Thanks in advance!



Last edited by PE; Mar 26, 2019 @ 3:36pm
< >
Showing 1-1 of 1 comments
PE Mar 27, 2019 @ 3:26pm 
WhiteW[forums.rpgmakerweb.com] from the rpgmakerweb.com forums solved it for me[forums.rpgmakerweb.com]-

I was overthinking. All I needed to do was change the Damage.png file in the IMG/SYSTEM folder.
Last edited by PE; Mar 27, 2019 @ 3:27pm
< >
Showing 1-1 of 1 comments
Per page: 1530 50

Date Posted: Mar 26, 2019 @ 3:29pm
Posts: 1