So to cut down on window size where there’s only 2 out of 5 weapon types available per character, I wonder if there’s supposed to be a line of code that skips the unavailable weapon types.
Olivia Weapon Swap: Hide Unequippable Weapon Types
Javascript/Plugin SupportI don't know if you can change that, but I can tell you this is intentional, seeing as it's directly based off how Octopath Traveller does it.
I have tried this code:
As a replacement to the original lines from 813 onwards and I got this error:
js/plugins/Olivia_WeaponSwap.js:816 Uncaught SyntaxError: Unexpected token this
Code:
Olivia.OctoBattle.Weapon.___Window_EquipWtype_isEnabled___ = Window_EquipSlot.prototype.isEnabled;
Window_EquipSlot.prototype.isEnabled = function(index) {
if (index < 2) {
if this._actor.isEquipWtypeOk(1);
index += 1;
if this._actor.isEquipWtypeOk(2);
index += 1;
if this._actor.isEquipWtypeOk(3);
index += 1;
if this._actor.isEquipWtypeOk(4);
index += 1;
if this._actor.isEquipWtypeOk(5);
index += 1;
if this._actor.isEquipWtypeOk(6);
index += 1;
} else {
return Olivia.OctoBattle.Weapon.___Window_EquipSlot_isEnabled___.call(this, index);
}
};
As a replacement to the original lines from 813 onwards and I got this error:
js/plugins/Olivia_WeaponSwap.js:816 Uncaught SyntaxError: Unexpected token this
You really ought to check your if statements syntax. it's
You're doing
I don't know why you thought that syntax would work, but the program is telling you it expects a "(condition)" not a "this.something" after your if statement.
No idea if your code would work, I don't have access to olivia's plugins.
Code:
if (condition) {effect}
You're doing
Code:
if condition
effect
I don't know why you thought that syntax would work, but the program is telling you it expects a "(condition)" not a "this.something" after your if statement.
No idea if your code would work, I don't have access to olivia's plugins.
Would I be better off just making this as a paid request?
Original thread: https://forums.rpgmakerweb.com/threads/olivia-weapon-swap-hide-unequippable-weapon-types.108810/