The problem is - when i load game on iphone some sprites are shown, some are not, plus CCBitmapFontAtlas labels and CCMenu button are also not visible and when i tap on the place where button have to be - there is no effect. At simulator it worked just fine. What is the reason of such strange situation?
IPad aslo works ok.
...
hi,
I am writing a game in iPad using cocos2d.
I need to mix two actions,
One action is, to get the rotation of the object. I have 10 images of the rotation of an object. When we animate them we get the rotation of the object.
Second action is to move the object from one edge to other edge. I am able to get one action after the other.
...
I have done a game in cocos2d. I used English. How do I translate that game to other languages like French, Japanese, etc.?
...
Hi
I have 10 images a ball of same size. I need to show the ball animation. The ball animation should start image1 and should end with image10.
I want to show that the ball is travelled far from the throwing position. So, I need to show that the images at the end of animation are small.
For this I manually resized the images of the ball...
Is it possible to run .gif file in cocos2d for iphone
...
Hi!
Is there way to do the shadow for CCSprite?
Thanks,
Yakov
...
Hello,
How to catapult animation in cocos2d.
Iam doing animation of streching stick like rubber, does not get any luck yet,
anyone knows please help.
Thank You.
...
How would one detect a touch on a rotated CCSprite?
I am familiar with the general technique of using ccTouchesBegan and contentSize, anchorPoint etc. to have a sprite detect if a touch was within its bounds ... but I am not sure how to proceed once the sprite has been rotated by some angle.
I want the sprite itself to detect the touch...
I'm working on an iPhone game that uses the accelerometer for control. I don't have an Apple Developer Program user yet, so I can't test it on my device, so I'm trying to give the game some accelerometer values depending on where I tap on the screen.
What I tried to do:
I tried to have the middle of the screen as a mid point, then the o...
Hey,
I Have the following code:
-(void) changeAnimation:(NSString*)name forTime:(int) times {
if(currentAnimation != @"attack")
{
id action = [CCAnimate actionWithAnimation:[self animationByName:name]];
id repeatAction = [CCRepeat actionWithAction:action times:times];
currentAction = [self runAction:repeatAction];
lastANimati...
I want to use photos from photo library in my game. How to make the file to be of size 280x280.
Is it possible to take the picture (captured by the camera immediately without saving) and then modify the picture and want to save
...
Hi, i'm having a little problem here and i cant figure out whats wrong.
I have a simple setup. A CCLayer-subclass, in it's init-method I initialize a CCSpriteSheet and add it as child to the layer.
- (id)init {
...
enemySprites = [CCSpriteSheet spriteSheetWithFile:@"rock1.png"];
enemies = [[NSMutableDictionary alloc] init];
[self ad...
Hello,
I'm creating an app for the Iphone and i'm using Cocos2d.
As part of the help menu, i want to redirect the user to a site when they click a link. Is it possible to do in cocos2d?
Thank you!
...
I'm new to development and I have played around with a few tutorials. I wonder what the best way to set up a menu for a game with cocos2d?
I want a MainMenu with a Startbutton, SettingsButton, HighScoresButton and a little info/creditsButton in the corner.
How should I set this up?
Should I have the MainMenu as a Scene and the others ...
Basically i have an array of Sprites to be loaded and removed one by one in an order.
I have a list of animal names in an array like
const NSString *Animal1[30] = {@"Lion .png",@"Zebra .png",...........
To load a sprite i use the following code
image[i]= [Sprite spriteWithFile: [NSString stringWithFormat:@"%@",Animal1[i]]];
image[i]...
Hi,
What is the recommended way to do basic clipping with cocos2d?
I am developing a tab control for an educational product and I want the items on a tab page to be clipped by that tab page. So any CCSprites on the CCNode that IS the tab page should be clipped to that CCNode?
Any help would be appreciated ...
...
Hi,
I have a LAYER class and created a protocol:
@protocol countryControllerDelegate
-(void)didReceiveGamePlayTimeWarning;
@end
And i make use of that delegate in a CocosNode class.
#import "protocolClass.h"
myClass: CocosNode [countryControllerDelegate] {
But there is an error that "cannot find protocol declaration ".
Is ...
when i put my game in ipad, the alertview seems to be very small. Is it possible to change the fontsize and increase the width and height of the alertview.
...
Hi all, i am adding overlays to a cocos2d layer in preparation for a screenshot...
CGSize winSize = [[CCDirector sharedDirector] winSize];
CCScene* currentScene = [[CCDirector sharedDirector] runningScene];
GameLayer* topLayer = (GameLayer *)[currentScene.children objectAtIndex:0];
CCSprite *middleBackground = [CCSprite spriteWith...
Hi,
I have created a "normal" app - initially without cocos2d. Now I need cocos2d in this app. So I added all the frameworks that are included when creating a cocos2d app and just copied the cocos2d group from another project by dragging it to my project.
For the init for cocos2d I get the application's window in an ivar of the ViewCon...