From 30826c49f05309388d302d1b96b4aef4138f08f3 Mon Sep 17 00:00:00 2001 From: Evan Debenham Date: Sun, 12 Aug 2018 16:36:03 -0400 Subject: [PATCH] v0.7.0: adjusted droprates. Bombs down, runestones slightly up --- .../shatteredpixeldungeon/items/bombs/Bomb.java | 9 +++++---- .../levels/rooms/secret/SecretHoneypotRoom.java | 7 +------ .../levels/rooms/special/LaboratoryRoom.java | 2 +- .../levels/rooms/special/RunestoneRoom.java | 2 +- .../levels/rooms/special/ShopRoom.java | 11 +++++------ 5 files changed, 13 insertions(+), 18 deletions(-) diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/Bomb.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/Bomb.java index 3e13ba802..307b3bc99 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/Bomb.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/bombs/Bomb.java @@ -23,6 +23,7 @@ package com.shatteredpixel.shatteredpixeldungeon.items.bombs; import com.shatteredpixel.shatteredpixeldungeon.Assets; import com.shatteredpixel.shatteredpixeldungeon.Dungeon; +import com.shatteredpixel.shatteredpixeldungeon.SPDSettings; import com.shatteredpixel.shatteredpixeldungeon.ShatteredPixelDungeon; import com.shatteredpixel.shatteredpixeldungeon.actors.Actor; import com.shatteredpixel.shatteredpixeldungeon.actors.Char; @@ -42,6 +43,7 @@ import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfRage; import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfRecharging; import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfRemoveCurse; import com.shatteredpixel.shatteredpixeldungeon.items.stones.Runestone; +import com.shatteredpixel.shatteredpixeldungeon.messages.Languages; import com.shatteredpixel.shatteredpixeldungeon.messages.Messages; import com.shatteredpixel.shatteredpixeldungeon.plants.Plant; import com.shatteredpixel.shatteredpixeldungeon.scenes.GameScene; @@ -187,12 +189,11 @@ public class Bomb extends Item { @Override public Item random() { - switch(Random.Int( 2 )){ + switch(Random.Int( 4 )){ case 0: + return new DoubleBomb(); default: return this; - case 1: - return new DoubleBomb(); } } @@ -288,7 +289,7 @@ public class Bomb extends Item { bomb.quantity(2); if (bomb.doPickUp(hero)) { //isaaaaac.... (don't bother doing this when not in english) - if (Messages.get(this, "name").equals("two bombs")) + if (SPDSettings.language() == Languages.ENGLISH) hero.sprite.showStatus(CharSprite.NEUTRAL, "1+1 free!"); return true; } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/secret/SecretHoneypotRoom.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/secret/SecretHoneypotRoom.java index 4d5aed046..44a54dbed 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/secret/SecretHoneypotRoom.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/secret/SecretHoneypotRoom.java @@ -30,7 +30,6 @@ import com.shatteredpixel.shatteredpixeldungeon.levels.Level; import com.shatteredpixel.shatteredpixeldungeon.levels.Terrain; import com.shatteredpixel.shatteredpixeldungeon.levels.painters.Painter; import com.watabou.utils.Point; -import com.watabou.utils.Random; public class SecretHoneypotRoom extends SecretRoom { @@ -58,11 +57,7 @@ public class SecretHoneypotRoom extends SecretRoom { placeItem(new Honeypot(), level); - placeItem( Random.Int(3) == 0 ? new Bomb.DoubleBomb() : new Bomb(), level); - - if (Random.Int(2) == 0){ - placeItem( new Bomb(), level); - } + placeItem( new Bomb().random(), level); entrance().set(Door.Type.HIDDEN); } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/LaboratoryRoom.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/LaboratoryRoom.java index 038bbfd2c..2e3a83984 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/LaboratoryRoom.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/LaboratoryRoom.java @@ -65,7 +65,7 @@ public class LaboratoryRoom extends SpecialRoom { alchemy.seed( level, pot.x + level.width() * pot.y, chapter*10 + Random.IntRange(0, 20) ); level.blobs.put( Alchemy.class, alchemy ); - int n = Random.NormalIntRange( 1, 3 ); + int n = Random.NormalIntRange( 2, 3 ); for (int i=0; i < n; i++) { int pos; do { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/RunestoneRoom.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/RunestoneRoom.java index e20a13bcc..2ef323278 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/RunestoneRoom.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/RunestoneRoom.java @@ -42,7 +42,7 @@ public class RunestoneRoom extends SpecialRoom { Painter.drawInside( level, this, entrance(), 2, Terrain.EMPTY_SP); Painter.fill( level, this, 2, Terrain.EMPTY ); - int n = Random.NormalIntRange(2, 3); + int n = Random.NormalIntRange(2, 4); int dropPos; for (int i = 0; i < n; i++) { do { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/ShopRoom.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/ShopRoom.java index 1208523b9..5e520d9cc 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/ShopRoom.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/special/ShopRoom.java @@ -229,17 +229,16 @@ public class ShopRoom extends SpecialRoom { itemsToSpawn.add( new SmallRation() ); itemsToSpawn.add( new SmallRation() ); - - itemsToSpawn.add( new Bomb().random() ); - switch (Random.Int(5)){ - case 1: + + switch (Random.Int(4)){ + case 0: itemsToSpawn.add( new Bomb() ); break; + case 1: case 2: - itemsToSpawn.add( new Bomb().random() ); + itemsToSpawn.add( new Bomb.DoubleBomb() ); break; case 3: - case 4: itemsToSpawn.add( new Honeypot() ); break; }