little editor bug -> parenting

Non-platform specific questions.

little editor bug -> parenting

Postby sonicfire » Sat Mar 26, 2011 9:50 pm

hi there!

just discovered that when you have an actor somewhere on the screen and set it to "parent -> view" then close the window, open it again, choose "parent-> none" for the same actor, it pops / reverts to 0,0 in coordinate space :)

intended or a bug?

cheers !
sonicfire
 
Posts: 425
Joined: Wed Nov 01, 2006 9:34 pm
Location: berlin germany
Score: 16 Give a positive score

Re: little editor bug -> parenting

Postby Kodo » Sat Mar 26, 2011 9:55 pm

I found that you can avoid it popping back to 0,0 if after you change the parent to 'none' you just select and hold the mouse button down on the actor as though to drag it for a second then release. It does seem like a bug to me, or at least I haven't thought of a reason why it should reset its position.
Inogames: http://www.inogames.com iOS gaming
Firetop Adventure (app store): http://itunes.apple.com/us/app/firetop- ... ?mt=8&ls=1
User avatar
Kodo
 
Posts: 449
Joined: Thu Oct 20, 2005 8:20 pm
Location: UK
Score: 23 Give a positive score

Re: little editor bug -> parenting

Postby Game A Gogo » Sat Mar 26, 2011 10:07 pm

What happens is the coordinate are not transformed, since when an actor is parented to another actor, the child actor has his x and y coordinates relative to it's parent.

Lets say the view was at (40,20) and another actor at (40,40). When you parent the actor to the view, it's coordinate will become (0,20). but if you remove the parent, the coordinates are unchanged... so it will become (0,20) relative to game center instead of view.

So yes, this is a bug. And like kodo said a way to fix this is to drag an object by a pixel before moving the working area around
Programming games is an art,
    Respect it.
User avatar
Game A Gogo
 
Posts: 3466
Joined: Wed Jun 29, 2005 10:49 pm
Location: French Canada *laughs*
Score: 181 Give a positive score

Re: little editor bug -> parenting

Postby sonicfire » Mon Mar 28, 2011 10:58 am

Thanks guys :) It´s not annoying me or something - just wanted to let you know.
sonicfire
 
Posts: 425
Joined: Wed Nov 01, 2006 9:34 pm
Location: berlin germany
Score: 16 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest