Mouse Button Down Enter/Leave Problem
Posted: Thu Jan 05, 2006 4:17 am
I am working on an isometric maze game. When the player clicks the ground actor (tile actor) the player character move to the location. This script all works great.
The problem is that GE does not seem to accurately detect if the mouse click occurs on the ground actor.
During debug I created a Mouse Enter event that sets the ground transparency to 50% and a Mouse Leave event that sets the ground transparency to 100%. This way when GE detects that the mouse is over the ground it makes it transparent and when the mouse leaves the ground returns to solid.
When this test is executed GE only turns the ground transparent when the mouse is over specific parts of a tile graphic. I have tried 32 bit graphics and 24 bit graphics to see if it was specific to the transparency. Same result. The tiles are squares rotated 45degrees to form diamonds. Thus they have transparent areas in each corner. All the pixels in the diamond area are fully opaque.
Using a filled region actor that covers the screen does work fine with mouse inputs. But I only want the player to move when the ground is clicked. Also I want to be able to do other things when other actors are clicked but the same problem exists for them too.
Anybody have any thoughts?
Thanks.
The problem is that GE does not seem to accurately detect if the mouse click occurs on the ground actor.
During debug I created a Mouse Enter event that sets the ground transparency to 50% and a Mouse Leave event that sets the ground transparency to 100%. This way when GE detects that the mouse is over the ground it makes it transparent and when the mouse leaves the ground returns to solid.
When this test is executed GE only turns the ground transparent when the mouse is over specific parts of a tile graphic. I have tried 32 bit graphics and 24 bit graphics to see if it was specific to the transparency. Same result. The tiles are squares rotated 45degrees to form diamonds. Thus they have transparent areas in each corner. All the pixels in the diamond area are fully opaque.
Using a filled region actor that covers the screen does work fine with mouse inputs. But I only want the player to move when the ground is clicked. Also I want to be able to do other things when other actors are clicked but the same problem exists for them too.
Anybody have any thoughts?
Thanks.