Problems with SetEmitterTarget()

So I spawn my enemies using some simple spawn code and add them to a table.

Then in my game loop I have

[lua]if enemies[1] then

Particles.SetEmitterTarget( “smallShipFiring1”, enemies[1], false, 0, 0, 0 )

end

if enemies[2] then

Particles.SetEmitterTarget( “smallShipFiring2”, enemies[2], false, 0, 0, 0 )

end

if enemies[3] then

Particles.SetEmitterTarget( “smallShipFiring3”, enemies[3], false, 0, 0, 0 )

end

if enemies[4] then

Particles.SetEmitterTarget( “smallShipFiring4”, enemies[4], false, 0, 0, 0 )

end

if enemies[5] then

Particles.SetEmitterTarget( “smallShipFiring5”, enemies[5], false, 0, 0, 0 )

end[/lua]

This basically works ok except the new x&y offset features don’t work at all. They do nothing and also when flip my enemies (they travel left and right) with enemies[i].xScale = -1. Then they fire all sorts of crazy. Goes really fast, but just sound, no particles. Any Ideas?

[lua]if enemies[i].type == “royalNavy” then

if playerIsAttacking then

if enemies[i].underAttack == true then

enemies[i]:translate( 0, 0 )

elseif enemies[i].playerSpotted == true then

enemies[i]:translate( -0.1, 0 )

elseif enemies[i].x >= _xPlayer then

enemies[i]:translate( speedLeft, 0 )
enemies[i].xScale = 1

else

enemies[i]:translate( speedRight, 0 )
enemies[i].xScale = -1

end

else

enemies[i]:translate( speedLeft, 0 )
enemies[i].xScale = 1

end

end[/lua] [import]uid: 26289 topic_id: 21070 reply_id: 321070[/import]