diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java index 7907aab72..10e5d77f4 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/armor/Armor.java @@ -215,7 +215,7 @@ public class Armor extends EquipableItem { public Item upgrade( boolean inscribe ) { if (glyph != null) { - if (!inscribe && Random.Int( level() ) > 0) { + if (!inscribe && Random.Float() > Math.pow(0.9, level())) { GLog.w( Messages.get(Armor.class, "incompatible") ); inscribe( null ); } diff --git a/src/com/shatteredpixel/shatteredpixeldungeon/items/weapon/Weapon.java b/src/com/shatteredpixel/shatteredpixeldungeon/items/weapon/Weapon.java index 16703423b..b5b01da41 100644 --- a/src/com/shatteredpixel/shatteredpixeldungeon/items/weapon/Weapon.java +++ b/src/com/shatteredpixel/shatteredpixeldungeon/items/weapon/Weapon.java @@ -180,7 +180,7 @@ abstract public class Weapon extends KindOfWeapon { public Item upgrade( boolean enchant ) { if (enchantment != null) { - if (!enchant && Random.Int( level() ) > 0) { + if (!enchant && Random.Float() > Math.pow(0.9, level())) { GLog.w( Messages.get(Weapon.class, "incompatible") ); enchant( null ); }