mirror of
https://gitlab.com/phoenix-dvpmt/mmoitems.git
synced 2025-03-11 13:11:50 +01:00
Fixes Stacking of Elements' Double Values - Noticed during fix of Elements tag testing!
This commit is contained in:
parent
d4a30f90f6
commit
c750355383
@ -33,7 +33,8 @@ public class ElementListData implements Mergeable {
|
||||
public void merge(StatData data) {
|
||||
Validate.isTrue(data instanceof ElementListData, "Cannot merge two different stat data types");
|
||||
ElementListData extra = (ElementListData) data;
|
||||
extra.stats.forEach((key, value) -> stats.put(key, value));
|
||||
//Includes old values if any, fixes stacking of element double values I believe - Kilo
|
||||
extra.stats.forEach((key, value) -> stats.put(key, value + stats.getOrDefault(key,0.0)));
|
||||
}
|
||||
|
||||
@NotNull
|
||||
|
Loading…
Reference in New Issue
Block a user