So I came across this thread here, where someone provided a little snippet that hides augments that are already slotted, effectively preventing the player from stacking augments. (Using Yanfly's AttachAugment plugin.)
At a glance this works fine. If you try to add the same augment item in another slot, it won't show it.
However, if you happen to have another slot filled with a different augment...
Trying to replace "ATK Starter" shows "MHP Starter" despite it already being used in slot 2.
This is of course an exploit that's an issue, so I'm looking for someone who could potentially fix this up.
(Here's the code for convenience.)
Thanks in advance. 😀
At a glance this works fine. If you try to add the same augment item in another slot, it won't show it.
However, if you happen to have another slot filled with a different augment...
Trying to replace "ATK Starter" shows "MHP Starter" despite it already being used in slot 2.
This is of course an exploit that's an issue, so I'm looking for someone who could potentially fix this up.
(Here's the code for convenience.)
Code:
Window_AugmentItemList.prototype.makeItemList = function() {
this._data = $gameParty.allItems().filter(function(item) {
return this.includes(item);
}, this);
if (this._item && this._item.augmentSlotItems[this._slotId] !== 'none') {
this._data.unshift(null);
}
if (this._data.length === 0) return;
alreadyAttached = this._item.augmentSlotItems;
for (i=0; i< this._data.length; i++){
if (this._data[i]) var keyWord = "item "+this._data[i].id
for (j=0; j<alreadyAttached.length; j++){
if (alreadyAttached[j] === keyWord) this._data.splice(i,1);
};
};
};
Thanks in advance. 😀