Hey developers !
I am really enjoying cocos2d now, and my game is almost finished ! I hope you'll be able to download it from the appstore in a few weeks :) I hope you'll really appreciate it ! But I still get problems programming, and I have just one question ; I have to make CGRects to be able to do two CCSprites interact (for example when one hit the other, both disappear), so, here is the code I found in the documentation :
persoRect = CGRectMake(perso.position.x - (perso.contentSize.width/2), perso.position.y - (perso.contentSize.height/2), perso.contentSize.width, perso.contentSize.height); gateauRect = CGRectMake(gateau.position.x - (gateau.contentSize.width/2), gateau.position.y - (gateau.contentSize.height/2), gateau.contentSize.width, gateau.contentSize.height);
I am a bit confused because there is 4 parameters, could you please tell me what does each parameter correspond to ? Completing this :
rect = CGRectMake(firstParameterIs…, secondParameterIs…, thirdParameterIs…, fourthParameterIs…);
Thanks in advance for your help ! :)