v0.9.3: improved several talent icons, added proper WIP T4 icons

This commit is contained in:
Evan Debenham 2021-06-01 21:11:39 -04:00
parent ad28843d98
commit b64f2b0195
2 changed files with 31 additions and 3 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

After

Width:  |  Height:  |  Size: 5.1 KiB

View File

@ -23,6 +23,7 @@ package com.shatteredpixel.shatteredpixeldungeon.actors.hero;
import com.shatteredpixel.shatteredpixeldungeon.Assets;
import com.shatteredpixel.shatteredpixeldungeon.Dungeon;
import com.shatteredpixel.shatteredpixeldungeon.GamesInProgress;
import com.shatteredpixel.shatteredpixeldungeon.actors.Actor;
import com.shatteredpixel.shatteredpixeldungeon.actors.Char;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.ArtifactRecharge;
@ -36,6 +37,7 @@ import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.RevealedArea;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Roots;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.WandEmpower;
import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.ArmorAbility;
import com.shatteredpixel.shatteredpixeldungeon.actors.hero.abilities.Ratmogrify;
import com.shatteredpixel.shatteredpixeldungeon.actors.mobs.Mob;
import com.shatteredpixel.shatteredpixeldungeon.effects.CellEmitter;
import com.shatteredpixel.shatteredpixeldungeon.effects.Speck;
@ -55,8 +57,10 @@ import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.MeleeWeapon;
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.missiles.MissileWeapon;
import com.shatteredpixel.shatteredpixeldungeon.levels.Level;
import com.shatteredpixel.shatteredpixeldungeon.levels.Terrain;
import com.shatteredpixel.shatteredpixeldungeon.messages.Languages;
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
import com.shatteredpixel.shatteredpixeldungeon.scenes.GameScene;
import com.shatteredpixel.shatteredpixeldungeon.scenes.HeroSelectScene;
import com.shatteredpixel.shatteredpixeldungeon.ui.BuffIndicator;
import com.watabou.noosa.Image;
import com.watabou.noosa.audio.Sample;
@ -140,9 +144,9 @@ public enum Talent {
EAGLE_EYE(119, 4), GO_FOR_THE_EYES(120, 4), SWIFT_SPIRIT(121, 4),
//universal T4
HEROIC_ENERGY(123, 4),
HEROIC_ENERGY(26, 4), //See icon() and title() for special logic for this one
//Ratmogrify T4
RATSISTANCE(125, 4), RATLOMACY(126, 4), RATFORCEMENTS(127, 4);
RATSISTANCE(124, 4), RATLOMACY(125, 4), RATFORCEMENTS(126, 4);
public static class ImprovisedProjectileCooldown extends FlavourBuff{
public int icon() { return BuffIndicator.TIME; }
@ -188,7 +192,24 @@ public enum Talent {
}
public int icon(){
return icon;
if (this == HEROIC_ENERGY){
if (Dungeon.hero != null && Dungeon.hero.armorAbility instanceof Ratmogrify){
return 127;
}
HeroClass cls = Dungeon.hero != null ? Dungeon.hero.heroClass : GamesInProgress.selectedClass;
switch (cls){
case WARRIOR: default:
return 26;
case MAGE:
return 58;
case ROGUE:
return 90;
case HUNTRESS:
return 122;
}
} else {
return icon;
}
}
public int maxPoints(){
@ -196,6 +217,13 @@ public enum Talent {
}
public String title(){
//TODO translate this
if (this == HEROIC_ENERGY &&
Messages.lang() == Languages.ENGLISH
&& Dungeon.hero != null
&& Dungeon.hero.armorAbility instanceof Ratmogrify){
return "ratroic energy";
}
return Messages.get(this, name() + ".title");
}