v0.7.0: polish pass on elixirs, brews, and spells

- Improved several sprites and vfx
- Beacon of returning no longer forgets return depth when used
This commit is contained in:
Evan Debenham 2018-10-17 02:45:12 -04:00
parent cec9f60e89
commit dd5d54f289
14 changed files with 46 additions and 30 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

After

Width:  |  Height:  |  Size: 19 KiB

View File

@ -64,7 +64,7 @@ public class Blizzard extends Blob {
@Override
public void use( BlobEmitter emitter ) {
super.use( emitter );
emitter.pour( Speck.factory( Speck.BLIZZARD ), 0.2f );
emitter.pour( Speck.factory( Speck.BLIZZARD, true ), 0.4f );
}
@Override

View File

@ -80,7 +80,7 @@ public class Inferno extends Blob {
public void use( BlobEmitter emitter ) {
super.use( emitter );
emitter.pour( Speck.factory( Speck.INFERNO ), 0.2f );
emitter.pour( Speck.factory( Speck.INFERNO, true ), 0.4f );
}
@Override

View File

@ -330,15 +330,15 @@ public class Speck extends Image {
break;
case INFERNO:
hardlight( 0xFF0000 );
angularSpeed = Random.Float( -20, +20 );
hardlight( 0xEE7722 );
angularSpeed = Random.Float( 200, 300 ) * (Random.Int(2) == 0 ? -1 : 1);
angle = Random.Float( 360 );
lifespan = Random.Float( 1f, 3f );
break;
case BLIZZARD:
hardlight( 0xFFFFFF );
angularSpeed = Random.Float( -20, +20 );
angularSpeed = Random.Float( 200, 300 ) * (Random.Int(2) == 0 ? -1 : 1);
angle = Random.Float( 360 );
lifespan = Random.Float( 1f, 3f );
break;

View File

@ -40,8 +40,6 @@ public class BlizzardBrew extends Brew {
@Override
public void shatter(int cell) {
if (Dungeon.level.heroFOV[cell]) {
setKnown();
splash( cell );
Sample.INSTANCE.play( Assets.SND_SHATTER );
}

View File

@ -21,6 +21,7 @@
package com.shatteredpixel.shatteredpixeldungeon.items.potions.brews;
import com.shatteredpixel.shatteredpixeldungeon.Assets;
import com.shatteredpixel.shatteredpixeldungeon.Dungeon;
import com.shatteredpixel.shatteredpixeldungeon.actors.Actor;
import com.shatteredpixel.shatteredpixeldungeon.actors.Char;
@ -31,6 +32,7 @@ import com.shatteredpixel.shatteredpixeldungeon.items.potions.PotionOfToxicGas;
import com.shatteredpixel.shatteredpixeldungeon.items.quest.GooBlob;
import com.shatteredpixel.shatteredpixeldungeon.sprites.ItemSpriteSheet;
import com.shatteredpixel.shatteredpixeldungeon.utils.BArray;
import com.watabou.noosa.audio.Sample;
import com.watabou.utils.PathFinder;
public class CausticBrew extends Brew {
@ -43,6 +45,11 @@ public class CausticBrew extends Brew {
@Override
public void shatter(int cell) {
if (Dungeon.level.heroFOV[cell]) {
splash( cell );
Sample.INSTANCE.play( Assets.SND_SHATTER );
}
PathFinder.buildDistanceMap( cell, BArray.not( Dungeon.level.solid, null ), 2 );
for (int i = 0; i < PathFinder.distance.length; i++) {
if (PathFinder.distance[i] < Integer.MAX_VALUE) {

View File

@ -48,7 +48,6 @@ public class AquaBlast extends TargetedSpell {
protected void affectTarget(Ballistica bolt, Hero hero) {
int cell = bolt.collisionPos;
//TODO perhaps different color based on depth?
Splash.at(cell, 0x00AAFF, 10);
for (int i : PathFinder.NEIGHBOURS9){

View File

@ -136,7 +136,6 @@ public class BeaconOfReturning extends Spell {
InterlevelScene.returnPos = returnPos;
Game.switchScene( InterlevelScene.class );
}
returnDepth = -1;
detach(hero.belongings.backpack);
}

View File

@ -21,6 +21,9 @@
package com.shatteredpixel.shatteredpixeldungeon.items.spells;
import com.shatteredpixel.shatteredpixeldungeon.Assets;
import com.shatteredpixel.shatteredpixeldungeon.effects.CellEmitter;
import com.shatteredpixel.shatteredpixeldungeon.effects.particles.ShadowParticle;
import com.shatteredpixel.shatteredpixeldungeon.items.Item;
import com.shatteredpixel.shatteredpixeldungeon.items.armor.Armor;
import com.shatteredpixel.shatteredpixeldungeon.items.quest.MetalShard;
@ -30,6 +33,7 @@ import com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.MeleeWeapon;
import com.shatteredpixel.shatteredpixeldungeon.items.weapon.missiles.Boomerang;
import com.shatteredpixel.shatteredpixeldungeon.sprites.ItemSpriteSheet;
import com.shatteredpixel.shatteredpixeldungeon.windows.WndBag;
import com.watabou.noosa.audio.Sample;
public class CurseInfusion extends InventorySpell {
@ -41,7 +45,8 @@ public class CurseInfusion extends InventorySpell {
@Override
protected void onItemSelected(Item item) {
//TODO visuals
CellEmitter.get(curUser.pos).burst(ShadowParticle.UP, 5);
Sample.INSTANCE.play(Assets.SND_CURSED);
item.cursed = true;
if (item instanceof MeleeWeapon || item instanceof Boomerang) {

View File

@ -25,6 +25,7 @@ import com.shatteredpixel.shatteredpixeldungeon.Assets;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Buff;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.FlavourBuff;
import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero;
import com.shatteredpixel.shatteredpixeldungeon.effects.Speck;
import com.shatteredpixel.shatteredpixeldungeon.items.potions.PotionOfLevitation;
import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfLullaby;
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
@ -43,6 +44,7 @@ public class FeatherFall extends Spell {
Buff.append(hero, FeatherBuff.class, 30f);
hero.sprite.operate(hero.pos);
Sample.INSTANCE.play(Assets.SND_READ );
hero.sprite.emitter().burst( Speck.factory( Speck.JET ), 20);
GLog.p(Messages.get(this, "light"));

View File

@ -60,7 +60,6 @@ public class MagicalPorter extends InventorySpell {
}
ported.add(result);
//TODO vfx
}
@Override

View File

@ -21,18 +21,22 @@
package com.shatteredpixel.shatteredpixeldungeon.items.spells;
import com.shatteredpixel.shatteredpixeldungeon.Assets;
import com.shatteredpixel.shatteredpixeldungeon.Dungeon;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.ArtifactRecharge;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Buff;
import com.shatteredpixel.shatteredpixeldungeon.actors.buffs.Recharging;
import com.shatteredpixel.shatteredpixeldungeon.actors.hero.Hero;
import com.shatteredpixel.shatteredpixeldungeon.effects.Lightning;
import com.shatteredpixel.shatteredpixeldungeon.items.quest.MetalShard;
import com.shatteredpixel.shatteredpixeldungeon.items.scrolls.ScrollOfRecharging;
import com.shatteredpixel.shatteredpixeldungeon.levels.traps.Trap;
import com.shatteredpixel.shatteredpixeldungeon.mechanics.Ballistica;
import com.shatteredpixel.shatteredpixeldungeon.messages.Messages;
import com.shatteredpixel.shatteredpixeldungeon.sprites.ItemSpriteSheet;
import com.shatteredpixel.shatteredpixeldungeon.tiles.DungeonTilemap;
import com.shatteredpixel.shatteredpixeldungeon.utils.GLog;
import com.watabou.noosa.audio.Sample;
public class ReclaimTrap extends TargetedSpell {
@ -47,8 +51,11 @@ public class ReclaimTrap extends TargetedSpell {
if (!t.visible) t.reveal();
t.disarm();
Sample.INSTANCE.play( Assets.SND_LIGHTNING );
hero.sprite.parent.addToFront( new Lightning(DungeonTilemap.tileCenterToWorld(t.pos), hero.sprite.center(), null) );
ScrollOfRecharging.charge(hero);
Buff.affect(hero, Recharging.class, 15f);
Buff.prolong(hero, Recharging.class, 15f);
Buff.affect(hero, ArtifactRecharge.class).set( 15 );
} else {

View File

@ -67,8 +67,8 @@ public class ItemSpriteSheet {
assignItemRect(SEED_HOLDER, 10, 10);
assignItemRect(SCROLL_HOLDER, 15, 14);
assignItemRect(STONE_HOLDER, 14, 12);
assignItemRect(BREW_HOLDER, 10, 14);
assignItemRect(ELIXIR_HOLDER, 10, 14);
assignItemRect(BREW_HOLDER, 12, 14);
assignItemRect(ELIXIR_HOLDER, 12, 14);
assignItemRect(SPELL_HOLDER, 8, 16);
}
@ -543,14 +543,14 @@ public class ItemSpriteSheet {
public static final int ELIXIR_SURGE = ELIXIRS+6;
public static final int ELIXIR_HONEY = ELIXIRS+7;
static{
assignItemRect(ELIXIR_DRAGON, 10, 14);
assignItemRect(ELIXIR_TOXIC, 10, 14);
assignItemRect(ELIXIR_ICY, 10, 14);
assignItemRect(ELIXIR_MIGHT, 10, 14);
assignItemRect(ELIXIR_AQUA, 10, 14);
assignItemRect(ELIXIR_RESTO, 10, 14);
assignItemRect(ELIXIR_SURGE, 10, 14);
assignItemRect(ELIXIR_HONEY, 10, 14);
assignItemRect(ELIXIR_DRAGON, 12, 14);
assignItemRect(ELIXIR_TOXIC, 12, 14);
assignItemRect(ELIXIR_ICY, 12, 14);
assignItemRect(ELIXIR_MIGHT, 12, 14);
assignItemRect(ELIXIR_AQUA, 12, 14);
assignItemRect(ELIXIR_RESTO, 12, 14);
assignItemRect(ELIXIR_SURGE, 12, 14);
assignItemRect(ELIXIR_HONEY, 12, 14);
}
private static final int BREWS = xy(1, 26); //16 slots
@ -563,14 +563,14 @@ public class ItemSpriteSheet {
public static final int BREW_BLIZZARD = BREWS+6;
public static final int BREW_SHOCKING = BREWS+7;
static{
assignItemRect(BREW_WICKED, 10, 14);
assignItemRect(BREW_FRIGID, 10, 14);
assignItemRect(BREW_FROSTFIRE, 10, 14);
assignItemRect(BREW_WICKED, 12, 14);
assignItemRect(BREW_FRIGID, 12, 14);
assignItemRect(BREW_FROSTFIRE, 12, 14);
assignItemRect(BREW_CAUSTIC, 10, 14);
assignItemRect(BREW_INFERNAL, 10, 14);
assignItemRect(BREW_BLIZZARD, 10, 14);
assignItemRect(BREW_SHOCKING, 10, 14);
assignItemRect(BREW_CAUSTIC, 12, 14);
assignItemRect(BREW_INFERNAL, 12, 14);
assignItemRect(BREW_BLIZZARD, 12, 14);
assignItemRect(BREW_SHOCKING, 12, 14);
}
//sprites still pretty WIP
private static final int SPELLS = xy(1, 27); //16 slots

View File

@ -347,12 +347,12 @@ public class QuickRecipe extends Component {
result.add(new QuickRecipe(new WickedBrew.Recipe()));
result.add(new QuickRecipe(new FrigidBrew.Recipe()));
result.add(new QuickRecipe(new FrostfireBrew.Recipe()));
result.add(new QuickRecipe(new CausticBrew.Recipe()));
result.add(null);
result.add(null);
result.add(new QuickRecipe(new InfernalBrew.Recipe()));
result.add(new QuickRecipe(new BlizzardBrew.Recipe()));
result.add(new QuickRecipe(new ShockingBrew.Recipe()));
result.add(new QuickRecipe(new CausticBrew.Recipe()));
return result;
case 8:
result.add(new QuickRecipe(new ElixirOfRestoration.Recipe()));