mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-27 05:02:56 +00:00
Cleanup Damage Handling Logic for CNPC+ and DBC Addon for better readability / context. Added Magic Data Support to Abilities
This commit is contained in:
1 parent
c3096b320e
commit
d9f100d245
12 files changed
+604
-13
No files matched your search
@@ -76,4 +76,15 @@ public class MagicData implements IMagicData {
|
||||
MagicEntry entry = magics.get(id);
|
||||
return entry == null ? 0 : entry.split;
|
||||
}
|
||||
|
||||
public MagicData copy() {
|
||||
MagicData copy = new MagicData();
|
||||
for (java.util.Map.Entry<Integer, MagicEntry> e : magics.entrySet()) {
|
||||
MagicEntry entryCopy = new MagicEntry();
|
||||
entryCopy.damage = e.getValue().damage;
|
||||
entryCopy.split = e.getValue().split;
|
||||
copy.magics.put(e.getKey(), entryCopy);
|
||||
}
|
||||
return copy;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user