com.watabou.noosa.TextureFilm Java Examples
The following examples show how to use
com.watabou.noosa.TextureFilm.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: BanditSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 6 votes |
public BanditSprite() { super(); texture( Assets.THIEF ); TextureFilm film = new TextureFilm( texture, 12, 13 ); idle = new Animation( 1, true ); idle.frames( film, 21, 21, 21, 22, 21, 21, 21, 21, 22 ); run = new Animation( 15, true ); run.frames( film, 21, 21, 23, 24, 24, 25 ); die = new Animation( 10, false ); die.frames( film, 25, 27, 28, 29, 30 ); attack = new Animation( 12, false ); attack.frames( film, 31, 32, 33 ); idle(); }
Example #2
Source File: MirrorSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 6 votes |
public void updateArmor( int tier ) { TextureFilm film = new TextureFilm( HeroSprite.tiers(), tier, FRAME_WIDTH, FRAME_HEIGHT ); idle = new Animation( 1, true ); idle.frames( film, 0, 0, 0, 1, 0, 0, 1, 1 ); run = new Animation( 20, true ); run.frames( film, 2, 3, 4, 5, 6, 7 ); die = new Animation( 20, false ); die.frames( film, 0 ); attack = new Animation( 15, false ); attack.frames( film, 13, 14, 15, 0 ); idle(); }
Example #3
Source File: ImpSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 6 votes |
public ImpSprite() { super(); texture( Assets.IMP ); TextureFilm frames = new TextureFilm( texture, 12, 14 ); idle = new Animation( 10, true ); 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 ); run = new Animation( 20, true ); run.frames( frames, 0 ); die = new Animation( 10, false ); die.frames( frames, 0, 3, 2, 1, 0, 3, 2, 1, 0 ); play( idle ); }
Example #4
Source File: WndInfoBuff.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 6 votes |
public WndInfoBuff(Buff buff){ super(); IconTitle titlebar = new IconTitle(); icons = TextureCache.get( Assets.BUFFS_LARGE ); film = new TextureFilm( icons, 16, 16 ); Image buffIcon = new Image( icons ); buffIcon.frame( film.get(buff.icon()) ); titlebar.icon( buffIcon ); titlebar.label( Utils.capitalize(buff.toString()), Window.TITLE_COLOR ); titlebar.setRect( 0, 0, WIDTH, 0 ); add( titlebar ); BitmapTextMultiline txtInfo = PixelScene.createMultiline(buff.desc(), 6); txtInfo.maxWidth = WIDTH; txtInfo.measure(); txtInfo.x = titlebar.left(); txtInfo.y = titlebar.bottom() + GAP; add( txtInfo ); resize( WIDTH, (int)(txtInfo.y + txtInfo.height()) ); }
Example #5
Source File: MirrorSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 6 votes |
public void updateArmor( int tier ) { TextureFilm film = new TextureFilm( HeroSprite.tiers(), tier, FRAME_WIDTH, FRAME_HEIGHT ); idle = new Animation( 1, true ); idle.frames( film, 0, 0, 0, 1, 0, 0, 1, 1 ); run = new Animation( 20, true ); run.frames( film, 2, 3, 4, 5, 6, 7 ); die = new Animation( 20, false ); die.frames( film, 0 ); attack = new Animation( 15, false ); attack.frames( film, 13, 14, 15, 0 ); idle(); }
Example #6
Source File: ShopkeeperSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 5 votes |
public ShopkeeperSprite() { super(); texture( Assets.KEEPER ); TextureFilm film = new TextureFilm( texture, 14, 14 ); idle = new Animation( 10, true ); idle.frames( film, 1, 1, 1, 1, 1, 0, 0, 0, 0 ); run = idle.clone(); die = idle.clone(); attack = idle.clone(); idle(); }
Example #7
Source File: DungeonTilemap.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 5 votes |
public DungeonTilemap() { super( Dungeon.level.tilesTex(), new TextureFilm( Dungeon.level.tilesTex(), SIZE, SIZE ) ); map( Dungeon.level.map, Level.WIDTH ); instance = this; }
Example #8
Source File: BruteSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 5 votes |
public BruteSprite() { super(); texture( Assets.BRUTE ); TextureFilm frames = new TextureFilm( texture, 12, 16 ); // idle = new Animation( 2, true ); // idle.frames( frames, 0, 0, 0, 1, 0, 0, 1, 1 ); // // run = new Animation( 12, true ); // run.frames( frames, 4, 5, 6, 7 ); // // attack = new Animation( 12, false ); // attack.frames( frames, 2, 3, 0 ); // // die = new Animation( 12, false ); // die.frames(frames, 8, 9, 10); idle = new Animation( 2, true ); idle.frames( frames, 21, 21, 21, 22, 21, 21, 22, 22 ); run = new Animation( 12, true ); run.frames( frames, 25, 26, 27, 28 ); attack = new Animation( 12, false ); attack.frames( frames, 23, 24 ); die = new Animation( 12, false ); die.frames( frames, 29, 30, 31 ); cast = attack.clone(); play( idle ); }
Example #9
Source File: ShopkeeperGhostSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 5 votes |
public ShopkeeperGhostSprite() { super(); texture( Assets.KEEPER2); TextureFilm film = new TextureFilm( texture, 14, 14 ); idle = new Animation( 10, true ); idle.frames( film, 1, 1, 1, 1, 1, 0, 0, 0, 0 ); run = idle.clone(); die = idle.clone(); attack = idle.clone(); idle(); }
Example #10
Source File: DungeonTilemap.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 5 votes |
public DungeonTilemap() { super( Dungeon.level.tilesTex(), new TextureFilm( Dungeon.level.tilesTex(), SIZE, SIZE ) ); map( Dungeon.level.map, Level.WIDTH ); instance = this; }
Example #11
Source File: ShopkeeperTrollSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 5 votes |
public ShopkeeperTrollSprite() { super(); texture( Assets.KEEPER3); TextureFilm film = new TextureFilm( texture, 14, 14 ); idle = new Animation( 10, true ); idle.frames( film, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0 ); run = idle.clone(); die = idle.clone(); attack = idle.clone(); idle(); }
Example #12
Source File: GreatCrabSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public GreatCrabSprite() { super(); texture( Assets.CRAB ); TextureFilm frames = new TextureFilm( texture, 16, 16 ); 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 ); 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 ); play( idle ); }
Example #13
Source File: DemonLordSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public DemonLordSprite() { super(); texture( Assets.EVILLORD); TextureFilm frames = new TextureFilm( texture, 16, 16 ); idle = new Animation( 2, true ); idle.frames( frames, 0, 0 ); run = new Animation( 10, true ); run.frames( frames, 1, 2, 3 ); attack = new Animation( 14, false ); attack.frames( frames, 4, 5, 4 ); die = new Animation( 10, false ); die.frames( frames, 6, 7, 8 ); play( idle ); }
Example #14
Source File: BatSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public BatSprite() { super(); texture( Assets.BAT ); TextureFilm frames = new TextureFilm( texture, 15, 15 ); idle = new Animation( 8, true ); idle.frames( frames, 0, 1 ); run = new Animation( 12, true ); run.frames( frames, 0, 1 ); attack = new Animation( 12, false ); attack.frames( frames, 2, 3, 0, 1 ); die = new Animation( 12, false ); die.frames( frames, 4, 5, 6 ); play( idle ); }
Example #15
Source File: NecromancerSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public NecromancerSprite() { super(); texture( Assets.NECRO ); TextureFilm frames = new TextureFilm( texture, 12, 15 ); idle = new Animation( 8, true ); idle.frames( frames, 0, 0, 0, 1, 0, 0, 1, 1 ); run = new Animation( 12, true ); run.frames( frames, 2, 3, 4, 5, 6 ); attack = new Animation( 12, false ); attack.frames( frames, 12, 13, 14 ); die = new Animation( 12, false ); die.frames( frames, 7, 8, 9, 10, 11 ); play( idle ); }
Example #16
Source File: BuffIndicator.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
@Override protected void createChildren() { texture = TextureCache.get( Assets.BUFFS_SMALL ); film = new TextureFilm( texture, SIZE, SIZE ); }
Example #17
Source File: DM300Sprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public DM300Sprite() { super(); texture( Assets.DM300 ); TextureFilm frames = new TextureFilm( texture, 22, 20 ); idle = new Animation( 10, true ); idle.frames( frames, 0, 1 ); run = new Animation( 10, true ); run.frames( frames, 2, 3 ); attack = new Animation( 15, false ); attack.frames( frames, 4, 5, 6 ); die = new Animation( 20, false ); die.frames( frames, 0, 7, 0, 7, 0, 7, 0, 7, 0, 7, 0, 7, 8 ); play( idle ); }
Example #18
Source File: SlimeSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public SlimeSprite() { super(); texture(Assets.SLIME); TextureFilm frames = new TextureFilm(texture, 20, 14); idle = new Animation(10, true); idle.frames(frames, 2, 1, 0, 0, 1); run = new Animation(10, true); run.frames(frames, 3, 2, 1, 2); attack = new Animation(10, false); attack.frames(frames, 8, 9, 4, 9, 10); die = new Animation(10, false); die.frames(frames, 5, 6, 7); play(idle); }
Example #19
Source File: MinotaurSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public MinotaurSprite() { super(); texture( Assets.MINOTAUR ); TextureFilm frames = new TextureFilm( texture, 12, 15 ); idle = new Animation( 4, true ); idle.frames( frames, 0, 0, 0, 1 ); run = new Animation( 10, true ); run.frames( frames, 4, 5, 6, 5 ); attack = new Animation( 15, false ); attack.frames( frames, 0, 3, 2, 3, 0 ); die = new Animation( 10, false ); die.frames( frames, 7, 8, 9, 10 ); play( idle ); }
Example #20
Source File: WandmakerSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
public WandmakerSprite() { super(); texture( Assets.MAKER ); TextureFilm frames = new TextureFilm( texture, 12, 14 ); idle = new Animation( 10, true ); idle.frames( frames, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 3, 3, 3, 3, 3, 3, 2, 1 ); run = new Animation( 20, true ); run.frames( frames, 0 ); die = new Animation( 20, false ); die.frames( frames, 0 ); play( idle ); }
Example #21
Source File: EyeSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public EyeSprite() { super(); texture( Assets.EYE ); TextureFilm frames = new TextureFilm( texture, 16, 18 ); idle = new Animation( 8, true ); idle.frames( frames, 0, 1, 2 ); run = new Animation( 12, true ); run.frames( frames, 5, 6 ); attack = new Animation( 8, false ); attack.frames( frames, 4, 3 ); die = new Animation( 8, false ); die.frames( frames, 7, 8, 9 ); play( idle ); }
Example #22
Source File: ShamanSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
public ShamanSprite() { super(); texture( Assets.SHAMAN ); TextureFilm frames = new TextureFilm( texture, 12, 15 ); idle = new Animation( 2, true ); idle.frames( frames, 0, 0, 0, 1, 0, 0, 1, 1 ); run = new Animation( 12, true ); run.frames( frames, 4, 5, 6, 7 ); attack = new Animation( 12, false ); attack.frames( frames, 2, 3, 0 ); // cast = attack.clone(); die = new Animation( 12, false ); die.frames( frames, 8, 9, 10 ); play( idle ); }
Example #23
Source File: BuffIndicator.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
@Override protected void createChildren() { texture = TextureCache.get( Assets.BUFFS_SMALL ); film = new TextureFilm( texture, SIZE, SIZE ); }
Example #24
Source File: ElementalSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
public ElementalSprite() { super(); texture( Assets.ELEMENTAL ); TextureFilm frames = new TextureFilm( texture, 12, 14 ); idle = new Animation( 10, true ); idle.frames( frames, 0, 1, 2 ); run = new Animation( 12, true ); run.frames( frames, 0, 1, 3 ); attack = new Animation( 15, false ); attack.frames( frames, 4, 5, 6 ); die = new Animation( 15, false ); die.frames( frames, 7, 8, 9, 10, 11, 12, 13, 12 ); cast = attack.clone(); play( idle ); }
Example #25
Source File: LarvaSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
public LarvaSprite() { super(); texture( Assets.LARVA ); TextureFilm frames = new TextureFilm( texture, 12, 8 ); idle = new Animation( 5, true ); idle.frames( frames, 4, 4, 4, 4, 4, 5, 5 ); run = new Animation( 12, true ); run.frames( frames, 0, 1, 2, 3 ); attack = new Animation( 15, false ); attack.frames( frames, 6, 5, 7 ); die = new Animation( 10, false ); die.frames( frames, 8 ); play( idle ); }
Example #26
Source File: MonkSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
public MonkSprite() { super(); texture( Assets.MONK ); TextureFilm frames = new TextureFilm( texture, 15, 14 ); idle = new Animation( 6, true ); idle.frames( frames, 1, 0, 1, 2 ); run = new Animation( 15, true ); run.frames( frames, 11, 12, 13, 14, 15, 16 ); attack = new Animation( 12, false ); attack.frames( frames, 3, 4, 3, 4 ); kick = new Animation( 10, false ); kick.frames( frames, 5, 6, 5 ); die = new Animation( 15, false ); die.frames( frames, 1, 7, 8, 8, 9, 10 ); play( idle ); }
Example #27
Source File: SurfaceScene.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public Avatar( HeroClass cl ) { super( Assets.AVATARS ); frame( new TextureFilm( texture, WIDTH, HEIGHT ).get( cl.ordinal() ) ); }
Example #28
Source File: CrabSprite.java From unleashed-pixel-dungeon with GNU General Public License v3.0 | 4 votes |
public CrabSprite() { super(); texture( Assets.CRAB ); TextureFilm frames = new TextureFilm( texture, 16, 16 ); idle = new Animation( 5, true ); idle.frames( frames, 0, 1, 0, 2 ); run = new Animation( 15, true ); run.frames( frames, 3, 4, 5, 6 ); attack = new Animation( 12, false ); attack.frames( frames, 7, 8, 9 ); die = new Animation( 12, false ); die.frames( frames, 10, 11, 12, 13 ); play( idle ); }
Example #29
Source File: BurningFistSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
public BurningFistSprite() { super(); texture( Assets.BURNING ); TextureFilm frames = new TextureFilm( texture, 24, 17 ); idle = new Animation( 2, true ); idle.frames( frames, 0, 0, 1 ); run = new Animation( 3, true ); run.frames( frames, 0, 1 ); attack = new Animation( 8, false ); attack.frames( frames, 0, 5, 6 ); die = new Animation( 10, false ); die.frames( frames, 0, 2, 3, 4 ); play( idle ); }
Example #30
Source File: BlacksmithSprite.java From YetAnotherPixelDungeon with GNU General Public License v3.0 | 4 votes |
public BlacksmithSprite() { super(); texture( Assets.TROLL ); TextureFilm frames = new TextureFilm( texture, 13, 16 ); idle = new Animation( 15, true ); idle.frames( frames, 0, 0, 0, 0, 0, 0, 0, 1, 2, 2, 2, 3 ); run = new Animation( 20, true ); run.frames( frames, 0 ); die = new Animation( 20, false ); die.frames( frames, 0 ); play( idle ); }