Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

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.
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.

1 decade ago by Jerczu

You sure all your frames are spaced properly and are 24x24px?

1 decade ago by dahl

Yeah, they were ok. i'm not sure what it was but eventually all the graphics started acting like that. i had to end up reinstalling the browser and that seemed to fix it. Thanks for the input though Jerczu.
Page 1 of 1
« first « previous next › last »