How can my event get the position inside group(current stage's position)?

I wonder that there are some ways to get the current position.

[lua]–a.lua

function new()
local a = display.newImage(“a.png”)

function touchHandle(e)
– print(e.phase)
if (e.phase == “began”) then
a.x = e.x;
a.y = e.y;
end

if (e.phase == “ended”) then
a.x = 10000;
a.y = 10000;
end
end

Runtime:addEventListener(“touch”, touchHandle);

return a;[/lua]

[lua]–main.lua
local camera = display.newGroup()
local a = require"a".new()
camera:insert(a);
–then follow with…cameraMoveHorizontal();[/lua]

Everytimes, I touched the screen, I found that the positions(x,y) of event did not much the current stage’s position. The value of event.x and event.y do not exceed screen’s size. While camera’s position is over screen’s size. I tried to find the references for solution but still get nothing.

Any help,thanks. [import]uid: 65906 topic_id: 15565 reply_id: 315565[/import]

Did you try printing a.x and a.y during both the “began” and “ended” phases? (And including event x and y in “began”?)

What were the results? [import]uid: 52491 topic_id: 15565 reply_id: 57473[/import]

@peach
the result is same [import]uid: 65906 topic_id: 15565 reply_id: 57477[/import]

The same as what?

It’s constantly the same and never changes? [import]uid: 52491 topic_id: 15565 reply_id: 57576[/import]

@peach

the result is same means the value is between 0-screen’s size.

But anyway, I figured out the solution. It is quite confusing and I encountered this problem when I used director class. My solution is using 2 groups. Add camera to another display group for director class.

Anyway, thanks for help [import]uid: 65906 topic_id: 15565 reply_id: 57760[/import]