Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7513517
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T00:12:32+00:00 2026-05-30T00:12:32+00:00

a real quick question here. It seems like super init has it’s own way

  • 0

a real quick question here. It seems like super init has it’s own way anchoring things around. Here is the example.
Below i have super init with sprite frame “image1”, and i have “image2” within the init. The problem is, these 2 images will not over-lapse each other as you would thought, it appears that the anchor point of init ‘image1’ is 0,0 and 0.5,0.5 for “image2” so the lower left edge of “image1” would be over-lapsing with the center of “image2”.

-(id) initWithSpriteImage
{
    if ((self = [super initWithSpriteFrameName:@"image1.png"]))
    {

        CCSprite *image2=[CCSprite spriteWithSpriteFrameName:@"image2.png"];
    }
    return self;

}

any idea how i can solve this beside removing the init sprite?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T00:12:35+00:00Added an answer on May 30, 2026 at 12:12 am

    Assuming image2 is a child of the image1 sprite, the behavior you see is correct. I wish it were different because it is a really annoying and hard to understand behavior for beginners.

    What happens is that child nodes are not centered on their parent’s anchorPoint, but on the origin (0,0) of the parent’s texture. So each child is centered on their parent’s lower-left corner, unless the parent is a non-visual node like CCScene, CCLayer or CCNode.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

this is a real quick question. Is their a way i could access Achievements
I'd like to build a real quick and dirty administrative backend for a Ruby
Quick question, which I think has a very easy solution for someone who has
All right real quick question guys. I know that C# Forms have the OnPaint()
Very quick question here. I was wondering if it is possible for me to
Real quick question - I must be blind or something. In SQL Server Mgmt
This is a real quick question, is it possible to allow Windows Authentication for
Have a quick question on iAd I would like to create a free app
Just a quick question. If I am happy with the way in which Android
I have a real simple question here. I only want to know if there

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.