4

I am creating an 3d car racing game and till now i have integrated accelerometer and i can move the car through the city the only thing now remaining in my game is collision detection ... i want to stop my car when it bangs on wall etc ...

how can i do that ? i know boundingVolume property ,but i am having an city(3d world as a single node ) and car so how can detect when it collides wall etc ?

please can you tell me what should be my approach ? any sample code? please help as i am new to this and don't have any experience in it ...

Thanks Amrut

Amrut
  • 55
  • 5

1 Answers1

2

Now cocos3d is on 0.6.2 version and as you know official site wrote that "simple collision detection" not supported yet! (big trouble) They want to implement it in 0.7 version.

But I think it is better for you to save your city locations in the file and when your car moved to each street you detect it and load some part of city locations into some variables and now detect "simple collision detection" by hand.

I hope it works for you!

Hamed Rajabi Varamini
  • 3,439
  • 3
  • 24
  • 38
  • ok Thanks Hamed,is there any other way to check collision detection because save your city locations and checking will be lot complicated – Amrut Nov 08 '11 at 07:42
  • As far as I know no one can do that without doing this complicated work! For doing this pretty good you need to take a part your world to children nodes and after detecting your car direction and position load some of these objects of world. – Hamed Rajabi Varamini Nov 08 '11 at 09:22
  • So can you tell about the improvements in cocos3d 0.7. I want to add collision detection in Laser game – Karan Alangat Aug 03 '13 at 06:43
  • @KaranAlangat I'm so sorry because i'm not working on Cocos3d for two years. – Hamed Rajabi Varamini Aug 06 '13 at 05:30