cleaned up formatting:

- removed trailing whitespace
- changed all leading whitespace to tabs
- removed IDE created author comments
This commit is contained in:
Evan Debenham
2015-06-12 16:22:26 -04:00
parent baa83b7e43
commit cebdff0221
335 changed files with 8555 additions and 8714 deletions
@@ -51,7 +51,7 @@ public class BurningFistSprite extends MobSprite {
@Override
public void attack( int cell ) {
posToShoot = cell;
posToShoot = cell;
super.attack( cell );
}
@@ -60,8 +60,8 @@ public class BurningFistSprite extends MobSprite {
if (anim == attack) {
Sample.INSTANCE.play( Assets.SND_ZAP );
MagicMissile.shadow( parent, ch.pos, posToShoot,
new Callback() {
MagicMissile.shadow( parent, ch.pos, posToShoot,
new Callback() {
@Override
public void call() {
ch.onAttackComplete();
@@ -54,7 +54,7 @@ public class CharSprite extends MovieClip implements Tweener.Listener, MovieClip
public static final int NEUTRAL = 0xFFFF00;
private static final float MOVE_INTERVAL = 0.1f;
private static final float FLASH_INTERVAL = 0.05f;
private static final float FLASH_INTERVAL = 0.05f;
public enum State {
BURNING, LEVITATING, INVISIBLE, PARALYSED, FROZEN, ILLUMINATED, CHILLED, DARKENED
@@ -90,7 +90,7 @@ public class CharSprite extends MovieClip implements Tweener.Listener, MovieClip
public Char ch;
public boolean isMoving = false;
public boolean isMoving = false;
public CharSprite() {
super();
@@ -145,7 +145,7 @@ public class CharSprite extends MovieClip implements Tweener.Listener, MovieClip
motion.listener = this;
parent.add( motion );
isMoving = true;
isMoving = true;
turnTo( from , to );
@@ -153,7 +153,7 @@ public class CharSprite extends MovieClip implements Tweener.Listener, MovieClip
GameScene.ripple( from );
}
ch.onMotionComplete();
ch.onMotionComplete();
}
public void interruptMotion() {
@@ -380,7 +380,7 @@ public class CharSprite extends MovieClip implements Tweener.Listener, MovieClip
}
emo = new EmoIcon.Sleep( this );
}
idle();
idle();
}
public void hideSleep() {
@@ -27,27 +27,27 @@ public class FetidRatSprite extends MobSprite {
private Emitter cloud;
public FetidRatSprite() {
super();
public FetidRatSprite() {
super();
texture( Assets.RAT );
texture( Assets.RAT );
TextureFilm frames = new TextureFilm( texture, 16, 15 );
TextureFilm frames = new TextureFilm( texture, 16, 15 );
idle = new Animation( 2, true );
idle.frames( frames, 32, 32, 32, 33 );
idle = new Animation( 2, true );
idle.frames( frames, 32, 32, 32, 33 );
run = new Animation( 10, true );
run.frames( frames, 38, 39, 40, 41, 42 );
run = new Animation( 10, true );
run.frames( frames, 38, 39, 40, 41, 42 );
attack = new Animation( 15, false );
attack.frames( frames, 34, 35, 36, 37, 32 );
attack = new Animation( 15, false );
attack.frames( frames, 34, 35, 36, 37, 32 );
die = new Animation( 10, false );
die.frames( frames, 43, 44, 45, 46 );
die = new Animation( 10, false );
die.frames( frames, 43, 44, 45, 46 );
play( idle );
}
play( idle );
}
@Override
public void link( Char ch ) {
@@ -41,11 +41,11 @@ public class GhostSprite extends MobSprite {
run = new Animation( 10, true );
run.frames( frames, 0, 1 );
attack = new Animation( 10, false );
attack.frames( frames, 0, 2, 3 );
attack = new Animation( 10, false );
attack.frames( frames, 0, 2, 3 );
die = new Animation( 8, false );
die.frames( frames, 0, 4, 5, 6, 7 );
die = new Animation( 8, false );
die.frames( frames, 0, 4, 5, 6, 7 );
play( idle );
}
@@ -7,56 +7,53 @@ import com.watabou.noosa.MovieClip;
import com.watabou.noosa.TextureFilm;
import com.watabou.utils.Callback;
/**
* Created by Evan on 09/10/2014.
*/
public class GnollTricksterSprite extends MobSprite {
private Animation cast;
private Animation cast;
public GnollTricksterSprite() {
super();
public GnollTricksterSprite() {
super();
texture( Assets.GNOLL );
texture( Assets.GNOLL );
TextureFilm frames = new TextureFilm( texture, 12, 15 );
TextureFilm frames = new TextureFilm( texture, 12, 15 );
idle = new MovieClip.Animation( 2, true );
idle.frames( frames, 21, 21, 21, 22, 21, 21, 22, 22 );
idle = new MovieClip.Animation( 2, true );
idle.frames( frames, 21, 21, 21, 22, 21, 21, 22, 22 );
run = new MovieClip.Animation( 12, true );
run.frames( frames, 25, 26, 27, 28 );
run = new MovieClip.Animation( 12, true );
run.frames( frames, 25, 26, 27, 28 );
attack = new MovieClip.Animation( 12, false );
attack.frames( frames, 23, 24, 21 );
attack = new MovieClip.Animation( 12, false );
attack.frames( frames, 23, 24, 21 );
cast = attack.clone();
cast = attack.clone();
die = new MovieClip.Animation( 12, false );
die.frames( frames, 29, 30, 31 );
die = new MovieClip.Animation( 12, false );
die.frames( frames, 29, 30, 31 );
play( idle );
}
play( idle );
}
@Override
public void attack( int cell ) {
if (!Level.adjacent(cell, ch.pos)) {
@Override
public void attack( int cell ) {
if (!Level.adjacent(cell, ch.pos)) {
((MissileSprite)parent.recycle( MissileSprite.class )).
reset( ch.pos, cell, new CurareDart(), new Callback() {
@Override
public void call() {
ch.onAttackComplete();
}
} );
((MissileSprite)parent.recycle( MissileSprite.class )).
reset( ch.pos, cell, new CurareDart(), new Callback() {
@Override
public void call() {
ch.onAttackComplete();
}
} );
play( cast );
turnTo( ch.pos , cell );
play( cast );
turnTo( ch.pos , cell );
} else {
} else {
super.attack( cell );
super.attack( cell );
}
}
}
}
}
@@ -29,7 +29,7 @@ import com.shatteredpixel.shatteredpixeldungeon.Assets;
public class GooSprite extends MobSprite {
private Animation pump;
private Animation pumpAttack;
private Animation pumpAttack;
public GooSprite() {
super();
@@ -47,8 +47,8 @@ public class GooSprite extends MobSprite {
pump = new Animation( 20, true );
pump.frames( frames, 4, 3, 2, 1, 0 );
pumpAttack = new Animation ( 20, false );
pumpAttack.frames( frames, 4, 3, 2, 1, 0, 7);
pumpAttack = new Animation ( 20, false );
pumpAttack.frames( frames, 4, 3, 2, 1, 0, 7);
attack = new Animation( 10, false );
attack.frames( frames, 8, 9, 10 );
@@ -63,7 +63,7 @@ public class GooSprite extends MobSprite {
play( pump );
}
public void pumpAttack() { play( pumpAttack ); }
public void pumpAttack() { play( pumpAttack ); }
@Override
public void play( Animation anim, boolean force ) {
@@ -114,13 +114,13 @@ public class GooSprite extends MobSprite {
}
@Override
public void onComplete( Animation anim ) {
super.onComplete(anim);
public void onComplete( Animation anim ) {
super.onComplete(anim);
if (anim == pumpAttack) {
if (anim == pumpAttack) {
idle();
ch.onAttackComplete();
}
}
idle();
ch.onAttackComplete();
}
}
}
@@ -4,35 +4,32 @@ import com.shatteredpixel.shatteredpixeldungeon.Assets;
import com.watabou.noosa.MovieClip;
import com.watabou.noosa.TextureFilm;
/**
* Created by Evan on 09/10/2014.
*/
public class GreatCrabSprite extends MobSprite {
public GreatCrabSprite() {
super();
public GreatCrabSprite() {
super();
texture( Assets.CRAB );
texture( Assets.CRAB );
TextureFilm frames = new TextureFilm( texture, 16, 16 );
TextureFilm frames = new TextureFilm( texture, 16, 16 );
idle = new MovieClip.Animation( 5, true );
idle.frames( frames, 16, 17, 16, 18 );
idle = new MovieClip.Animation( 5, true );
idle.frames( frames, 16, 17, 16, 18 );
run = new MovieClip.Animation( 10, true );
run.frames( frames, 19, 20, 21, 22 );
run = new MovieClip.Animation( 10, true );
run.frames( frames, 19, 20, 21, 22 );
attack = new MovieClip.Animation( 12, false );
attack.frames( frames, 23, 24, 25 );
attack = new MovieClip.Animation( 12, false );
attack.frames( frames, 23, 24, 25 );
die = new MovieClip.Animation( 12, false );
die.frames( frames, 26, 27, 28, 29 );
die = new MovieClip.Animation( 12, false );
die.frames( frames, 26, 27, 28, 29 );
play( idle );
}
play( idle );
}
@Override
public int blood() {
return 0xFFFFEA80;
}
@Override
public int blood() {
return 0xFFFFEA80;
}
}
@@ -84,7 +84,7 @@ public class HeroSprite extends CharSprite {
}
@Override
public void move( int from, int to ) {
public void move( int from, int to ) {
super.move( from, to );
if (ch.flying) {
play( fly );
@@ -93,12 +93,12 @@ public class HeroSprite extends CharSprite {
}
@Override
public void jump( int from, int to, Callback callback ) {
public void jump( int from, int to, Callback callback ) {
super.jump( from, to, callback );
play( fly );
}
play( fly );
}
@Override
@Override
public void update() {
sleeping = ((Hero)ch).restoreHealth;
@@ -33,7 +33,7 @@ public class ImpSprite extends MobSprite {
TextureFilm frames = new TextureFilm( texture, 12, 14 );
idle = new Animation( 10, true );
idle.frames( frames,
idle.frames( frames,
0, 1, 2, 3, 0, 1, 2, 3, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
0, 1, 2, 3, 0, 1, 2, 3, 0, 1, 3, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4, 0, 0, 0, 4, 4, 4, 4, 4, 4, 4, 4 );
@@ -156,7 +156,7 @@ public class ItemSprite extends MovieClip {
} else {
float px = x;
float py = y;
float py = y;
drop();
place(from);
@@ -19,219 +19,219 @@ package com.shatteredpixel.shatteredpixeldungeon.sprites;
public class ItemSpriteSheet {
// Row definers
private static final int ROW1 = 0*16;
private static final int ROW2 = 1*16;
private static final int ROW3 = 2*16;
private static final int ROW4 = 3*16;
private static final int ROW5 = 4*16;
private static final int ROW6 = 5*16;
private static final int ROW7 = 6*16;
private static final int ROW8 = 7*16;
private static final int ROW9 = 8*16;
private static final int ROW10 = 9*16;
private static final int ROW11 = 10*16;
private static final int ROW12 = 11*16;
private static final int ROW13 = 12*16;
private static final int ROW14 = 13*16;
private static final int ROW15 = 14*16;
private static final int ROW16 = 15*16;
// Row definers
private static final int ROW1 = 0*16;
private static final int ROW2 = 1*16;
private static final int ROW3 = 2*16;
private static final int ROW4 = 3*16;
private static final int ROW5 = 4*16;
private static final int ROW6 = 5*16;
private static final int ROW7 = 6*16;
private static final int ROW8 = 7*16;
private static final int ROW9 = 8*16;
private static final int ROW10 = 9*16;
private static final int ROW11 = 10*16;
private static final int ROW12 = 11*16;
private static final int ROW13 = 12*16;
private static final int ROW14 = 13*16;
private static final int ROW15 = 14*16;
private static final int ROW16 = 15*16;
//Row One: Items which can't be obtained
//null warning occupies space 0, should only show up if there's a bug.
public static final int NULLWARN = ROW1+0;
public static final int DEWDROP = ROW1+1;
public static final int PETAL = ROW1+2;
public static final int SANDBAG = ROW1+3;
// Heaps (containers)
public static final int BONES = ROW1+4;
public static final int REMAINS = ROW1+5;
public static final int TOMB = ROW1+6;
public static final int GRAVE = ROW1+7;
public static final int CHEST = ROW1+8;
public static final int LOCKED_CHEST = ROW1+9;
public static final int CRYSTAL_CHEST = ROW1+10;
// Placeholders
public static final int WEAPON = ROW1+11;
public static final int ARMOR = ROW1+12;
public static final int RING = ROW1+13;
public static final int SMTH = ROW1+14;
//Row One: Items which can't be obtained
//null warning occupies space 0, should only show up if there's a bug.
public static final int NULLWARN = ROW1+0;
public static final int DEWDROP = ROW1+1;
public static final int PETAL = ROW1+2;
public static final int SANDBAG = ROW1+3;
// Heaps (containers)
public static final int BONES = ROW1+4;
public static final int REMAINS = ROW1+5;
public static final int TOMB = ROW1+6;
public static final int GRAVE = ROW1+7;
public static final int CHEST = ROW1+8;
public static final int LOCKED_CHEST = ROW1+9;
public static final int CRYSTAL_CHEST = ROW1+10;
// Placeholders
public static final int WEAPON = ROW1+11;
public static final int ARMOR = ROW1+12;
public static final int RING = ROW1+13;
public static final int SMTH = ROW1+14;
//Row Two: Miscellaneous single use items
public static final int GOLD = ROW2+0;
public static final int TORCH = ROW2+1;
public static final int STYLUS = ROW2+2;
public static final int ANKH = ROW2+3;
// Keys
public static final int IRON_KEY = ROW2+4;
public static final int GOLDEN_KEY = ROW2+5;
public static final int SKELETON_KEY = ROW2+6;
//Boss Rewards
public static final int BEACON = ROW2+7;
public static final int MASTERY = ROW2+8;
public static final int KIT = ROW2+9;
public static final int AMULET = ROW2+10;
public static final int WEIGHT = ROW2+11;
//Row Two: Miscellaneous single use items
public static final int GOLD = ROW2+0;
public static final int TORCH = ROW2+1;
public static final int STYLUS = ROW2+2;
public static final int ANKH = ROW2+3;
// Keys
public static final int IRON_KEY = ROW2+4;
public static final int GOLDEN_KEY = ROW2+5;
public static final int SKELETON_KEY = ROW2+6;
//Boss Rewards
public static final int BEACON = ROW2+7;
public static final int MASTERY = ROW2+8;
public static final int KIT = ROW2+9;
public static final int AMULET = ROW2+10;
public static final int WEIGHT = ROW2+11;
public static final int BOMB = ROW2+12;
public static final int DBL_BOMB= ROW2+13;
public static final int DBL_BOMB= ROW2+13;
public static final int HONEYPOT= ROW2+14;
public static final int SHATTPOT= ROW2+15;
public static final int SHATTPOT= ROW2+15;
//Row Three: Melee weapons
public static final int KNUCKLEDUSTER = ROW3+0;
public static final int DAGGER = ROW3+1;
public static final int SHORT_SWORD = ROW3+2;
public static final int MAGES_STAFF = ROW3+3;
public static final int QUARTERSTAFF = ROW3+4;
public static final int SPEAR = ROW3+5;
public static final int MACE = ROW3+6;
public static final int SWORD = ROW3+7;
public static final int BATTLE_AXE = ROW3+8;
public static final int LONG_SWORD = ROW3+9;
public static final int WAR_HAMMER = ROW3+10;
public static final int GLAIVE = ROW3+11;
//Row Three: Melee weapons
public static final int KNUCKLEDUSTER = ROW3+0;
public static final int DAGGER = ROW3+1;
public static final int SHORT_SWORD = ROW3+2;
public static final int MAGES_STAFF = ROW3+3;
public static final int QUARTERSTAFF = ROW3+4;
public static final int SPEAR = ROW3+5;
public static final int MACE = ROW3+6;
public static final int SWORD = ROW3+7;
public static final int BATTLE_AXE = ROW3+8;
public static final int LONG_SWORD = ROW3+9;
public static final int WAR_HAMMER = ROW3+10;
public static final int GLAIVE = ROW3+11;
//Row Four: Missile weapons
public static final int DART = ROW4+0;
public static final int BOOMERANG = ROW4+1;
public static final int INCENDIARY_DART = ROW4+2;
public static final int SHURIKEN = ROW4+3;
public static final int CURARE_DART = ROW4+4;
public static final int JAVELIN = ROW4+5;
public static final int TOMAHAWK = ROW4+6;
//Row Four: Missile weapons
public static final int DART = ROW4+0;
public static final int BOOMERANG = ROW4+1;
public static final int INCENDIARY_DART = ROW4+2;
public static final int SHURIKEN = ROW4+3;
public static final int CURARE_DART = ROW4+4;
public static final int JAVELIN = ROW4+5;
public static final int TOMAHAWK = ROW4+6;
//Row Five: Armors
public static final int ARMOR_CLOTH = ROW5+0;
public static final int ARMOR_LEATHER = ROW5+1;
public static final int ARMOR_MAIL = ROW5+2;
public static final int ARMOR_SCALE = ROW5+3;
public static final int ARMOR_PLATE = ROW5+4;
public static final int ARMOR_WARRIOR = ROW5+5;
public static final int ARMOR_MAGE = ROW5+6;
public static final int ARMOR_ROGUE = ROW5+7;
public static final int ARMOR_HUNTRESS = ROW5+8;
//Row Five: Armors
public static final int ARMOR_CLOTH = ROW5+0;
public static final int ARMOR_LEATHER = ROW5+1;
public static final int ARMOR_MAIL = ROW5+2;
public static final int ARMOR_SCALE = ROW5+3;
public static final int ARMOR_PLATE = ROW5+4;
public static final int ARMOR_WARRIOR = ROW5+5;
public static final int ARMOR_MAGE = ROW5+6;
public static final int ARMOR_ROGUE = ROW5+7;
public static final int ARMOR_HUNTRESS = ROW5+8;
//Row Six: Wands
public static final int WAND_MAGIC_MISSILE = ROW6+0;
public static final int WAND_FIREBOLT = ROW6+1;
public static final int WAND_FROST = ROW6+2;
public static final int WAND_LIGHTNING = ROW6+3;
public static final int WAND_DISINTEGRATION = ROW6+4;
public static final int WAND_PRISMATIC_LIGHT= ROW6+5;
public static final int WAND_VENOM = ROW6+6;
public static final int WAND_LIVING_EARTH = ROW6+7;
public static final int WAND_BLAST_WAVE = ROW6+8;
public static final int WAND_CORRUPTION = ROW6+9;
public static final int WAND_WARDING = ROW6+10;
public static final int WAND_REGROWTH = ROW6+11;
public static final int WAND_TRANSFUSION = ROW6+12;
//Row Six: Wands
public static final int WAND_MAGIC_MISSILE = ROW6+0;
public static final int WAND_FIREBOLT = ROW6+1;
public static final int WAND_FROST = ROW6+2;
public static final int WAND_LIGHTNING = ROW6+3;
public static final int WAND_DISINTEGRATION = ROW6+4;
public static final int WAND_PRISMATIC_LIGHT= ROW6+5;
public static final int WAND_VENOM = ROW6+6;
public static final int WAND_LIVING_EARTH = ROW6+7;
public static final int WAND_BLAST_WAVE = ROW6+8;
public static final int WAND_CORRUPTION = ROW6+9;
public static final int WAND_WARDING = ROW6+10;
public static final int WAND_REGROWTH = ROW6+11;
public static final int WAND_TRANSFUSION = ROW6+12;
//Row Seven: Rings
public static final int RING_GARNET = ROW7+0;
public static final int RING_RUBY = ROW7+1;
public static final int RING_TOPAZ = ROW7+2;
public static final int RING_EMERALD = ROW7+3;
public static final int RING_ONYX = ROW7+4;
public static final int RING_OPAL = ROW7+5;
public static final int RING_TOURMALINE = ROW7+6;
public static final int RING_SAPPHIRE = ROW7+7;
public static final int RING_AMETHYST = ROW7+8;
public static final int RING_QUARTZ = ROW7+9;
public static final int RING_AGATE = ROW7+10;
public static final int RING_DIAMOND = ROW7+11;
//Row Seven: Rings
public static final int RING_GARNET = ROW7+0;
public static final int RING_RUBY = ROW7+1;
public static final int RING_TOPAZ = ROW7+2;
public static final int RING_EMERALD = ROW7+3;
public static final int RING_ONYX = ROW7+4;
public static final int RING_OPAL = ROW7+5;
public static final int RING_TOURMALINE = ROW7+6;
public static final int RING_SAPPHIRE = ROW7+7;
public static final int RING_AMETHYST = ROW7+8;
public static final int RING_QUARTZ = ROW7+9;
public static final int RING_AGATE = ROW7+10;
public static final int RING_DIAMOND = ROW7+11;
//Row Eight: Artifacts with Static Images
public static final int ARTIFACT_CLOAK = ROW8+0;
public static final int ARTIFACT_ARMBAND = ROW8+1;
public static final int ARTIFACT_CAPE = ROW8+2;
public static final int ARTIFACT_TALISMAN = ROW8+3;
public static final int ARTIFACT_HOURGLASS = ROW8+4;
public static final int ARTIFACT_TOOLKIT = ROW8+5;
public static final int ARTIFACT_SPELLBOOK = ROW8+6;
public static final int ARTIFACT_BEACON = ROW8+7;
public static final int ARTIFACT_CHAINS = ROW8+8;
//Row Eight: Artifacts with Static Images
public static final int ARTIFACT_CLOAK = ROW8+0;
public static final int ARTIFACT_ARMBAND = ROW8+1;
public static final int ARTIFACT_CAPE = ROW8+2;
public static final int ARTIFACT_TALISMAN = ROW8+3;
public static final int ARTIFACT_HOURGLASS = ROW8+4;
public static final int ARTIFACT_TOOLKIT = ROW8+5;
public static final int ARTIFACT_SPELLBOOK = ROW8+6;
public static final int ARTIFACT_BEACON = ROW8+7;
public static final int ARTIFACT_CHAINS = ROW8+8;
//Row Nine: Artifacts with Dynamic Images
public static final int ARTIFACT_HORN1 = ROW9+0;
public static final int ARTIFACT_HORN2 = ROW9+1;
public static final int ARTIFACT_HORN3 = ROW9+2;
public static final int ARTIFACT_HORN4 = ROW9+3;
public static final int ARTIFACT_CHALICE1 = ROW9+4;
public static final int ARTIFACT_CHALICE2 = ROW9+5;
public static final int ARTIFACT_CHALICE3 = ROW9+6;
public static final int ARTIFACT_SANDALS = ROW9+7;
public static final int ARTIFACT_SHOES = ROW9+8;
public static final int ARTIFACT_BOOTS = ROW9+9;
public static final int ARTIFACT_GREAVES = ROW9+10;
public static final int ARTIFACT_ROSE1 = ROW9+11;
public static final int ARTIFACT_ROSE2 = ROW9+12;
public static final int ARTIFACT_ROSE3 = ROW9+13;
//Row Nine: Artifacts with Dynamic Images
public static final int ARTIFACT_HORN1 = ROW9+0;
public static final int ARTIFACT_HORN2 = ROW9+1;
public static final int ARTIFACT_HORN3 = ROW9+2;
public static final int ARTIFACT_HORN4 = ROW9+3;
public static final int ARTIFACT_CHALICE1 = ROW9+4;
public static final int ARTIFACT_CHALICE2 = ROW9+5;
public static final int ARTIFACT_CHALICE3 = ROW9+6;
public static final int ARTIFACT_SANDALS = ROW9+7;
public static final int ARTIFACT_SHOES = ROW9+8;
public static final int ARTIFACT_BOOTS = ROW9+9;
public static final int ARTIFACT_GREAVES = ROW9+10;
public static final int ARTIFACT_ROSE1 = ROW9+11;
public static final int ARTIFACT_ROSE2 = ROW9+12;
public static final int ARTIFACT_ROSE3 = ROW9+13;
//Row Ten: Scrolls
public static final int SCROLL_KAUNAN = ROW10+0;
public static final int SCROLL_SOWILO = ROW10+1;
public static final int SCROLL_LAGUZ = ROW10+2;
public static final int SCROLL_YNGVI = ROW10+3;
public static final int SCROLL_GYFU = ROW10+4;
public static final int SCROLL_RAIDO = ROW10+5;
public static final int SCROLL_ISAZ = ROW10+6;
public static final int SCROLL_MANNAZ = ROW10+7;
public static final int SCROLL_NAUDIZ = ROW10+8;
public static final int SCROLL_BERKANAN = ROW10+9;
public static final int SCROLL_ODAL = ROW10+10;
public static final int SCROLL_TIWAZ = ROW10+11;
//Row Ten: Scrolls
public static final int SCROLL_KAUNAN = ROW10+0;
public static final int SCROLL_SOWILO = ROW10+1;
public static final int SCROLL_LAGUZ = ROW10+2;
public static final int SCROLL_YNGVI = ROW10+3;
public static final int SCROLL_GYFU = ROW10+4;
public static final int SCROLL_RAIDO = ROW10+5;
public static final int SCROLL_ISAZ = ROW10+6;
public static final int SCROLL_MANNAZ = ROW10+7;
public static final int SCROLL_NAUDIZ = ROW10+8;
public static final int SCROLL_BERKANAN = ROW10+9;
public static final int SCROLL_ODAL = ROW10+10;
public static final int SCROLL_TIWAZ = ROW10+11;
//Row Eleven: Potions
public static final int POTION_CRIMSON = ROW11+0;
public static final int POTION_AMBER = ROW11+1;
public static final int POTION_GOLDEN = ROW11+2;
public static final int POTION_JADE = ROW11+3;
public static final int POTION_TURQUOISE = ROW11+4;
public static final int POTION_AZURE = ROW11+5;
public static final int POTION_INDIGO = ROW11+6;
public static final int POTION_MAGENTA = ROW11+7;
public static final int POTION_BISTRE = ROW11+8;
public static final int POTION_CHARCOAL = ROW11+9;
public static final int POTION_SILVER = ROW11+10;
public static final int POTION_IVORY = ROW11+11;
//Row Eleven: Potions
public static final int POTION_CRIMSON = ROW11+0;
public static final int POTION_AMBER = ROW11+1;
public static final int POTION_GOLDEN = ROW11+2;
public static final int POTION_JADE = ROW11+3;
public static final int POTION_TURQUOISE = ROW11+4;
public static final int POTION_AZURE = ROW11+5;
public static final int POTION_INDIGO = ROW11+6;
public static final int POTION_MAGENTA = ROW11+7;
public static final int POTION_BISTRE = ROW11+8;
public static final int POTION_CHARCOAL = ROW11+9;
public static final int POTION_SILVER = ROW11+10;
public static final int POTION_IVORY = ROW11+11;
//Row Twelve: Seeds
public static final int SEED_ROTBERRY = ROW12+0;
public static final int SEED_FIREBLOOM = ROW12+1;
public static final int SEED_STARFLOWER = ROW12+2;
public static final int SEED_BLINDWEED = ROW12+3;
public static final int SEED_SUNGRASS = ROW12+4;
public static final int SEED_ICECAP = ROW12+5;
public static final int SEED_STORMVINE = ROW12+6;
public static final int SEED_SORROWMOSS = ROW12+7;
public static final int SEED_DREAMFOIL = ROW12+8;
public static final int SEED_EARTHROOT = ROW12+9;
public static final int SEED_FADELEAF = ROW12+10;
public static final int SEED_BLANDFRUIT = ROW12+11;
//Row Twelve: Seeds
public static final int SEED_ROTBERRY = ROW12+0;
public static final int SEED_FIREBLOOM = ROW12+1;
public static final int SEED_STARFLOWER = ROW12+2;
public static final int SEED_BLINDWEED = ROW12+3;
public static final int SEED_SUNGRASS = ROW12+4;
public static final int SEED_ICECAP = ROW12+5;
public static final int SEED_STORMVINE = ROW12+6;
public static final int SEED_SORROWMOSS = ROW12+7;
public static final int SEED_DREAMFOIL = ROW12+8;
public static final int SEED_EARTHROOT = ROW12+9;
public static final int SEED_FADELEAF = ROW12+10;
public static final int SEED_BLANDFRUIT = ROW12+11;
//Row Thirteen: Food
public static final int MEAT = ROW13+0;
public static final int STEAK = ROW13+1;
public static final int OVERPRICED = ROW13+2;
public static final int CARPACCIO = ROW13+3;
public static final int BLANDFRUIT = ROW13+4;
public static final int RATION = ROW13+5;
public static final int PASTY = ROW13+6;
//Row Thirteen: Food
public static final int MEAT = ROW13+0;
public static final int STEAK = ROW13+1;
public static final int OVERPRICED = ROW13+2;
public static final int CARPACCIO = ROW13+3;
public static final int BLANDFRUIT = ROW13+4;
public static final int RATION = ROW13+5;
public static final int PASTY = ROW13+6;
//Row Fourteen: Quest Items
public static final int SKULL = ROW14+0;
public static final int DUST = ROW14+1;
public static final int PICKAXE = ROW14+2;
public static final int ORE = ROW14+3;
public static final int TOKEN = ROW14+4;
//Row Fourteen: Quest Items
public static final int SKULL = ROW14+0;
public static final int DUST = ROW14+1;
public static final int PICKAXE = ROW14+2;
public static final int ORE = ROW14+3;
public static final int TOKEN = ROW14+4;
//Row Fifteen: Containers/Bags
public static final int VIAL = ROW15+0;
public static final int POUCH = ROW15+1;
public static final int HOLDER = ROW15+2;
public static final int BANDOLIER = ROW15+3;
public static final int HOLSTER = ROW15+4;
//Row Fifteen: Containers/Bags
public static final int VIAL = ROW15+0;
public static final int POUCH = ROW15+1;
public static final int HOLDER = ROW15+2;
public static final int BANDOLIER = ROW15+3;
public static final int HOLSTER = ROW15+4;
//Row Sixteen: Unused
//Row Sixteen: Unused
}
@@ -53,11 +53,11 @@ public class MissileSprite extends ItemSprite implements Tweener.Listener {
point( DungeonTilemap.tileToWorld( from ) );
PointF dest = DungeonTilemap.tileToWorld( to );
PointF d = PointF.diff( dest, point() );
PointF d = PointF.diff( dest, point() );
speed.set( d ).normalize().scale( SPEED );
if (image == ItemSpriteSheet.DART || image == ItemSpriteSheet.INCENDIARY_DART
|| image == ItemSpriteSheet.CURARE_DART || image == ItemSpriteSheet.JAVELIN) {
|| image == ItemSpriteSheet.CURARE_DART || image == ItemSpriteSheet.JAVELIN) {
angularSpeed = 0;
angle = 135 - (float)(Math.atan2( d.x, d.y ) / 3.1415926 * 180);
@@ -40,7 +40,7 @@ public class MobSprite extends CharSprite {
super.onComplete( anim );
if (anim == die) {
if (anim == die) {
parent.add( new AlphaTweener( this, 0, FADE_TIME ) {
@Override
protected void onComplete() {
@@ -62,7 +62,7 @@ public class ScorpioSprite extends MobSprite {
cellToAttack = cell;
turnTo( ch.pos , cell );
play( zap );
play( zap );
} else {
@@ -77,7 +77,7 @@ public class ScorpioSprite extends MobSprite {
idle();
((MissileSprite)parent.recycle( MissileSprite.class )).
reset( ch.pos, cellToAttack, new Dart(), new Callback() {
reset( ch.pos, cellToAttack, new Dart(), new Callback() {
@Override
public void call() {
ch.onAttackComplete();
@@ -33,7 +33,7 @@ public class SheepSprite extends MobSprite {
idle = new Animation( 8, true );
idle.frames( frames, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 0 );
run = idle.clone();
run = idle.clone();
attack = idle.clone();
die = new Animation( 20, false );
@@ -60,13 +60,13 @@ public class TenguSprite extends MobSprite {
play( run );
turnTo( from , to );
isMoving = true;
isMoving = true;
if (Level.water[to]) {
if (Level.water[to]) {
GameScene.ripple( to );
}
ch.onMotionComplete();
ch.onMotionComplete();
}
@Override
@@ -74,7 +74,7 @@ public class TenguSprite extends MobSprite {
if (!Level.adjacent( cell, ch.pos )) {
((MissileSprite)parent.recycle( MissileSprite.class )).
reset( ch.pos, cell, new Shuriken(), new Callback() {
reset( ch.pos, cell, new Shuriken(), new Callback() {
@Override
public void call() {
ch.onAttackComplete();
@@ -94,8 +94,8 @@ public class TenguSprite extends MobSprite {
@Override
public void onComplete( Animation anim ) {
if (anim == run) {
isMoving = false;
idle();
isMoving = false;
idle();
} else {
super.onComplete( anim );
}
@@ -55,8 +55,8 @@ public class WarlockSprite extends MobSprite {
turnTo( ch.pos , cell );
play( zap );
MagicMissile.shadow( parent, ch.pos, cell,
new Callback() {
MagicMissile.shadow( parent, ch.pos, cell,
new Callback() {
@Override
public void call() {
((Warlock)ch).onZapComplete();