Попросили сделать подобное для MZ.
Под него еще не писал, но нашел в Light Crusader адаптацию под MV.
Код:
//=============================================================================
// CustomGraphicChange.js
//=============================================================================
/*
* @plugindesc Сhange graphic on event
* @author Caveman
*
* @help This plugin provides possibility to change graphic on events as it was in XP
*
* params:
# characterIndex - pos in big charset file
# name - charset name
# direction - turn (row in charset): 2,4,6,8
# pattern - pos (col in charset): 0,1,2
functions:
- setGraphicName(name, direction, pattern)
- setGraphic(direction, pattern)
- setIndexGraphicName(name, characterIndex, direction, pattern)
- setIndexGraphic(characterIndex, direction, pattern)
use in 'custom route' or 'set move route' as
this.setGraphic ...
*/
(function() {
Game_CharacterBase.prototype.setGraphicName = function(name, direction, pattern) {
this._characterName = name;
this.setGraphic(direction, pattern);
};
Game_CharacterBase.prototype.setGraphic = function(direction, pattern) {
this._direction = direction;
this._pattern = pattern;
this._originalPattern = pattern
};
Game_CharacterBase.prototype.setIndexGraphicName = function(name, characterIndex, direction, pattern) {
this._characterName = name;
this.setIndexGraphic(characterIndex, direction, pattern);
};
Game_CharacterBase.prototype.setIndexGraphic = function(characterIndex, direction, pattern) {
this._characterIndex = characterIndex;
this._direction = direction;
this._pattern = pattern;
this._originalPattern = pattern;
};
})();
Социальные закладки