this is the animation object
local specialObjectAnimation = {
{name = “bomb”, frames = {1,2}, time = 10, loopCount = 0},<—if here I change the frames only to 1( frames = {1} ) the hole things works
{name = “boom”, frames = {3,4,5,6}, time = 1600, loopCount = 1}
}
here I create the sprite object
options = {
width = 25,
height = 40,
numFrames = 6,
sheetContentWidth = 76,
sheetContentHeight = 81
};
specialObjectSheet = graphics.newImageSheet(“IMG/bomb.png”, options);
here I create the specialObject wich contains my animation and adding a dynamyc physic body and enabling the isSensor to true
local special = display.newSprite(group, specialObjectSheet, specialObjectAnimation);
physics.addBody(special, “dynamic”, {bounce = 0, radius = 20, isSensor = true});
special.angularVelocity = 200;
special.gravityScale = 0;
special.isSensor = true;
special.isHit = false
here is the fraction of the code for the collision event
elseif event.other.name == “special” then
if event.other.frame == 1 then
event.other:pause() <-- pausing the bomb animation
event.other:setSequence(“boom”);<-- setting it to the boom animation
event.other:setFrame(3)<-- start frame from 3
event.other:play()<— play
end
else
But all this should not be any reason not to work I belive this is the frame work