Im trying to create a timer in Cocos2d in which an object is created and deleted 5 seconds after it is created. Does anyone know how to make this?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I’m assuming you mean you are trying to delete a CCSprite when you said object. You setup a timer to call a method which then deletes the sprite by the tag number that you assigned it when you created the sprite (lets pretend you assigned the tag number 10 for the example below)