diff --git a/core/src/main/assets/messages/actors/actors.properties b/core/src/main/assets/messages/actors/actors.properties index f7801a12c..1db3abaa3 100644 --- a/core/src/main/assets/messages/actors/actors.properties +++ b/core/src/main/assets/messages/actors/actors.properties @@ -339,43 +339,47 @@ actors.hero.abilities.armorability.prompt=Choose a location to target actors.hero.abilities.warrior.heroicleap.name=heroic leap actors.hero.abilities.warrior.heroicleap.prompt=Choose direction to leap -actors.hero.abilities.warrior.heroicleap.short_desc=The Warrior performs a heroic leap towards a targeted location, slamming down to stun all neighbouring enemies. Consumes 35 charge. -actors.hero.abilities.warrior.heroicleap.desc=I haven't decided on this ability yet. +actors.hero.abilities.warrior.heroicleap.short_desc=The Warrior performs a _Heroic Leap_ towards a targeted location, slamming down to stun all neighbouring enemies. +actors.hero.abilities.warrior.heroicleap.desc=TODO actors.hero.abilities.warrior.shockwave.name=shockwave -actors.hero.abilities.warrior.shockwave.short_desc=The Warrior slams the ground and releases a shockwave in a conical AOE. Enemies caught in the shockwave are damaged and crippled. Consumes 35 energy. -actors.hero.abilities.warrior.shockwave.desc=I haven't decided on this ability yet. -actors.hero.abilities.warrior.warrior3.name=??? -actors.hero.abilities.warrior.warrior3.short_desc=I haven't decided on this ability yet. -actors.hero.abilities.warrior.warrior3.desc=I haven't decided on this ability yet. +actors.hero.abilities.warrior.shockwave.short_desc=The Warrior releases a _Shockwave_ in a conical AOE by slamming the ground. Enemies caught in the shockwave are damaged and crippled. +actors.hero.abilities.warrior.shockwave.desc=TODO +actors.hero.abilities.warrior.endure.name=endure +actors.hero.abilities.warrior.endure.short_desc=The Warrior _Endures_, skipping several turns but gaining high damage resistance. He then deals bonus damage based on what he endured. +actors.hero.abilities.warrior.endure.desc=TODO actors.hero.abilities.mage.elementalblast.name=elemental blast -actors.hero.abilities.mage.elementalblast.short_desc=TODO -actors.hero.abilities.mage.elementalblast.desc=I haven't decided on this ability yet. -actors.hero.abilities.mage.mage2.name=??? -actors.hero.abilities.mage.mage2.short_desc=I haven't decided on this ability yet. -actors.hero.abilities.mage.mage2.desc=I haven't decided on this ability yet. -actors.hero.abilities.mage.mage3.name=??? -actors.hero.abilities.mage.mage3.short_desc=I haven't decided on this ability yet. -actors.hero.abilities.mage.mage3.desc=I haven't decided on this ability yet. +actors.hero.abilities.mage.elementalblast.short_desc=The Mage emits an _Elemental Blast_ from his staff, covering a large area around him in an effect that varies based on the wand in his staff. +actors.hero.abilities.mage.elementalblast.desc=TODO +actors.hero.abilities.mage.wildmagic.name=wild magic +actors.hero.abilities.mage.wildmagic.short_desc=The Mage unleashes the _Wild Magic_ contained in his wands, randomly firing them multiple times at a chosen target over a single turn. +actors.hero.abilities.mage.wildmagic.desc=TODO +actors.hero.abilities.mage.magicalchains.name=magical chains +actors.hero.abilities.mage.magicalchains.short_desc=The Mage throws out _Magical Chains_, which affect every enemy he has used magic on recently. +actors.hero.abilities.mage.magicalchains.desc=TODO actors.hero.abilities.rogue.smokebomb.name=smoke bomb actors.hero.abilities.rogue.smokebomb.fov=You can only jump to an empty location in your field of view actors.hero.abilities.rogue.smokebomb.prompt=Choose a location to jump to -actors.hero.abilities.rogue.smokebomb.short_desc=The Rogue blinks to any nearby location which he can see, leaving a plume of smoke where he stood. This ability makes the rogue temporarily invisible, and blinds any enemies adjacent to his old location. Consumes 35 charge. +actors.hero.abilities.rogue.smokebomb.short_desc=The Rogue throws down a _Smoke Bomb_ while blinking away. He becomes temporarily invisible and blinds enemies near his old location. actors.hero.abilities.rogue.smokebomb.desc=TODO -actors.hero.abilities.rogue.rogue2.name=??? -actors.hero.abilities.rogue.rogue2.short_desc=I haven't decided on this ability yet. -actors.hero.abilities.rogue.rogue2.desc=TODO -actors.hero.abilities.rogue.rogue3.name=??? -actors.hero.abilities.rogue.rogue3.short_desc=I haven't decided on this ability yet. -actors.hero.abilities.rogue.rogue3.desc=TODO +actors.hero.abilities.rogue.deathmark.name=death mark +actors.hero.abilities.rogue.deathmark.short_desc=The Rogue places a _Death Mark_ on a chosen enemy. Marked enemies take bonus damage, but cannot die until the mark ends. +actors.hero.abilities.rogue.deathmark.desc=TODO +actors.hero.abilities.rogue.shadowclone.name=shadow clone +actors.hero.abilities.rogue.shadowclone.short_desc=The Rogue summons a _Shadow Clone_, which is frail, but can be directed and deals damage based on his weapon. +actors.hero.abilities.rogue.shadowclone.desc=TODO actors.hero.abilities.huntress.spectralblades.name=spectral blades -actors.hero.abilities.huntress.spectralblades.short_desc=The Huntress throws a spectral blade at a target, inflicting damage depending on her currently equipped melee weapon. Consumes 35 charge. +actors.hero.abilities.huntress.spectralblades.short_desc=The Huntress throws a _Spectral Blade_ at a target, inflicting damage depending on her currently equipped melee weapon. actors.hero.abilities.huntress.spectralblades.desc=TODO -actors.hero.abilities.huntress.huntress2.name=??? -actors.hero.abilities.huntress.huntress2.short_desc=I haven't decided on this ability yet. -actors.hero.abilities.huntress.huntress2.desc=TODO -actors.hero.abilities.huntress.huntress3.name=??? -actors.hero.abilities.huntress.huntress3.short_desc=I haven't decided on this ability yet. -actors.hero.abilities.huntress.huntress3.desc=TODO +actors.hero.abilities.huntress.naturesstrength.name=Nature's Strength +actors.hero.abilities.huntress.naturesstrength.short_desc=The Huntress calls upon _Nature's Strength_ to empower her, increasing her movement speed and her bow's rate of fire for a short time. +actors.hero.abilities.huntress.naturesstrength.desc=TODO +actors.hero.abilities.huntress.spirithawk.name=spirit hawk +actors.hero.abilities.huntress.spirithawk.short_desc=The Huntress summons a _Spirit Hawk_ familiar, which can help her scout locations and distract enemies. +actors.hero.abilities.huntress.spirithawk.desc=TODO + +actors.hero.abilities.ratmogrify.name=ratmogrify +actors.hero.abilities.ratmogrify.short_desc=The hero _ratmogrifies_ an enemy! This temporarily turns them into a rat with weakened attack power and no abilities. +actors.hero.abilities.ratmogrify.desc=TODO actors.hero.hero.name=you actors.hero.hero.leave=You can't leave yet, the rest of the dungeon awaits below! @@ -517,7 +521,7 @@ actors.hero.talent.wand_preservation.desc=_+1:_ When the Mage imbues a new wand actors.hero.talent.arcane_vision.title=arcane vision actors.hero.talent.arcane_vision.desc=_+1:_ When the Mage zaps an enemy, he gains mind vision on them for _10 turns_.\n\n_+2:_ When the Mage zaps an enemy, he gains mind vision on them for _15 turns_. actors.hero.talent.shield_battery.title=shield battery -actors.hero.talent.shield_battery.desc=_+1:_ The Mage can self-target with a wand to convert its charges into shielding at a rate of _5% max HP per charge_.\n\n_+2:_ The Mage can self-target with a wand to convert its charges into shielding at a rate of _7.5% max HP per charge_. +actors.hero.talent.shield_battery.desc=_+1:_ The Mage can self-target with a wand to convert all of its charges into shielding at a rate of _5% max HP per charge_.\n\n_+2:_ The Mage can self-target with a wand to convert all of its charges into shielding at a rate of _7.5% max HP per charge_. actors.hero.talent.empowering_scrolls.title=empowering scrolls actors.hero.talent.empowering_scrolls.desc=_+1:_ When the Mage reads a scroll, his next wand zap will get _+1 level_.\n\n_+2:_ When the Mage reads a scroll, his next wand zap will get _+2 levels_.\n\n_+3:_ When the Mage reads a scroll, his next wand zap will get _+3 levels_. @@ -746,6 +750,13 @@ actors.mobs.npcs.ratking.name=rat king actors.mobs.npcs.ratking.not_sleeping=I'm not sleeping! actors.mobs.npcs.ratking.what_is_it=What is it? I have no time for this nonsense. My kingdom won't rule itself! actors.mobs.npcs.ratking.confused=Wha... Where am I? My kingdom needs me! +actors.mobs.npcs.ratking.crown_clothes=Put some clothes on! You're in no state to talk to royalty! +actors.mobs.npcs.ratking.crown_desc=Oooh, is that crown for me!? It looks much shinier than mine, so I graciously accept!\n\nIn fact, I think I can offer you something as a reward for this crown. A tremendous power befitting a hero such as yourself! Would you like that? +actors.mobs.npcs.ratking.crown_yes=Of course! +actors.mobs.npcs.ratking.crown_no=I'm not so sure... +actors.mobs.npcs.ratking.crown_thankyou=Hehehe, thank you! Now go and make your king proud! +actors.mobs.npcs.ratking.crown_fine=Fine! It's not like I wanted it anyway... +actors.mobs.npcs.ratking.crown_after=Enjoying your new armor? No take-backsies! actors.mobs.npcs.ratking.desc_festive=This rat is a little bigger than a regular marsupial rat. It's wearing a tiny festive hat instead of its usual crown. Happy Holidays! actors.mobs.npcs.ratking.desc=This rat is a little bigger than a regular marsupial rat and it's wearing a tiny crown on its head. diff --git a/core/src/main/assets/messages/items/items.properties b/core/src/main/assets/messages/items/items.properties index a0c267e07..7938be8e4 100644 --- a/core/src/main/assets/messages/items/items.properties +++ b/core/src/main/assets/messages/items/items.properties @@ -101,15 +101,15 @@ items.armor.classarmor.low_charge=The armor does not have enough charge to use i items.armor.clotharmor.name=cloth armor items.armor.clotharmor.desc=This lightweight armor offers basic protection. -items.armor.huntressarmor.name=huntress cloak +items.armor.huntressarmor.name=hero's cloak items.armor.huntressarmor.no_enemies=No enemies in sight -items.armor.huntressarmor.desc=... . While wearing this cloak, the Huntress can perform a special ability: +items.armor.huntressarmor.desc=While wearing this cloak, the Huntress can perform a special ability: items.armor.leatherarmor.name=leather armor items.armor.leatherarmor.desc=Armor made from tanned monster hide. Not as light as cloth armor but provides better protection. -items.armor.magearmor.name=mage robe -items.armor.magearmor.desc=... . While wearing this gorgeous robe, the Mage can perform a special ability: +items.armor.magearmor.name=hero's robe +items.armor.magearmor.desc=While wearing this gorgeous robe, the Mage can perform a special ability: items.armor.mailarmor.name=mail armor items.armor.mailarmor.desc=Interlocking metal links make for a tough but flexible suit of armor. @@ -117,14 +117,14 @@ items.armor.mailarmor.desc=Interlocking metal links make for a tough but flexibl items.armor.platearmor.name=plate armor items.armor.platearmor.desc=Enormous plates of metal are joined together into a suit that provides unmatched protection to any adventurer strong enough to bear its staggering weight. -items.armor.roguearmor.name=rogue garb -items.armor.roguearmor.desc=... . When wearing this dark garb, the Rogue can perform a special ability: +items.armor.roguearmor.name=hero's garb +items.armor.roguearmor.desc=When wearing this dark garb, the Rogue can perform a special ability: items.armor.scalearmor.name=scale armor items.armor.scalearmor.desc=The metal scales sewn onto a leather vest create a flexible, yet protective armor. -items.armor.warriorarmor.name=warrior suit of armor -items.armor.warriorarmor.desc=... . While this armor looks heavy, it allows the Warrior to perform a special ability: +items.armor.warriorarmor.name=hero's armor +items.armor.warriorarmor.desc=While this armor looks heavy, it allows the Warrior to perform a special ability: @@ -1678,6 +1678,7 @@ items.kingscrown.name=Dwarf King's crown items.kingscrown.ac_wear=WEAR items.kingscrown.naked=Unfortunately, the crown cannot transform your underwear. items.kingscrown.upgraded=The crown glows brightly and then disintegrates as your armor transforms! +items.kingscrown.ratgraded=Rat King's hands glow brightly as your armor transforms! items.kingscrown.desc=The crown of the last dwarven king, it glows with tremendous magical energy.\n\nWhen worn, the crown's magic will flow into the armor you're currently wearing, transforming it into a _unique epic armor with special abilities._ The new armor will keep all the properties of the original armor. items.merchantsbeacon.name=merchant's beacon diff --git a/core/src/main/assets/sprites/ratking.png b/core/src/main/assets/sprites/ratking.png index 3938b183d..b99848b3f 100644 Binary files a/core/src/main/assets/sprites/ratking.png and b/core/src/main/assets/sprites/ratking.png differ diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/HeroClass.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/HeroClass.java index 446356948..db259d148 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/HeroClass.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/HeroClass.java @@ -27,18 +27,18 @@ import com.shatteredpixel.shatteredpixeldungeon.Challenges; import com.shatteredpixel.shatteredpixeldungeon.Dungeon; import com.shatteredpixel.shatteredpixeldungeon.QuickSlot; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; -import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.huntress.Huntress2; -import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.huntress.Huntress3; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.huntress.NaturesStrength; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.huntress.SpiritHawk; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.huntress.SpectralBlades; -import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.mage.Mage2; -import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.mage.Mage3; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.mage.WildMagic; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.mage.MagicalChains; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.mage.ElementalBlast; -import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.rogue.Rogue2; -import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.rogue.Rogue3; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.rogue.DeathMark; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.rogue.ShadowClone; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.rogue.SmokeBomb; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.warrior.HeroicLeap; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.warrior.Shockwave; -import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.warrior.Warrior3; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.warrior.Endure; import com.shatteredpixel.shatteredpixeldungeon.items.BrokenSeal; import com.shatteredpixel.shatteredpixeldungeon.items.Item; import com.shatteredpixel.shatteredpixeldungeon.items.Waterskin; @@ -211,13 +211,13 @@ public enum HeroClass { public ArmorAbility[] armorAbilities(){ switch (this) { case WARRIOR: default: - return new ArmorAbility[]{new HeroicLeap(), new Shockwave(), new Warrior3()}; + return new ArmorAbility[]{new HeroicLeap(), new Shockwave(), new Endure()}; case MAGE: - return new ArmorAbility[]{new ElementalBlast(), new Mage2(), new Mage3()}; + return new ArmorAbility[]{new ElementalBlast(), new WildMagic(), new MagicalChains()}; case ROGUE: - return new ArmorAbility[]{new SmokeBomb(), new Rogue2(), new Rogue3()}; + return new ArmorAbility[]{new SmokeBomb(), new DeathMark(), new ShadowClone()}; case HUNTRESS: - return new ArmorAbility[]{new SpectralBlades(), new Huntress2(), new Huntress3()}; + return new ArmorAbility[]{new SpectralBlades(), new NaturesStrength(), new SpiritHawk()}; } } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/Ratmogrify.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/Ratmogrify.java new file mode 100644 index 000000000..ab964f003 --- /dev/null +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/Ratmogrify.java @@ -0,0 +1,18 @@ +package com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities; + +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; +import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; + +public class Ratmogrify extends ArmorAbility { + + @Override + protected void activate(ClassArmor armor, Hero hero, Integer target) { + //TODO + } + + @Override + public Talent[] talents() { + return new Talent[]{ Talent.RK_1, Talent.RK_2, Talent.RK_3, Talent.HEROIC_ENERGY}; + } +} diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/Huntress2.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/NaturesStrength.java similarity index 96% rename from core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/Huntress2.java rename to core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/NaturesStrength.java index 91714398b..fce6ab799 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/Huntress2.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/NaturesStrength.java @@ -26,7 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; -public class Huntress2 extends ArmorAbility { +public class NaturesStrength extends ArmorAbility { @Override protected void activate(ClassArmor armor, Hero hero, Integer target) { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/Huntress3.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/SpiritHawk.java similarity index 96% rename from core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/Huntress3.java rename to core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/SpiritHawk.java index 4a0d363af..3c35fc3f2 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/Huntress3.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/huntress/SpiritHawk.java @@ -26,7 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; -public class Huntress3 extends ArmorAbility { +public class SpiritHawk extends ArmorAbility { @Override protected void activate(ClassArmor armor, Hero hero, Integer target) { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/Mage3.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/MagicalChains.java similarity index 96% rename from core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/Mage3.java rename to core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/MagicalChains.java index 893e33b95..c8a90e2c9 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/Mage3.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/MagicalChains.java @@ -26,7 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; -public class Mage3 extends ArmorAbility { +public class MagicalChains extends ArmorAbility { @Override protected void activate(ClassArmor armor, Hero hero, Integer target) { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/Mage2.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/WildMagic.java similarity index 96% rename from core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/Mage2.java rename to core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/WildMagic.java index 8da04487d..773242f19 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/Mage2.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/mage/WildMagic.java @@ -26,7 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; -public class Mage2 extends ArmorAbility { +public class WildMagic extends ArmorAbility { @Override protected void activate(ClassArmor armor, Hero hero, Integer target) { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/Rogue2.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/DeathMark.java similarity index 96% rename from core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/Rogue2.java rename to core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/DeathMark.java index f6eacf97b..d883cb3cb 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/Rogue2.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/DeathMark.java @@ -26,7 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; -public class Rogue2 extends ArmorAbility { +public class DeathMark extends ArmorAbility { @Override protected void activate(ClassArmor armor, Hero hero, Integer target) { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/Rogue3.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/ShadowClone.java similarity index 96% rename from core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/Rogue3.java rename to core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/ShadowClone.java index c2b700223..a93e8ae84 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/Rogue3.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/rogue/ShadowClone.java @@ -26,7 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; -public class Rogue3 extends ArmorAbility { +public class ShadowClone extends ArmorAbility { @Override protected void activate(ClassArmor armor, Hero hero, Integer target) { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/warrior/Warrior3.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/warrior/Endure.java similarity index 96% rename from core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/warrior/Warrior3.java rename to core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/warrior/Endure.java index 9e5a4d02e..a8e1bd844 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/warrior/Warrior3.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/hero/abilities/warrior/Endure.java @@ -26,7 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; -public class Warrior3 extends ArmorAbility { +public class Endure extends ArmorAbility { @Override protected void activate(ClassArmor armor, Hero hero, Integer target) { diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Rat.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Rat.java index 4be5dec80..cd9dc27b6 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Rat.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/Rat.java @@ -21,7 +21,9 @@ package com.shatteredpixel.shatteredpixeldungeon.actors.mobs; +import com.shatteredpixel.shatteredpixeldungeon.Dungeon; import com.shatteredpixel.shatteredpixeldungeon.actors.Char; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.Ratmogrify; import com.shatteredpixel.shatteredpixeldungeon.sprites.RatSprite; import com.watabou.utils.Random; @@ -35,7 +37,15 @@ public class Rat extends Mob { maxLvl = 5; } - + + @Override + protected boolean act() { + if (Dungeon.hero.armorAbility instanceof Ratmogrify){ + alignment = Alignment.NEUTRAL; + } + return super.act(); + } + @Override public int damageRoll() { return Random.NormalIntRange( 1, 4 ); diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/RatKing.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/RatKing.java index aded20d0d..244ac2a54 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/RatKing.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/mobs/npcs/RatKing.java @@ -24,8 +24,14 @@ package com.shatteredpixel.shatteredpixeldungeon.actors.mobs.npcs; import com.shatteredpixel.shatteredpixeldungeon.Dungeon; import com.shatteredpixel.shatteredpixeldungeon.actors.Char; import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Buff; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.Ratmogrify; +import com.shatteredpixel.shatteredpixeldungeon.items.KingsCrown; import com.shatteredpixel.shatteredpixeldungeon.messages.Messages; +import com.shatteredpixel.shatteredpixeldungeon.scenes.GameScene; import com.shatteredpixel.shatteredpixeldungeon.sprites.RatKingSprite; +import com.shatteredpixel.shatteredpixeldungeon.windows.WndOptions; +import com.watabou.noosa.Game; +import com.watabou.utils.Callback; public class RatKing extends NPC { @@ -103,10 +109,41 @@ public class RatKing extends NPC { return super.interact(c); } + KingsCrown crown = Dungeon.hero.belongings.getItem(KingsCrown.class); if (state == SLEEPING) { notice(); yell( Messages.get(this, "not_sleeping") ); state = WANDERING; + } else if (crown != null){ + if (Dungeon.hero.belongings.armor == null){ + yell( Messages.get(RatKing.class, "crown_clothes") ); + } else { + Game.runOnRenderThread(new Callback() { + @Override + public void call() { + GameScene.show(new WndOptions( + sprite(), + Messages.titleCase(name()), + Messages.get(RatKing.class, "crown_desc"), + Messages.get(RatKing.class, "crown_yes"), + Messages.get(RatKing.class, "crown_no") + ){ + @Override + protected void onSelect(int index) { + if (index == 0){ + crown.upgradeArmor(Dungeon.hero, Dungeon.hero.belongings.armor, new Ratmogrify()); + ((RatKingSprite)sprite).resetAnims(); + yell(Messages.get(RatKing.class, "crown_thankyou")); + } else { + yell(Messages.get(RatKing.class, "crown_fine")); + } + } + }); + } + }); + } + } else if (Dungeon.hero.armorAbility instanceof Ratmogrify) { + yell( Messages.get(RatKing.class, "crown_after") ); } else { yell( Messages.get(this, "what_is_it") ); } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/KingsCrown.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/KingsCrown.java index 6b458499f..ae2e97689 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/KingsCrown.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/KingsCrown.java @@ -26,6 +26,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.Actor; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Talent; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.Ratmogrify; import com.shatteredpixel.shatteredpixeldungeon.effects.Speck; import com.shatteredpixel.shatteredpixeldungeon.items.armor.Armor; import com.shatteredpixel.shatteredpixeldungeon.items.armor.ClassArmor; @@ -94,27 +95,31 @@ public class KingsCrown extends Item { if (armor != null){ - GLog.p(Messages.get(this, "upgraded")); + if (ability instanceof Ratmogrify){ + GLog.p(Messages.get(this, "ratgraded")); + } else { + GLog.p(Messages.get(this, "upgraded")); + } ClassArmor classArmor = ClassArmor.upgrade(hero, armor); if (hero.belongings.armor == armor) { - curUser.belongings.armor = classArmor; - ((HeroSprite) curUser.sprite).updateArmor(); - classArmor.activate(curUser); + hero.belongings.armor = classArmor; + ((HeroSprite) hero.sprite).updateArmor(); + classArmor.activate(hero); } else { - armor.detach(curUser.belongings.backpack); - classArmor.collect(curUser.belongings.backpack); + armor.detach(hero.belongings.backpack); + classArmor.collect(hero.belongings.backpack); } } hero.armorAbility = ability; Talent.initArmorTalents(hero); - - curUser.sprite.operate( curUser.pos ); + + hero.sprite.operate( hero.pos ); Sample.INSTANCE.play( Assets.Sounds.MASTERY ); } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java index 17caf1715..a24baa91a 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/items/armor/ClassArmor.java @@ -178,12 +178,11 @@ abstract public class ClassArmor extends Armor { @Override public String desc() { - //TODO descriptions for each class armor String desc = super.desc(); ArmorAbility ability = Dungeon.hero.armorAbility; if (ability != null){ - desc += "\n\n" + "_" + Messages.titleCase(ability.name()) + ":_ " + ability.desc(); + desc += "\n\n" + ability.shortDesc(); } else { desc += "\n\n" + "_" + Messages.get(this, "no_ability") + "_"; } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/SurfaceScene.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/SurfaceScene.java index 23efad2fb..4b389b64a 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/SurfaceScene.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/scenes/SurfaceScene.java @@ -25,6 +25,7 @@ import com.shatteredpixel.shatteredpixeldungeon.Assets; import com.shatteredpixel.shatteredpixeldungeon.Badges; import com.shatteredpixel.shatteredpixeldungeon.Dungeon; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.HeroClass; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.Ratmogrify; import com.shatteredpixel.shatteredpixeldungeon.items.artifacts.DriedRose; import com.shatteredpixel.shatteredpixeldungeon.items.wands.WandOfLivingEarth; import com.shatteredpixel.shatteredpixeldungeon.items.wands.WandOfWarding; @@ -75,7 +76,9 @@ public class SurfaceScene extends PixelScene { private static final int NSTARS = 100; private static final int NCLOUDS = 5; - + + private Pet[] rats; + private Camera viewport; @Override public void create() { @@ -142,7 +145,20 @@ public class SurfaceScene extends PixelScene { a.x = (SKY_WIDTH - a.width) / 2; a.y = SKY_HEIGHT - a.height; align(a); - + + if (Dungeon.hero.armorAbility instanceof Ratmogrify) { + rats = new Pet[30]; + for (int i = 0; i < rats.length; i++){ + Pet pet = new Pet(); + pet.rm = pet.gm = pet.bm = 1.2f; + pet.x = Random.Int(SKY_WIDTH)-10; + pet.y = SKY_HEIGHT - pet.height; + window.add(pet); + rats[i] = pet; + if (dayTime) pet.brightness( 1.2f ); + } + } + final Pet pet = new Pet(); pet.rm = pet.gm = pet.bm = 1.2f; pet.x = SKY_WIDTH / 2 + 2; @@ -239,7 +255,20 @@ public class SurfaceScene extends PixelScene { fadeIn(); } - + + private float ratJumpTimer = 0.02f; + @Override + public void update() { + ratJumpTimer -= Game.elapsed; + while (ratJumpTimer <= 0f){ + ratJumpTimer += 0.02f; + Random.element(rats).jump(); + } + + super.update(); + + } + @Override public void destroy() { Badges.saveGlobal(); diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/HeroSprite.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/HeroSprite.java index 949e133bc..2ccc3ded3 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/HeroSprite.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/HeroSprite.java @@ -25,9 +25,11 @@ import com.shatteredpixel.shatteredpixeldungeon.Assets; import com.shatteredpixel.shatteredpixeldungeon.Dungeon; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero; import com.shatteredpixel.shatteredpixeldungeon.actors.hero.HeroClass; +import com.shatteredpixel.shatteredpixeldungeon.scenes.GameScene; import com.watabou.gltextures.SmartTexture; import com.watabou.gltextures.TextureCache; import com.watabou.noosa.Camera; +import com.watabou.noosa.Game; import com.watabou.noosa.Image; import com.watabou.noosa.TextureFilm; import com.watabou.utils.Callback; @@ -96,7 +98,7 @@ public class HeroSprite extends CharSprite { @Override public void place( int p ) { super.place( p ); - Camera.main.panTo(center(), 5f); + if (Game.scene() instanceof GameScene) Camera.main.panTo(center(), 5f); } @Override diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/RatKingSprite.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/RatKingSprite.java index c9b706aa6..c95c100ed 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/RatKingSprite.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/sprites/RatKingSprite.java @@ -22,6 +22,9 @@ package com.shatteredpixel.shatteredpixeldungeon.sprites; import com.shatteredpixel.shatteredpixeldungeon.Assets; +import com.shatteredpixel.shatteredpixeldungeon.Dungeon; +import com.shatteredpixel.shatteredpixeldungeon.actors.Char; +import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.Ratmogrify; import com.watabou.noosa.TextureFilm; import java.util.Calendar; @@ -33,29 +36,49 @@ public class RatKingSprite extends MobSprite { public RatKingSprite() { super(); + resetAnims(); + } + + public void resetAnims(){ + final Calendar calendar = Calendar.getInstance(); //once a year the rat king feels a bit festive! festive = (calendar.get(Calendar.MONTH) == Calendar.DECEMBER && calendar.get(Calendar.WEEK_OF_MONTH) > 2); - final int c = festive ? 8 : 0; - + int c = festive ? 8 : 0; + + if (Dungeon.hero != null && Dungeon.hero.armorAbility instanceof Ratmogrify){ + c += 16; + if (parent != null) aura(0xFFFF00); + } + texture( Assets.Sprites.RATKING ); - + TextureFilm frames = new TextureFilm( texture, 16, 17 ); - + idle = new Animation( 2, true ); idle.frames( frames, c+0, c+0, c+0, c+1 ); - + run = new Animation( 10, true ); run.frames( frames, c+2, c+3, c+4, c+5, c+6 ); - + attack = new Animation( 15, false ); attack.frames( frames, c+0 ); - + die = new Animation( 10, false ); die.frames( frames, c+0 ); - + play( idle ); + + } + + + @Override + public void link(Char ch) { + super.link(ch); + if (Dungeon.hero != null && Dungeon.hero.armorAbility instanceof Ratmogrify){ + aura(0xFFFF00); + } } } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndChooseAbility.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndChooseAbility.java index 4a2bd4b36..7fd11d412 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndChooseAbility.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/windows/WndChooseAbility.java @@ -65,7 +65,7 @@ public class WndChooseAbility extends Window { float pos = body.bottom() + 3*GAP; for (ArmorAbility ability : hero.heroClass.armorAbilities()) { - RedButton abilityButton = new RedButton("_" + Messages.titleCase(ability.name()) + ":_ " + ability.shortDesc(), 6){ + RedButton abilityButton = new RedButton(ability.shortDesc(), 6){ @Override protected void onClick() { GameScene.show(new WndOptions(new Image(hero.heroClass.spritesheet(), 0, 90, 12, 15),