diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_e5_carbine.py b/scripts/loot/lootItems/exceptionallootchest/legendary_e5_carbine.py index 1e01cd9c..b268fcbc 100644 --- a/scripts/loot/lootItems/exceptionallootchest/legendary_e5_carbine.py +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_e5_carbine.py @@ -25,12 +25,12 @@ def requiredCL(): def itemStats(): - stats = ['mindamage','400','450'] - stats += ['maxdamage','850','900'] + stats = ['mindamage','400','400'] + stats += ['maxdamage','850','850'] stats += ['attackspeed','0.6','0.6'] stats += ['maxrange','0','50'] stats += ['damagetype','energy','energy'] - stats += ['elemtype','elemental_electricity','elemental_electricity'] + stats += ['elemtype','electricity','electricity'] stats += ['elemdamage','23','23'] stats += ['weapontype','1','1'] diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_fwg5_pistol.py b/scripts/loot/lootItems/exceptionallootchest/legendary_fwg5_pistol.py index 75f4059a..c441cd26 100644 --- a/scripts/loot/lootItems/exceptionallootchest/legendary_fwg5_pistol.py +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_fwg5_pistol.py @@ -25,12 +25,12 @@ def requiredCL(): def itemStats(): - stats = ['mindamage','250','270'] - stats += ['maxdamage','500','530'] + stats = ['mindamage','250','250'] + stats += ['maxdamage','500','500'] stats += ['attackspeed','0.4','0.4'] stats += ['maxrange','0','35'] stats += ['damagetype','energy','energy'] - stats += ['elemtype','elemental_heat','elemental_heat'] + stats += ['elemtype','heat','heat'] stats += ['elemdamage','35','35'] stats += ['weapontype','2','2'] diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_nightsister_energy_lance.py b/scripts/loot/lootItems/exceptionallootchest/legendary_nightsister_energy_lance.py index c61909e8..24e6aa4c 100644 --- a/scripts/loot/lootItems/exceptionallootchest/legendary_nightsister_energy_lance.py +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_nightsister_energy_lance.py @@ -25,12 +25,12 @@ def requiredCL(): def itemStats(): - stats = ['mindamage','750','800'] - stats += ['maxdamage','1100','1200'] + stats = ['mindamage','800','800'] + stats += ['maxdamage','1200','1200'] stats += ['attackspeed','1.0','1.0'] stats += ['maxrange','0','5'] stats += ['damagetype','energy','energy'] - stats += ['elemtype','elemental_electricity','elemental_electricity'] + stats += ['elemtype','electricity','electricity'] stats += ['elemdamage','50','50'] stats += ['weapontype','7','7'] diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_power_hammer.py b/scripts/loot/lootItems/exceptionallootchest/legendary_power_hammer.py index 6d005e80..a05de2b3 100644 --- a/scripts/loot/lootItems/exceptionallootchest/legendary_power_hammer.py +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_power_hammer.py @@ -25,12 +25,12 @@ def requiredCL(): def itemStats(): - stats = ['mindamage','850','900'] - stats += ['maxdamage','1250','1350'] + stats = ['mindamage','900','900'] + stats += ['maxdamage','1350','1350'] stats += ['attackspeed','1.0','1.0'] stats += ['maxrange','0','5'] stats += ['damagetype','energy','energy'] - stats += ['elemtype','elemental_acid','elemental_acid'] + stats += ['elemtype','acid','acid'] stats += ['elemdamage','20','20'] stats += ['weapontype','5','5'] diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_stun_baton.py b/scripts/loot/lootItems/exceptionallootchest/legendary_stun_baton.py index d5b7f390..5e9556aa 100644 --- a/scripts/loot/lootItems/exceptionallootchest/legendary_stun_baton.py +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_stun_baton.py @@ -25,12 +25,12 @@ def requiredCL(): def itemStats(): - stats = ['mindamage','550','600'] - stats += ['maxdamage','1250','1300'] + stats = ['mindamage','600','600'] + stats += ['maxdamage','1300','1300'] stats += ['attackspeed','1.0','1.0'] stats += ['maxrange','0','5'] stats += ['damagetype','energy','energy'] - stats += ['elemtype','elemental_electricity','elemental_electricity'] + stats += ['elemtype','electricity','electricity'] stats += ['elemdamage','75','75'] stats += ['weapontype','5','5'] diff --git a/scripts/loot/lootItems/exceptionallootchest/legendary_t21_rifle.py b/scripts/loot/lootItems/exceptionallootchest/legendary_t21_rifle.py index 16fd22cf..e84cf910 100644 --- a/scripts/loot/lootItems/exceptionallootchest/legendary_t21_rifle.py +++ b/scripts/loot/lootItems/exceptionallootchest/legendary_t21_rifle.py @@ -25,12 +25,12 @@ def requiredCL(): def itemStats(): - stats = ['mindamage','500','550'] - stats += ['maxdamage','1050','1100'] + stats = ['mindamage','550','550'] + stats += ['maxdamage','1100','1100'] stats += ['attackspeed','0.8','0.8'] stats += ['maxrange','0','64'] stats += ['damagetype','energy','energy'] - stats += ['elemtype','elemental_acid','elemental_acid'] + stats += ['elemtype','acid','acid'] stats += ['elemdamage','30','30'] stats += ['weapontype','0','0'] diff --git a/scripts/loot/lootItems/rarelootchest/kowakian_cage.py b/scripts/loot/lootItems/rarelootchest/kowakian_cage.py index 810362f8..8a5c9ff6 100644 --- a/scripts/loot/lootItems/rarelootchest/kowakian_cage.py +++ b/scripts/loot/lootItems/rarelootchest/kowakian_cage.py @@ -2,3 +2,7 @@ def itemTemplate(): return ['object/tangible/event_perk/shared_lifeday_monkey_cage.iff'] # needs correct iff still + +def STFparams(): + + return ['static_item_n','item_event_lifeday_monkey_cage','static_item_d','item_event_lifeday_monkey_cage'] \ No newline at end of file diff --git a/src/services/LootService.java b/src/services/LootService.java index 27614803..ba03cbcb 100644 --- a/src/services/LootService.java +++ b/src/services/LootService.java @@ -76,7 +76,7 @@ public class LootService implements INetworkDispatch { private NGECore core; private static int prepInvCnt = 0; String testDropTemplate = null; - //String testDropTemplate = "composite_armor_bracer_left"; + //String testDropTemplate = "kowakian_cage"; public LootService(NGECore core) { this.core = core; @@ -1762,14 +1762,20 @@ public class LootService implements INetworkDispatch { if (statName.equals("mindamage")){ int minimalValue = (int) Integer.parseInt(minValue); int maximalValue = (int) Integer.parseInt(maxValue); - int randomValue = minimalValue + new Random().nextInt(maximalValue-minimalValue); + int extra = 0; + if (maximalValue>minimalValue) + extra = new Random().nextInt(maximalValue-minimalValue); + int randomValue = minimalValue + extra; weapon.setMinDamage(randomValue); } if (statName.equals("maxdamage")){ int minimalValue = (int) Integer.parseInt(minValue); int maximalValue = (int) Integer.parseInt(maxValue); - int randomValue = minimalValue + new Random().nextInt(maximalValue-minimalValue); + int extra = 0; + if (maximalValue>minimalValue) + extra = new Random().nextInt(maximalValue-minimalValue); + int randomValue = minimalValue + extra; weapon.setMaxDamage(randomValue); }