HI can some one suggest me how can i drag the sprite image which I am creating on click of HUD object.
i am able to drag the sprites which i have created from the tiled map within object layer by registering them like me.pool.register("mainPlayer", game.playerdrag);
But i am not able to drag the sprite even if i am registering in pool.
have a look on my code
onClick: function (event) {
console.log("clicked!");
// me.collision.check();
camera = new me.Sprite(500, 500, {
image: "building_64_64-02",
framewidth: 134,
frameheight: 134,
});
me.pool.register("camera", game.playerdrag);
me.game.world.addChild(camera, 10, game.playerdrag);
....
....
....
}