Tagged Questions
-1
votes
0answers
23 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 ...
-2
votes
1answer
509 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
0answers
206 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
1k views
How to simulate a water splash effect?
I need to achieve the effect of a ball falling down into a pool then splashing in the water.
At first, I made a sensor to detect the collision between the ball and the water and then show the sprite ...
0
votes
1answer
363 views
Store and create game objects at positions along terrain
I have a circular character that rolls down terrain like that shown in the picture below.
The terrain is created from an array holding 1000 points. The ground is drawn one screen width infront and ...
0
votes
1answer
1k views
b2Body moves without stopping
I got a quite strange bug. It is difficult to explain it in two words, but i'll try to do this in short.
My b2Body has restitution, friction, density, mass and collision group.
I'm controlling my ...
0
votes
0answers
808 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 ...