3
votes
1answer
257 views
cocos2d sprite animation
Hi all,
How can I change an image position like background-position in css? By position I don't mean the position of background like ccp(200,150), I mean for example, I have an ima …
1
vote
2answers
202 views
Replacing image in sprite - cocos2d game development of iphone
I want to change the sprite image.
Say for example.
mainSprite=[Sprite spriteWithFile:@"redFile.png"];
[self addChild:mainSprite];
Here, Sprite is already added to a layer.
I h …
2
votes
1answer
83 views
Moving Sprites (more then one) at a time
-(void)moveBox:(NSTimer*)myTimer{
float endx=[[[myTimer userInfo] valueForKey:@"endX"] floatValue];
float endy=[[[myTimer userInfo] valueForKey:@"endY"] floatValue];
float timin …