On Tue, Aug 19, 2008 at 10:02 PM, Lucio Torre <[EMAIL PROTECTED]> wrote:
> As you are using your own images, you have to set the image anchor
> yourself at the center. when you create sprites using:
>
> sprite = Sprite("myimage.png")

I'm not sure when I should set the anchors on my images.

Something like this:

img = pyglet.resource.image("media\\img\\dispo-body.png")
img.anchor_x = img.width / 2
img.anchor_y = img.height / 2

?

I've tried iterate through my dictionary to set the anchors of the
images to the center, but it had no effect, the children are still
placed on the same point...

I'll fiddle with the code a little more to see if I can find where I'm
doing it wrong. Thanks for the advices!

-- 
Kao Cardoso Félix

Página pessoal: http://www.inf.ufrgs.br/~kcfelix
Blog: http://kaofelix.blogspot.com

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cocos2d discuss" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cocos-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to