Tagged Questions
-1
votes
0answers
22 views
Applying the vector of a swipe movement to a box2d object
Hi I'm trying to achieve game functionality where the player can place their finger on an object then swipe in a certain direction and apply the speed and velocity of the swipe to the object they have ...
0
votes
1answer
59 views
Cocos 2d move CCsprite in array of points [closed]
I need a CCsprite to move to the points in my array those points will form a circle.I know to move CCsprite but my app crashes when i make it to move in array of points. Help me where i am making ...
0
votes
1answer
20 views
Set texture of a LHSprite that is loaded from LevelHelper
How do i set the image/texture of an LHSprite that is loaded into xCode using levelHelper & spriteHelper?
I am using sprite sheets. So i tried to load the image the old fashioned way using ...
0
votes
0answers
40 views
How to select a show and select weapon on touch a bubble that changes continuously weapons! [closed]
hello i need to select a weapon from a floating bubble that changes weapon inside in it !
Bubble must show 2 weapons changing randomly until user taps to gain the weapon
(This lets user gain any bonus ...
0
votes
0answers
36 views
Image is displaying in inverse order cocos2d
I am drawing image in cocos2d using opengl call but image is displaying inverse order, i faced same problem previously that time i used to change value of CC_TEXTURE_NPOT_SUPPORT to 1 from 0 in ...
0
votes
0answers
27 views
Make a layer over an image and adjust its co-ordinates by touch
I need to make a layer over an image and adjust the layer to fit to image and get its co-ordinates of the layer.
I need to adjust the layer by touch and pinch.
The sample image is as below. I need ...
3
votes
0answers
63 views
Rotate an image and get back to its original position - opengles glkit
I need to rotate an image in opengles GLkit and get it back to its original position in GLkit.
rotation += 5;
_modelViewMatrix = GLKMatrix4Rotate( _modelViewMatrix, GLKMathDegreesToRadians(5), 1, 0, ...
1
vote
1answer
132 views
iOS game integrated with Facebook - Random game
How could I implement a random game for iOS via Facebook. I registered my game with Facebook and done everything so far... Can Facebook do such a thing?
EDIT
I connected my app to Facebook, I can ...
3
votes
4answers
239 views
What is technical specs for iOS platform for a game?
I would like to know when a contractor ask you for a technical specs for iOS platform of a game, what's the description that you should give back to him?
2
votes
1answer
228 views
Wheel rotation, to change velocity of vehicle
I update the velocity of my vehicle like so:
[v setVelocity: ((2 * 3.14 * 100 * (wheel.getRotationValue / 360) / 30)) * gameSpeed]; // update on 60 fps this gets velocity on all frames divide by 60 ...
0
votes
0answers
121 views
Cocos2d update leaking memory
I have a weird issue - my app is leaking memory on device only, not on a simulator. It is leaking if i schedule update method anywhere, on any scene. It is leaking despite update method is empty, ...
-2
votes
1answer
506 views
How change the size of sprite in cocos2d?
I want to change the scale of sprite like a paper in 'Paper Toss' game.
'Paper Toss' is the game is available on the App store. I want to make a sprite like a paper and change the scale of sprite ...
1
vote
2answers
250 views
How can I make a rectangle to an irregular shape?
I used masking for breaking an image into the below pattern. Now that it's broken into different pieces I need to make a rectangle of each piece. I need to drag the broken pieces and adjust to the ...
1
vote
0answers
205 views
Design pattern for procedural terrain assets
I'm developing a procedural terrain class at the moment and am stuck on the correct design pattern. The terrain is 2D and is constructed from a series of (x,y) points. I currently have a method that ...
0
votes
1answer
133 views
Changing location after CommitAnimations
I'm using the following code to move a UIImageView:
shootImg.image = [UIImage imageNamed:@"Projectile Left 1.png"];
[UIView beginAnimations:nil context:nil];
shootImg.center = ...
2
votes
1answer
133 views
How can I implement temporary effects in Objective-C?
How could I use this IBAction
-(IBAction)shield:(id)sender{
appDelegate.healthInt = 150;
}
and simply make it work for a limited time. I want to set appDelegate.healthint = 150 for about 20 ...
1
vote
0answers
179 views
Cocos2D and iPhone's accelerometer
good afternoon!
Today I've started to develop a game and I got a trouble. So, first at all I would like to say that I have no experience developing games...
So, I've a CCSprite in the layer and I ...
1
vote
0answers
113 views
Game Development Resources? [closed]
I want to make an iPhone game and I was wondering if somebody could point me to some resources. Before you rage and close this, I am not looking for just a tutorial on programming, I could just google ...
0
votes
1answer
326 views
Thread-safety in Cocos2d-iPhone?
After tinkering a bit with cocos2d, I discovered that there is no classic game loop and everything is more-or-less event driven. I guess I can wrap my head around that, no problem.
But I cannot find ...
1
vote
2answers
593 views
How do I repeatedly move an image by 1 pixel?
I have a method that is moving a UIImageView called shootImg across the screen:
-(IBAction)shoot{
if (appDelegate.shootInt > 0) {
if (direction == 1) {
shootImg.center = ...
2
votes
1answer
823 views
Best Method to Create Side Scrolling Levels? - Cocos2D
I am looking to start my first side scroller project using Cocos2D, but I am curious. What is the preferred/best method of creating you levels? For large levels I see hand making it very laborious, is ...
1
vote
3answers
938 views
Detecting End of Animation
So I am making a death animation for a game. enemy1 is a UIImageView, and what I'm doing is when an integer is less than or equal to zero, it calls this deathAnimation which only happens once. What I ...
4
votes
2answers
309 views
Aggro with Images
I have three UIImageViews. enemy1, enemy1AggroBox and mainSprite. What I want to do is when
mainSprite and enemy1AggroBox interect, I want enemy1 to start moving towards mainSprite. Basically ...
-1
votes
1answer
167 views
CGPointMake in Respect to other UIImageViews
I have a UIImageView called hitBox, and another image called mainSprite. So what I want to do is when an IBAction is pressed, it will move hitBox to above mainSprite. I don't know if this is syntax ...
5
votes
2answers
567 views
Best way to do buttons for an OpenGL ES iPhone game
I'm making a simple 2d game in OpenGL ES and I want to add movement buttons to it. What's the best way of going about this? In previous projects I've simply added UIButtons to the view but I hear ...
0
votes
1answer
2k views
Cocos2d CCSpriteFrameCache: couldn't load texture file
I am currently doing this Cocos2d tutorial: http://www.raywenderlich.com/1271/how-to-use-animations-and-sprite-sheets-in-cocos2d
...and get the following error messages:
2011-12-30 16:36:28.536 ...
2
votes
2answers
2k views
How to implement “Flick” gesture for throwing an object in the 2D realm
I am trying to implement a FLICK gesture for throwing a ball from point A to point B on the iPhone. This is my current plan....
Using touchesBegan and touchesEnd I can find the direction I need to ...
0
votes
0answers
806 views
Cocos2d Box2d how to shoot an object inside the screen [closed]
I have the code below :
- (id) initWithGame:(mainGame*)game {
if ((self = [super init])) {
isTouchEnabled_ = YES;
self.game = game;
CGSize size = [[CCDirector ...
0
votes
0answers
188 views
objective-c iphone sdk dragging between a boundary box
I was thinking of make a slider/joystick but not in a circle but in a line.
So I made the image drag able only over the X axis and when it gets to the point
where the slider stops i did this :
...
0
votes
1answer
334 views
objective-c iphone sdk side scrolling
I was making a game and I did the side scrolling like this: if the player get past 150, the player stops moving and the background starts moving. But thats very annoying with placing objects in the ...
0
votes
3answers
393 views
How can I spawn multiple monsters in my game?
I made a little iPhone game in which I want to make multiple monsters spawn.
I have one UIImageView called enemy that spawns at beginning of the game. But I want it to spawn many more monsters until ...
3
votes
1answer
388 views
How can I spawn monsters at random locations?
I made a little 2D shooter game for my iPhone. I want monsters to spawn at random locations.
But I don't have any clue where to start to make them spawn.
I already made the monster image and ...
1
vote
1answer
786 views
Detecting right/left collisions with a bounding box
I'm building a platformer in cocos2d, my first game project. I'm working on movement and collision detection. I'm using a tilemap with a "meta" layer of invisible blocks that are designated ...
-1
votes
1answer
596 views
Help: -[GameScene spiderBelowScreen]: unrecognized selector sent to instance 0x257f50
I am currently doing the tutorials in the book: "learn iPhone and iPad cocos2d Game Development" by Steffen Itterheim and have been running into problems with the code for the DoodleDrop tutorial, ...
4
votes
2answers
573 views
How to design a leaderboard?
This sounds like an easy thing but when I considering the following
Many players
Some have played many games and some just started
Different type of statistics
On what information should the ...
1
vote
4answers
351 views
How do I randomly create and store enemy data for my iPhone game?
In my game you need to protect something from enemies. There can be many on the screen at once. But I don't know how to create the enemies randomly, and how I can save the data to each enemy? Can give ...
1
vote
2answers
368 views
Connect 4 Iphone game
I'm new to game development and development in general, I want to make a Connect 4 game. I have made a few simple game tutorials and I decided I wanted to make my own game now. I figured a connect 4 ...
12
votes
5answers
2k views
Tools for generating texture atlases/sprites from source images? [closed]
Is there an industry standard file format for texture atlases?
What are the apps that take a directory of images and turns it into a texture atlas png and a text file describing what's on it?
This ...
7
votes
6answers
2k views
Storing game state at exit on the iPhone with Objective-C
How would you store your game state at exit for an iPhone game written in Objective-C?

