1 decade ago by dahl
My entity is a plasmaball that i took pics of here at the house and turned into png images to use for my animation. when i play the animation the first frame is the ball, but all the next frames turn it into a cylinder that bounces around the screen.
that's all the code i have, i'm pretty sure it's not that. and i used the png from jump/run as a guide, plus the skull png i made works great. not sure whats up. any help would be great. thanks.
ig.module(
'game.entities.plasmaball'
)
.requires(
'impact.entity'
)
.defines(function(){
EntityPlasmaball = ig.Entity.extend({
size: {x:24, y:24},
collides: ig.Entity.COLLIDES.ACTIVE,
animSheet: new ig.AnimationSheet( 'media/plasmaball.png', 24, 24 ),
bounciness: 2,
init: function( x, y, settings ) {
this.parent( x, y, settings );
this.addAnim( 'idle', .3, [0,1,2,3,4,5,6,7,6,5,4,3,2,1] );
this.vel.x = -200;
this.vel.y = 100;
}
});
});
that's all the code i have, i'm pretty sure it's not that. and i used the png from jump/run as a guide, plus the skull png i made works great. not sure whats up. any help would be great. thanks.
