mirror of
https://gitlab.com/phoenix-dvpmt/mmoitems.git
synced 2024-12-22 04:37:42 +01:00
I'm pretty sure that when I changed this a while back, I either messed up the loading or i forgot to fully fix this, but this should fix the issue with the cloning of the items resulting in having a bunch of element stats added to the new Statdata!
This commit is contained in:
parent
99e893801d
commit
2a7f81339e
@ -41,7 +41,13 @@ public class ElementListData implements Mergeable {
|
||||
@Override
|
||||
public StatData cloneData() {
|
||||
ElementListData ret = new ElementListData();
|
||||
stats.forEach((key, value) -> ret.stats.put(key, value));
|
||||
for (Map.Entry<Pair<Element, ElementStatType>, Double> entry : stats.entrySet()) {
|
||||
Pair<Element, ElementStatType> key = entry.getKey();
|
||||
Double value = entry.getValue();
|
||||
if (value != 0) {
|
||||
ret.stats.put(key, value);
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user