diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/Wandmaker.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/Wandmaker.java index 733b2d42b..663b2dbdb 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/Wandmaker.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/Wandmaker.java @@ -45,6 +45,7 @@ import com.shatteredpixel.shatteredpixeldungeon.windows.WndWandmaker; import com.watabou.noosa.Game; import com.watabou.utils.Bundle; import com.watabou.utils.Callback; +import com.watabou.utils.Point; import com.watabou.utils.Random; import java.util.ArrayList; @@ -272,9 +273,20 @@ public class Wandmaker extends NPC { questRoomSpawned = false; Wandmaker npc = new Wandmaker(); + boolean validPos; + //Do not spawn wandmaker on the entrance, or next to a door. do { + validPos = true; npc.pos = level.pointToCell(room.random()); - } while (npc.pos == level.entrance); + if (npc.pos == level.entrance){ + validPos = false; + } + for (Point door : room.connected.values()){ + if (level.adjacent( npc.pos, level.pointToCell( door ) )){ + validPos = false; + } + } + } while (!validPos); level.mobs.add( npc ); spawned = true; diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/DriedRose.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/DriedRose.java index d5e291c96..a1235223b 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/DriedRose.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/artifacts/DriedRose.java @@ -214,7 +214,17 @@ public class DriedRose extends Artifact { } else desc += "\n\n" + Messages.get(this, "desc_cursed"); } + + desc += "\n"; + + if (weapon != null){ + desc += "\n" + Messages.get(this, "desc_weapon", weapon.toString()); + } + if (armor != null){ + desc += "\n" + Messages.get(this, "desc_armor", armor.toString()); + } + return desc; } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndBag.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndBag.java index 24a262c8a..013a13218 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndBag.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndBag.java @@ -184,16 +184,6 @@ public class WndBag extends WndTabbed { protected void placeTitle( Bag bag, int width ){ - RenderedTextBlock txtTitle = PixelScene.renderTextBlock( - title != null ? Messages.titleCase(title) : Messages.titleCase( bag.name() ), 9 ); - txtTitle.hardlight( TITLE_COLOR ); - txtTitle.setPos( - 1, - (TITLE_HEIGHT - txtTitle.height()) / 2f - 1 - ); - PixelScene.align(txtTitle); - add( txtTitle ); - ItemSprite gold = new ItemSprite(ItemSpriteSheet.GOLD, null); gold.x = width - gold.width() - 1; gold.y = (TITLE_HEIGHT - gold.height())/2f - 1; @@ -207,6 +197,17 @@ public class WndBag extends WndTabbed { amt.y = (TITLE_HEIGHT - amt.baseLine())/2f - 1; PixelScene.align(amt); add(amt); + + RenderedTextBlock txtTitle = PixelScene.renderTextBlock( + title != null ? Messages.titleCase(title) : Messages.titleCase( bag.name() ), 8 ); + txtTitle.hardlight( TITLE_COLOR ); + txtTitle.maxWidth( (int)amt.x - 2 ); + txtTitle.setPos( + 1, + (TITLE_HEIGHT - txtTitle.height()) / 2f - 1 + ); + PixelScene.align(txtTitle); + add( txtTitle ); } protected void placeItems( Bag container ) { diff --git a/core/src/main/resources/com/shatteredpixel/shatteredpixeldungeon/messages/items/items.properties b/core/src/main/resources/com/shatteredpixel/shatteredpixeldungeon/messages/items/items.properties index 1c465cea6..2ac1020a4 100644 --- a/core/src/main/resources/com/shatteredpixel/shatteredpixeldungeon/messages/items/items.properties +++ b/core/src/main/resources/com/shatteredpixel/shatteredpixeldungeon/messages/items/items.properties @@ -198,6 +198,8 @@ items.artifacts.driedrose.desc=Is this the rose that the ghost mentioned before items.artifacts.driedrose.desc_no_quest=A dried aged rose that is somehow still holding together despite its age.\n\nIt seems to have some spiritual power, but you have no idea how to use it right now. items.artifacts.driedrose.desc_hint=It seems to be missing some petals. Perhaps reattaching them will strengthen the rose. items.artifacts.driedrose.desc_cursed=The cursed rose is bound to your hand, it feels eerily cold. +items.artifacts.driedrose.desc_weapon=Ghost's weapon: %s. +items.artifacts.driedrose.desc_armor=Ghost's armor: %s. items.artifacts.driedrose$petal.name=dried petal items.artifacts.driedrose$petal.no_rose=You have no rose to add this petal to. items.artifacts.driedrose$petal.no_room=There is no room left for this petal, so you discard it. @@ -1446,7 +1448,7 @@ items.weapon.melee.wornshortsword.desc=A quite short sword, worn down through he ###missile weapons items.weapon.missiles.darts.adrenalinedart.name=adrenaline dart -items.weapon.missiles.darts.adrenalinedart.desc=These darts are tipped with a swiftthistle-based compound which will give their target a boost in speed. This boost affects both speed of movement and of attacking, though movement is improved more. +items.weapon.missiles.darts.adrenalinedart.desc=These darts are tipped with a swiftthistle-based compound which will give their target a boost in speed. This boost affects both speed of movement and of attacking, though movement is improved more. The dart will itself is still harmful to enemies, but will not harm allies. items.weapon.missiles.darts.blindingdart.name=blinding dart items.weapon.missiles.darts.blindingdart.desc=These darts are tipped with a blindweed-based compound which will blind their target for a short time. They do not disorient however, so an enemy will still know where they last saw you. @@ -1469,10 +1471,10 @@ items.weapon.missiles.darts.displacingdart.name=displacing dart items.weapon.missiles.darts.displacingdart.desc=These darts are tipped with a fadeleaf-based compound which will teleport their target a short distance away. items.weapon.missiles.darts.healingdart.name=healing dart -items.weapon.missiles.darts.healingdart.desc=These darts are tipped with a sungrass-based compound which grants a burst of healing to their target. The dart itself is still harmful though. +items.weapon.missiles.darts.healingdart.desc=These darts are tipped with a sungrass-based compound which grants a burst of healing to their target. The dart will itself is still harmful to enemies, but will not harm allies. items.weapon.missiles.darts.holydart.name=holy dart -items.weapon.missiles.darts.holydart.desc=These darts are tipped with a starflower-based compound which grants a boost in power to their target. The dart itself is still harmful though. +items.weapon.missiles.darts.holydart.desc=These darts are tipped with a starflower-based compound which grants a boost in power to their target. The dart will itself is still harmful to enemies, but will not harm allies. items.weapon.missiles.darts.incendiarydart.name=incendiary dart items.weapon.missiles.darts.incendiarydart.desc=These darts are tipped with a firebloom-based compound which will burst into brilliant flames on impact.