<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>cocos2d for iPhone &#187; Tag: sprites - Recent Posts</title>
		<link>http://www.cocos2d-iphone.org/forum/tags/sprites</link>
		<description>A fast, easy to use, free, and community supported 2D game engine</description>
		<language>en-US</language>
		<pubDate>Fri, 10 Feb 2012 02:51:53 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://www.cocos2d-iphone.org/forum/search.php</link>
		</textInput>
		<atom:link href="http://www.cocos2d-iphone.org/forum/rss/tags/sprites" rel="self" type="application/rss+xml" />

		<item>
			<title>realfolkblues12 on "Initializing multiple subclassed sprites of the same kind from tiled"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/17180#post-143267</link>
			<pubDate>Wed, 08 Feb 2012 13:30:38 +0000</pubDate>
			<dc:creator>realfolkblues12</dc:creator>
			<guid isPermaLink="false">143267@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Something along these lines worked for me.</p>
<p>        self.theMap = [CCTMXTiledMap tiledMapWithTMXFile:MapFile.tmx];<br />
        self.bgLayer = [theMap layerNamed:@"bg"];<br />
        self.overLayer = [theMap layerNamed:@"over"];<br />
        self.stLayer = [theMap layerNamed:@"st"];<br />
        stLayer.visible = NO;<br />
        [self addChild:theMap];<br />
        [self reorderChild: overLayer];</p>
<p>CCTMXObjectGroup * tileMapObjects = [theMap objectGroupNamed:@"oj"];</p>
<p>        NSMutableDictionary * hummingBirdDic = [tileMapObjects objectNamed:@"hummingBird"];</p>
<p>        for (hummingBirdDic in [tileMapObjects objects]) {<br />
			if ([[hummingBirdDic valueForKey:@"name"] isEqualToString:@"hummingBird"]){<br />
                int x = [[hummingBirdDic valueForKey:@"x"]intValue];<br />
                int y = [[hummingBirdDic valueForKey:@"y"]intValue];<br />
                CCSPRITE * spriteGFX = [CCSprite spriteWithFile:@"hummingBird.png"];<br />
                [self addChild:spriteGFX];<br />
			}<br />
		}
</p></description>
		</item>
		<item>
			<title>Harrison Xi on "Additive Coloring Solution? Thoughts?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/20487/page/2#post-142275</link>
			<pubDate>Thu, 02 Feb 2012 09:45:02 +0000</pubDate>
			<dc:creator>Harrison Xi</dc:creator>
			<guid isPermaLink="false">142275@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Shader Program can help me to implement the effect I want. :)
</p></description>
		</item>
		<item>
			<title>Harrison Xi on "Additive Coloring Solution? Thoughts?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/20487/page/2#post-142239</link>
			<pubDate>Thu, 02 Feb 2012 03:37:11 +0000</pubDate>
			<dc:creator>Harrison Xi</dc:creator>
			<guid isPermaLink="false">142239@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Hi @<a href='http://www.cocos2d-iphone.org/forum/profile/1915'>Par</a> &#38; @<a href='http://www.cocos2d-iphone.org/forum/profile/72718'>plugboy</a>,</p>
<p>I tried to use glTexEnvi in cocos2d-iphone, but it did not work. Did I miss something? Here are my codes, could you help to take a look?<br />
<pre><code>@implementation CCSpriteTint

@synthesize colorOpacity = colorOpacity_;

-(void) draw
{
	CC_PROFILER_START_CATEGORY(kCCProfilerCategorySprite, @&#34;CCSprite - draw&#34;);

	NSAssert(!batchNode_, @&#34;If CCSprite is being rendered by CCSpriteBatchNode, CCSprite#<a href='http://www.cocos2d-iphone.org/forum/tags/draw'>draw</a> SHOULD NOT be called&#34;);

	CC_NODE_DRAW_SETUP();

	// set blend func
	ccGLBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA );

	// enable
	glActiveTexture( GL_TEXTURE0 );
	glEnable( GL_TEXTURE_2D );

	ccGLBindTexture2D( [texture_ name] );

	// set color
	float tinting[4] = { color_.r/255.0f, color_.g/255.0f, color_.b/255.0f, colorOpacity_/255.0f };
	glTexEnvfv(GL_TEXTURE_ENV, GL_TEXTURE_ENV_COLOR, tinting);

	// texEnvi
	glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_COMBINE);
	glTexEnvi(GL_TEXTURE_ENV, GL_COMBINE_RGB,      GL_ADD);
	glTexEnvi(GL_TEXTURE_ENV, GL_SRC0_RGB, GL_PREVIOUS); // color
	glTexEnvi(GL_TEXTURE_ENV, GL_SRC1_RGB, GL_TEXTURE); // texture

	//
	// Attributes
	//

	ccGLEnableVertexAttribs( kCCVertexAttribFlag_PosColorTex );

#<a href='http://www.cocos2d-iphone.org/forum/tags/define'>define</a> kQuadSize sizeof(quad_.bl)
	long offset = (long)&#38;quad_;

	// vertex
	NSInteger diff = offsetof( ccV3F_C4B_T2F, vertices);
	glVertexAttribPointer(kCCVertexAttrib_Position, 3, GL_FLOAT, GL_FALSE, kQuadSize, (void*) (offset + diff));

	// texCoods
	diff = offsetof( ccV3F_C4B_T2F, texCoords);
	glVertexAttribPointer(kCCVertexAttrib_TexCoords, 2, GL_FLOAT, GL_FALSE, kQuadSize, (void*)(offset + diff));

	// color
	diff = offsetof( ccV3F_C4B_T2F, colors);
	glVertexAttribPointer(kCCVertexAttrib_Color, 4, GL_UNSIGNED_BYTE, GL_TRUE, kQuadSize, (void*)(offset + diff));

	glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);

	CHECK_GL_ERROR_DEBUG();

#<a href='http://www.cocos2d-iphone.org/forum/tags/if'>if</a> CC_SPRITE_DEBUG_DRAW == 1
	// draw bounding box
	CGPoint vertices[4]={
		ccp(quad_.tl.vertices.x,quad_.tl.vertices.y),
		ccp(quad_.bl.vertices.x,quad_.bl.vertices.y),
		ccp(quad_.br.vertices.x,quad_.br.vertices.y),
		ccp(quad_.tr.vertices.x,quad_.tr.vertices.y),
	};
	ccDrawPoly(vertices, 4, YES);
#elif CC_SPRITE_DEBUG_DRAW == 2
	// draw texture box
	CGSize s = self.textureRect.size;
	CGPoint offsetPix = self.offsetPosition;
	CGPoint vertices[4] = {
		ccp(offsetPix.x,offsetPix.y), ccp(offsetPix.x+s.width,offsetPix.y),
		ccp(offsetPix.x+s.width,offsetPix.y+s.height), ccp(offsetPix.x,offsetPix.y+s.height)
	};
	ccDrawPoly(vertices, 4, YES);
#endif // CC_SPRITE_DEBUG_DRAW

	// reset
	glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
	glBlendFunc( CC_BLEND_SRC, CC_BLEND_DST );

	CC_PROFILER_STOP_CATEGORY(kCCProfilerCategorySprite, @&#34;CCSprite - draw&#34;);
}

@end</code></pre></description>
		</item>
		<item>
			<title>mruffa on "Disappearing graphics (CCSprite) on NOT debug"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28710#post-141509</link>
			<pubDate>Fri, 27 Jan 2012 10:55:25 +0000</pubDate>
			<dc:creator>mruffa</dc:creator>
			<guid isPermaLink="false">141509@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Hey gyus,</p>
<p>I'm developing games on cocos2d for a while, but in the newest game I got something strange. </p>
<p>On debug everything works fine, otherwise some of graphics - CCSprite  - are disappearing.</p>
<p>Anybody been there? :)</p>
<p>thanks!
</p></description>
		</item>
		<item>
			<title>breskit on "removing sprite in array help?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/22192#post-141361</link>
			<pubDate>Thu, 26 Jan 2012 14:50:07 +0000</pubDate>
			<dc:creator>breskit</dc:creator>
			<guid isPermaLink="false">141361@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>This post is 3 months old!  I hope he has removed it.</p>
<p>You can't remove objects from an array as you cycle upwards through the array.  Either loop through descending, or add the items to be removed into a holding array and then remove them implicitly in a separate loop.
</p></description>
		</item>
		<item>
			<title>elsevero on "removing sprite in array help?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/22192#post-141352</link>
			<pubDate>Thu, 26 Jan 2012 13:17:28 +0000</pubDate>
			<dc:creator>elsevero</dc:creator>
			<guid isPermaLink="false">141352@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@<a href='http://www.cocos2d-iphone.org/forum/profile/57656'>goodeats2009</a>: Have you solved your issue?
</p></description>
		</item>
		<item>
			<title>elsevero on "removing sprites in order"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28681#post-141328</link>
			<pubDate>Thu, 26 Jan 2012 09:01:22 +0000</pubDate>
			<dc:creator>elsevero</dc:creator>
			<guid isPermaLink="false">141328@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Hello guys,</p>
<p>I've been searching for a solution for my finding objects game but couldn't find anything yet; What I must deal is that I have couple of objects that are placed on top of each other and I need to remove them in a certain order (in this case it will be the z order).<br />
How do I manage the objects that are placed in two layers which have been added to a parallaxNode? </p>
<p>any examples or tips for this will be nice!
</p></description>
		</item>
		<item>
			<title>polatolu on "Sprite Master"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28564#post-140680</link>
			<pubDate>Sun, 22 Jan 2012 17:52:02 +0000</pubDate>
			<dc:creator>polatolu</dc:creator>
			<guid isPermaLink="false">140680@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Not yet but it will have.</p>
<p>You can take a look at FAQ page (<a href="http://www.mobinodo.com/spritemaster/faq.html" rel="nofollow">http://www.mobinodo.com/spritemaster/faq.html</a>) for next feature and roadmap. Also, I'm accepting feature requests, this will give a right shape to the application.</p>
<p>If we talk about 'now', there is no better features for all of the applications but partially yes. I don't want to talk about differences between those application because it's not ethical for me.</p>
<p>Thanks.
</p></description>
		</item>
		<item>
			<title>boolWerk Software on "Sprite Master"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28564#post-140678</link>
			<pubDate>Sun, 22 Jan 2012 17:35:20 +0000</pubDate>
			<dc:creator>boolWerk Software</dc:creator>
			<guid isPermaLink="false">140678@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Does this have any benefits over for example texture packer or zwoptex or texturehelper?</p>
<p>Thanks
</p></description>
		</item>
		<item>
			<title>polatolu on "Sprite Master"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28564#post-140672</link>
			<pubDate>Sun, 22 Jan 2012 16:42:57 +0000</pubDate>
			<dc:creator>polatolu</dc:creator>
			<guid isPermaLink="false">140672@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Hi Guys,</p>
<p>I want to talk about Sprite Master. Sprite Master is a sprite sheet generator for Mac. It generates sprite sheets using Basic and MaxRects algorithms. Also, generates coordinate data, exports .plist for Cocos2D.</p>
<p>If you are interested, you can take a look at <a href="http://www.mobinodo.com/spritemaster" rel="nofollow">http://www.mobinodo.com/spritemaster</a> for more details.
</p></description>
		</item>
		<item>
			<title>jellyfish on "How do I get a sprite to leave &quot;prints&quot; of itself that fade out."</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28002#post-140152</link>
			<pubDate>Thu, 19 Jan 2012 03:51:09 +0000</pubDate>
			<dc:creator>jellyfish</dc:creator>
			<guid isPermaLink="false">140152@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I found a Tutorial that teaches how to do this:</p>
<p><a href="http://mobile.tutsplus.com/series/build-a-caterpillar-game-with-cocos2d/" rel="nofollow">http://mobile.tutsplus.com/series/build-a-caterpillar-game-with-cocos2d/</a>
</p></description>
		</item>
		<item>
			<title>Par on "Additive Coloring Solution? Thoughts?"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/20487/page/2#post-139509</link>
			<pubDate>Sat, 14 Jan 2012 15:45:01 +0000</pubDate>
			<dc:creator>Par</dc:creator>
			<guid isPermaLink="false">139509@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@<a href='http://www.cocos2d-iphone.org/forum/profile/72718'>plugboy</a>, The last post I have here pretty much describes the solution, the only thing you really need is a way to change the tinting amount. You could change setColor to take alpha as well but instead I chose to simply create a colorOpacity variable. I've had issues with getting the alpha to work as well when it comes to additive combining the textures. I haven't spent a lot of time trying to solve that issue because I don't need it yet. However, the code I'm using for tinting allows you to fade sprites in and out no problem.</p>
<p>If you are having problems with setOpacity not working though, it's likely because the way you are combining the textures, at least from my experience.</p>
<p><strong>Here check out the article I just wrote on it, should solve your problem: <a href="http://digitallybold.com/314/cocos2d-additive-sprite-color-tinting" rel="nofollow">http://digitallybold.com/314/cocos2d-additive-sprite-color-tinting</a></strong></p>
<p>Hope this helps.
</p></description>
		</item>
		<item>
			<title>Duckwit on "[TUTORIAL/GUIDE] Additive Sprite Coloring &amp; Tinting"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28333#post-139443</link>
			<pubDate>Fri, 13 Jan 2012 21:30:04 +0000</pubDate>
			<dc:creator>Duckwit</dc:creator>
			<guid isPermaLink="false">139443@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I'd really like to know how to change the Hue of graphics, just like in Flash.<br />
Any idea how that works? :)
</p></description>
		</item>
		<item>
			<title>rakkarage on "[TUTORIAL/GUIDE] Additive Sprite Coloring &amp; Tinting"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28333#post-139425</link>
			<pubDate>Fri, 13 Jan 2012 20:00:24 +0000</pubDate>
			<dc:creator>rakkarage</dc:creator>
			<guid isPermaLink="false">139425@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>thanks! :)
</p></description>
		</item>
		<item>
			<title>Par on "[TUTORIAL/GUIDE] Additive Sprite Coloring &amp; Tinting"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28333#post-139418</link>
			<pubDate>Fri, 13 Jan 2012 19:34:14 +0000</pubDate>
			<dc:creator>Par</dc:creator>
			<guid isPermaLink="false">139418@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I just finished a tutorial on setting up new sprite classes that will use setColor to modify the sprites colors in different ways from normal. Here's the link: <a href="http://digitallybold.com/314/cocos2d-additive-sprite-color-tinting" rel="nofollow">http://digitallybold.com/314/cocos2d-additive-sprite-color-tinting</a></p>
<p>The tutorial explains how to subclass CCSprite and change the OpenGL texture rendering so that setColor produces different effects. For example: </p>
<pre><code>[sprite setColor:ccc3(0, 0, 255)];</code></pre>
<p>produces different things based on the way your texture environment is set up allowing you to have additive coloring and even tinting. As seen below:<br />
<img src="http://digitallybold.com/wp-content/uploads/2012/01/coloring1.png" /></p>
<p>Likewise you can take the tinting and apply it in lesser amounts to produce different effects like below:<br />
<img src="http://digitallybold.com/wp-content/uploads/2012/01/coloring2.png" /></p>
<p>Anyway, I know this has been asked for in the past so I wanted to share how I've been able to do it. Here's the link again: <a href="http://digitallybold.com/314/cocos2d-additive-sprite-color-tinting" rel="nofollow">http://digitallybold.com/314/cocos2d-additive-sprite-color-tinting</a></p>
<p>Thanks, I hope this helps. I'd love to see someone take the openGL and come up with some different effects.
</p></description>
		</item>
		<item>
			<title>SeruK on "Universal iOS App - iPad scaling issues"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28065#post-139043</link>
			<pubDate>Wed, 11 Jan 2012 11:16:39 +0000</pubDate>
			<dc:creator>SeruK</dc:creator>
			<guid isPermaLink="false">139043@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Hi knightkrows,<br />
I eventually ended up just having two sets of graphics, SD and HD. All the sprites are placed in the middle, and the backgrounds are placed so that they cover up the areas clipped on an iPhone. I just make sure not to place anything of importance in those particular areas.
</p></description>
		</item>
		<item>
			<title>JC on "How do I get a sprite to leave &quot;prints&quot; of itself that fade out."</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28002#post-139025</link>
			<pubDate>Wed, 11 Jan 2012 09:00:33 +0000</pubDate>
			<dc:creator>JC</dc:creator>
			<guid isPermaLink="false">139025@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>To have a sprite behind another one, it must be added before. the draw are done in the "addchild" order, so first add, first display and the last are the top most.</p>
<p>you can create sprite, without "addchild" it and do all addchild at the end of the method, that way, you can manage who are on top and who are on bottom.</p>
<p>i think the best way for you to learn "game programming", is to buy some books, on cocos 2D programming or on "general" game programming.
</p></description>
		</item>
		<item>
			<title>jellyfish on "How do I get a sprite to leave &quot;prints&quot; of itself that fade out."</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28002#post-139006</link>
			<pubDate>Wed, 11 Jan 2012 05:34:39 +0000</pubDate>
			<dc:creator>jellyfish</dc:creator>
			<guid isPermaLink="false">139006@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>@<a href='http://www.cocos2d-iphone.org/forum/profile/57377'>JC</a> I need more help figuring out how to apply your method to my code above.  The only thing I could think of (being so new to this), is to duplicate my code to create a "myBox1" to follow "myBox". </p>
<p>'CCSprite *myBox = [CCSprite node];<br />
        [myBox setTextureRect:CGRectMake(0, 20, 8, 8)];<br />
        [myBox setPosition:ccp(160, 340)];<br />
        [myBox setAnchorPoint:ccp(.5,10)];</p>
<p>        [myBox setColor:ccGREEN];<br />
        [self addChild:myBox];</p>
<p>        id rotate1 = [CCRotateBy actionWithDuration:0 angle:15];<br />
        id delay = [CCDelayTime actionWithDuration:.1];</p>
<p>        [myBox runAction:[CCRepeatForever actionWithAction:[CCSequence actions:rotate1, delay, nil]]];</p>
<p>		CCSprite *myBox1 = [CCSprite node];<br />
        [myBox1 setTextureRect:CGRectMake(0, 20, 8, 8)];<br />
        [myBox1 setPosition:ccp(160, 340)];<br />
        [myBox1 setAnchorPoint:ccp(.5,10)];</p>
<p>        [myBox1 setColor:ccc3(0, 255, 255)];<br />
        [self addChild:myBox1];</p>
<p>        id rotate2 = [CCRotateBy actionWithDuration:0 angle:15];<br />
        id delay2 = [CCDelayTime actionWithDuration:.1];</p>
<p>        [myBox1 runAction:[CCRepeatForever actionWithAction:[CCSequence actions:rotate2, delay2, nil]]];'</p>
<p>Now how do I get it so "myBox1" is not on top of "myBox", but one step behind.</p>
<p>Having no background in programming, even this simple task is hard to figure out for me.  Even though there are a lot of tutorials on YouTube, its hard to find one that discusses my specific situation.  I have also been searching (without success) for a school nearby that teaches cocos2d.  If I had a professor that could show me how to do the specific things I want to do, my progress would be much accelerated.  I want to know, how others, like yourself, learned when you were just starting out.  Any advice I can get, from more experienced programmers, is much appreciated.</p>
<p>Thank You.
</p></description>
		</item>
		<item>
			<title>knightkrows on "Universal iOS App - iPad scaling issues"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28065#post-138193</link>
			<pubDate>Thu, 05 Jan 2012 16:36:12 +0000</pubDate>
			<dc:creator>knightkrows</dc:creator>
			<guid isPermaLink="false">138193@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Hi,<br />
I found this as a best approach up to now. </p>
<p><a href="http://www.raywenderlich.com/2560/how-to-create-a-mole-whacking-game-with-cocos2d-part-1" rel="nofollow">http://www.raywenderlich.com/2560/how-to-create-a-mole-whacking-game-with-cocos2d-part-1</a></p>
<p>I used this same concept for following universal games</p>
<p><a href="http://itunes.apple.com/app/house-no.13" rel="nofollow">http://itunes.apple.com/app/house-no.13</a>!!/id435333789?mt=8<br />
<a href="http://itunes.apple.com/us/app/the-night-of-santa/id483218121?mt=8" rel="nofollow">http://itunes.apple.com/us/app/the-night-of-santa/id483218121?mt=8</a></p>
<p>I used two types of graphics only:<br />
1.normal graphics<br />
2.Retina graphics</p>
<p>The only additional iPad graphics were required for only background images. Rest all frames of retina graphics were used as iPad graphics.</p>
<p>Thanks,<br />
knightkrows
</p></description>
		</item>
		<item>
			<title>SeruK on "Universal iOS App - iPad scaling issues"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28065#post-138141</link>
			<pubDate>Thu, 05 Jan 2012 10:20:52 +0000</pubDate>
			<dc:creator>SeruK</dc:creator>
			<guid isPermaLink="false">138141@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I kind of do, and I think I'm going with a similar approach. Make the backgrounds a wee bit larger, see to it that nothing of importance are in the areas that are not visible on the iPhones.
</p></description>
		</item>
		<item>
			<title>JC on "Universal iOS App - iPad scaling issues"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28065#post-138134</link>
			<pubDate>Thu, 05 Jan 2012 09:36:01 +0000</pubDate>
			<dc:creator>JC</dc:creator>
			<guid isPermaLink="false">138134@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>in my apps, i'm using ipad texture in retina instead of retina texture in ipad, because of the ratio of the screen. and use the same 'ratio' (ipad ratio) for non retina iphone (so the background will be a little to big for non retina iphone) to make it easier to manage all assets.</p>
<p>with that, i only have to scale done on iphone my image by 640/768, and prevent using the left/right part of the image which is not visible on iphone.</p>
<p>all my coords are based on the center of the image and placed in the "background image" space (ex : -1, -1 is the left bottom on ipad, but is not visible on iphone). so i'm in a reduced normalized space and use only position for X from - 0.9f to 0.9f.</p>
<p>i don't know if you understand what i mean :X in my head, it's clear :D
</p></description>
		</item>
		<item>
			<title>tetna on "Simple Collision Detection for Newbie"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28053#post-138127</link>
			<pubDate>Thu, 05 Jan 2012 08:33:03 +0000</pubDate>
			<dc:creator>tetna</dc:creator>
			<guid isPermaLink="false">138127@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>PROBLEM SOLVED :)
</p></description>
		</item>
		<item>
			<title>jellyfish on "How do I get a sprite to leave &quot;prints&quot; of itself that fade out."</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28002#post-138074</link>
			<pubDate>Thu, 05 Jan 2012 04:21:17 +0000</pubDate>
			<dc:creator>jellyfish</dc:creator>
			<guid isPermaLink="false">138074@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>"An array of sprites" and "snake games": Thank you, I did a search on both of these and lots of results came up.  I am in the process of going through them, one by one, to learn how others are doing it.<br />
  "Merci Beaucoup!" : )
</p></description>
		</item>
		<item>
			<title>SeruK on "Universal iOS App - iPad scaling issues"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28065#post-137995</link>
			<pubDate>Wed, 04 Jan 2012 17:49:16 +0000</pubDate>
			<dc:creator>SeruK</dc:creator>
			<guid isPermaLink="false">137995@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>I am currently working on a universal app with Cocos2D and I have some questions about scaling. I have already dealt with the positioning issue thanks to this guy (<a href="http://michaelgilkes.info/cocos2d-using-hd-images-for-ipad-in-a-universal-app/" rel="nofollow">http://michaelgilkes.info/cocos2d-using-hd-images-for-ipad-in-a-universal-app/</a>), but I want to stretch the -hd textures to cover up the iPad window.</p>
<p>i.e. for my 'root' class (which inherits CCSprite) I do this after initializing:<br />
<pre><code>if(IS_IPAD())
        {
            self.scaleX = kIpadScaleXRatio;
            self.scaleY = kIpadScaleYRatio;
        }</code></pre>
<p>I already know the bounding box method fails to take scaling into account so I overrode it:<br />
<pre><code>- (CGRect)boundingBox
{
    CGRect rect = CGRectMake(self.position.x, self.position.y, self.contentSize.width*self.scaleX, self.contentSize.height*self.scaleY);

    CGRect returnRect = CGRectApplyAffineTransform(rect, [self nodeToParentTransform]);

    return CC_RECT_PIXELS_TO_POINTS(returnRect);
}</code></pre>
<p>None of this seems to work perfectly, since my 640x960 texture doesn't actually cover up the entire window. I really want to avoid a third set of textures for the iPad version.</p>
<p>Would this approach even work? Or am I making a total arse of myself? If it actually would work, is there anything else to consider but the boundingBox method?</p>
<p>Thanks in advance.
</p></description>
		</item>
		<item>
			<title>tetna on "Simple Collision Detection for Newbie"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28053#post-137936</link>
			<pubDate>Wed, 04 Jan 2012 10:36:03 +0000</pubDate>
			<dc:creator>tetna</dc:creator>
			<guid isPermaLink="false">137936@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>i get error about the CC when i change it to Sprite it dont have any errors
</p></description>
		</item>
		<item>
			<title>breskit on "Simple Collision Detection for Newbie"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28053#post-137934</link>
			<pubDate>Wed, 04 Jan 2012 10:32:15 +0000</pubDate>
			<dc:creator>breskit</dc:creator>
			<guid isPermaLink="false">137934@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Hmmm...</p>
<p>If you have this line in your project </p>
<p><code>CCSprite *target = [CCSprite spriteWithFile:@&#34;waa.png&#34;];</code></p>
<p>and it gives you a compile error, it sounds like your project is a bit foobar.
</p></description>
		</item>
		<item>
			<title>tetna on "Simple Collision Detection for Newbie"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28053#post-137933</link>
			<pubDate>Wed, 04 Jan 2012 10:29:09 +0000</pubDate>
			<dc:creator>tetna</dc:creator>
			<guid isPermaLink="false">137933@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>yes i do.. and CC still dont work XD
</p></description>
		</item>
		<item>
			<title>breskit on "Simple Collision Detection for Newbie"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28053#post-137931</link>
			<pubDate>Wed, 04 Jan 2012 10:22:37 +0000</pubDate>
			<dc:creator>breskit</dc:creator>
			<guid isPermaLink="false">137931@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>you do have the #<a href='http://www.cocos2d-iphone.org/forum/tags/import'>import</a> 'cocos2d.h' at the top of your layer/scene right?</p>
<p>If you are getting errors for every CC-related reference, is sounds like you are missing the import.<br />
Cocos2D uses a CC prefix on most (if not all) of it's methods/classes and these should not be generating errors.
</p></description>
		</item>
		<item>
			<title>tetna on "Simple Collision Detection for Newbie"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28053#post-137929</link>
			<pubDate>Wed, 04 Jan 2012 10:12:27 +0000</pubDate>
			<dc:creator>tetna</dc:creator>
			<guid isPermaLink="false">137929@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>as i said i just downloaded this open source app.. it has a cocos2d in it. but everytime i call CC it says that it is undeclared i am thinking that the cocos2d of this app is old? dont you think
</p></description>
		</item>
		<item>
			<title>breskit on "Simple Collision Detection for Newbie"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/28053#post-137928</link>
			<pubDate>Wed, 04 Jan 2012 10:10:43 +0000</pubDate>
			<dc:creator>breskit</dc:creator>
			<guid isPermaLink="false">137928@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>Is Sprite your own class?  I don't recognise this as a Cocos2D class.
</p></description>
		</item>

	</channel>
</rss>

