≡
Products
▼
Support
▼
Company
▼
Forum
Ambiera Forum
Discussions, Help and Support.
Create a new account
,
Search
, or Login:
Create reply in
createClone() problems - still
Posted by:
(you are not logged in)
Enter the missing letter in: "Internation?l"
(you are not logged in)
Text:
[quote][b]csp-games[/b] wrote: As it happens so often, we find a solution right after asking. The cloning thing is solved, my code just sucketh, but the missing collision on the clones is still a game stopper, any ideas? BTW here's the code that works: [code] // find entity var mytree=ccbGetSceneNodeFromName("my_pinetree1"); // entityxyz var myvec_old=mytree.getAbsolutePosition(); var myvec=cam.getAbsolutePosition(); //copyentity var mytree2=mytree.createClone(scene.getRootSceneNode(),mytree.Id,mytree.Id+count_trees);// worked count_trees+=1; // that's a global myvec.Z-=40; myvec.Y=myvec_old.Y; mytree2.Pos=myvec; mytree2.updateAbsolutePosition(); [/code] I added this to the example that allows to shoot a cube at the wall (collision example), so I can walk around and just plant trees, pretty cool, but I really need collision.[/quote]
Possible Codes
Feature
Code
Link
[url] www.example.com [/url]
Bold
[b]bold text[/b]
Image
[img]http://www.example.com/image.jpg[/img]
Quote
[quote]quoted text[/quote]
Code
[code]source code[/code]
Emoticons
Copyright© Ambiera e.U. all rights reserved.
Privacy Policy | Terms and Conditions | Imprint | Contact