mouse hit over 3d entities

All things HTML5 or text based engines, or really any web based engines.
Post Reply
User avatar
stokaboka
Posts: 8
Joined: Fri Oct 18, 2013 5:51 am

mouse hit over 3d entities

Post by stokaboka »

Hi!

mouseOver, mouseUp, mouseLeave fire over red box...
how to make fire mouse events inside 3d bounds (green line area) ?
User avatar
coolbloke1324
Posts: 181
Joined: Mon Jan 23, 2012 5:20 pm

Re: mouse hit over 3d entities

Post by coolbloke1324 »

stokaboka wrote:Hi!

mouseOver, mouseUp, mouseLeave fire over red box...
how to make fire mouse events inside 3d bounds (green line area) ?
Hi ya!

I have updated the engine to allow for mouse picking / intersection checking with iso-3d bounds. The updates have been pushed to the dev branch in the premium repo, version 1.2.8.

You can see how it works in example 14.1-isoobjects as you move the mouse over the isometric objects they are highlighted.

To make mouse events work based on the 3d bounds you can just set:

Code: Select all

entity.mouseEventTrigger('isoBounds');
This will tell the engine to check the mouse pointer against the iso 3d bounds of the object instead of it's default AABB.

Let me know if that works ok and if that is what you needed!
CEO & Lead Developer
Irrelon Software Limited
http://www.isogenicengine.com
User avatar
stokaboka
Posts: 8
Joined: Fri Oct 18, 2013 5:51 am

Re: mouse hit over 3d entities

Post by stokaboka »

thanks Rob!

Code: Select all

entity.mouseEventTrigger('isoBounds');
it works perfectly, exactly as expected )

but.... I can use v1.2.8 @ 2013-10-22.002 a production application ?
this is dev branch...
User avatar
coolbloke1324
Posts: 181
Joined: Mon Jan 23, 2012 5:20 pm

Re: mouse hit over 3d entities

Post by coolbloke1324 »

Hey ya. Yes that should be fine. This version has been tested and it did not break any existing functionality.

The dev branch will be merged into master next week.
CEO & Lead Developer
Irrelon Software Limited
http://www.isogenicengine.com
User avatar
stokaboka
Posts: 8
Joined: Fri Oct 18, 2013 5:51 am

Re: mouse hit over 3d entities

Post by stokaboka »

ok, thanks )
alex_king92
Posts: 12
Joined: Fri Aug 30, 2013 9:21 am

Re: mouse hit over 3d entities

Post by alex_king92 »

Hi, I've just downloaded again the engine, but it has downloaded v1.2.4@2013-10-07.001 version and not the latest you told.
alex_king92
Posts: 12
Joined: Fri Aug 30, 2013 9:21 am

Re: mouse hit over 3d entities

Post by alex_king92 »

Found! xD Really great update!
User avatar
coolbloke1324
Posts: 181
Joined: Mon Jan 23, 2012 5:20 pm

Re: mouse hit over 3d entities

Post by coolbloke1324 »

alex_king92 wrote:Found! xD Really great update!
Thanks :)
CEO & Lead Developer
Irrelon Software Limited
http://www.isogenicengine.com
Post Reply

Return to “HTML5/Web Engines”