Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: nrefzen on March 13, 2014, 01:26:50 PM
-
I'm new to Unity and Playmaker. I was working on a project, the idea is to have a room where if you click on an object (see image attached) the result will be a switch to a different camera, a second click on the object will result in a simple action for the object, for example, the laptop rotates. A third click would return to the main camera.
I have added a FSM to a specific object, using GET MOUSE BUTTON DOWN, to facilitate this. I'm able to get the camera change, action and return to original state working. However I want this to only happen when I click on the object. Instead if I click anywhere on the scene the action still happens. If i Add FSM to another object, it overrides the previous action and only the new FSM works.
Where am I going wrong, how can i make sure the action only takes place when i click on the object only.
Any help would be gratefully appreciated. Please let me know if any more data will be useful.
-
You can use Mouse Pick for this, store the object, do a compare and send the event you want.
-
Hi,
also, are you sure you are only receiving mouse events on the object you clicked, and not a general mouse click, unrelated to what's beneath it?
bye,
Jean