Skip to content

Instantly share code, notes, and snippets.

@sdabet
Created March 1, 2013 09:51
Show Gist options
  • Save sdabet/5063619 to your computer and use it in GitHub Desktop.
Save sdabet/5063619 to your computer and use it in GitHub Desktop.
Usage of getChildByTagRecursive
// Define the tags
#define CLOUDS_TAG 1
// Load node hierarchy from CocosBuilder file
CCNode *background = [CCBReader nodeGraphFromFile:@"background.ccbi"];
// Recursively find node by tag
CCNode *clouds = [background getChildByTagRecursive:CLOUDS_TAG];
// Do stuff with the node
// ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment