ambiera logo

Ambiera Forum

Discussions, Help and Support.

folder icon Ambiera Forum > CopperLicht
forum topic indicator Detecting nearby Nodes
person icon
elmario
Registered User
Quote
2014-09-01 14:22:06

I'm trying to find out when a SceneNode falls inside the radius of another SceneNode. I'm using the following methods from the API


var handleProximity = function(){
console.log('now near your scene node!');
}

var animator = new CL3D.AnimatorOnProximity(_this._scene, 5000, 'PlayerMesh', handleProximity, true);

mesh.addAnimator(animator);


but when the "mesh" and PlayerMesh are right next to eachother the HandleProximity function is not called. I've checked the names, ids and everything, but it's not working correctly, the callback function is never called.

_this._scene = _this._engine.getScene();

Any ideas?

person icon
niko
Moderator
Quote
2014-09-01 19:40:13

Hi,
you also asked this via mail, I just answered you. But here again, maybe someone else might have the same problem:

Maybe it is because you set the last parameter to 'true', which means that it triggers when you leave the radius again. BTW, 5000 is usually a pretty big radius, so maybe that's why?


Create reply:










 

  

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


icon_holyicon_cryicon_devilicon_lookicon_grinicon_kissicon_monkeyicon_hmpf
icon_sadicon_happyicon_smileicon_uhicon_blink   






Copyright© Ambiera e.U. all rights reserved.
Contact | Imprint | Products | Privacy Policy | Terms and Conditions |