Code:
Window_PartySelect.prototype.processPageup = function() {
*code
}
Code:
Window_PartyList.prototype.processPageup = function() {
*code
}
I am editing the Yanfly_PartySystem-Plugin.
The Code below is probably the reason why the Window_PartySelect function works, because when I entered "//" before the pageUp and PageDown bindings the Window_PartySelect.prototype.processPageup = function() stopped working.
Code:
Scene_Party.prototype.createPartyWindow = function() {
this._partyWindow = new Window_PartySelect(this._commandWindow);
if (this._helpWindow) this._partyWindow.setHelpWindow(this._helpWindow);
this._partyWindow.setHandler('ok', this.onPartyOk.bind(this));
this._partyWindow.setHandler('cancel', this.onPartyCancel.bind(this));
this._partyWindow.setHandler('pageup', this.onPartyPageUp.bind(this));
this._partyWindow.setHandler('pagedown', this.onPartyPageDown.bind(this));
this.addWindow(this._partyWindow);
};
The following Code is necessary, too:
Code:
Scene_Party.prototype.onPartyPageUp = function() {
}
Scene_Party.prototype.onPartyPageDown = function() {
}
And the following Code fixes my problem! 🙂:
Code:
Scene_Party.prototype.createListWindow = function() {
this._listWindow = new Window_PartyList(this._partyWindow);
if (this._helpWindow) this._listWindow.setHelpWindow(this._helpWindow);
this._listWindow.setHandler('ok', this.onListOk.bind(this));
this._listWindow.setHandler('cancel', this.onListCancel.bind(this));
this._listWindow.setHandler('pageup', this.onPartyPageUp.bind(this)); //i did this
this._listWindow.setHandler('pagedown', this.onPartyPageDown.bind(this)); // i did this
this.addWindow(this._listWindow);
};
It seems like this is the part necessary to use buttons! 🙂
this._listWindow.setHandler('pageup', this.onPartyPageUp.bind(this));
this._listWindow.setHandler('pagedown', this.onPartyPageDown.bind(this));