Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - cmonroy

Pages: 1 2 [3]
PlayMaker Help / [SOLVED] Re: Aiming Routine Help
« on: May 14, 2014, 05:22:26 PM »
It is simple, really.

MousePick only works when there is an object at the pointed location, but no when there is no geometry at the designated vector. So, I built a room with walls and ceiling, put a little sphere (which works as my aiming point)  and used an FSM with a MousePick and a Set Position actions. A previous event set the cursor to a reticle and voilĂ : it worked...

Now, this solution will not work in open spaces unless you can provide some bounding planes at the edges of your level and increase accordingly the ray distance.

From here, making a raycast to the aiming point is easy. Hope this serves anyone having similar issues.

Jean: it is always a good idea to translate technical term and use them along the original one. The reason for this is that some concepts are more understandable: FSM are known in spanish as Máquinas de Estado Finito and as such it is easier to grasp the whole meaning and implications of this concept. After that, is is simple to use the abbreviation of Finite State Machines (FSM).

PlayMaker Help / Aiming Routine Help
« on: May 12, 2014, 05:04:46 AM »
Hello to all.

I have a setup in which the camera always follows my character from behind and I need it to aim to where the cursor or reticle is located. All the aiming routines I've checked, assume the target will be at the center of the screen or rotate the character to compensate this. The character is a GameObject which contains the mesh and the camera, along the FSM's to control its locomotion. I've set the main camera the get its position and the coordinates of the mouse at the X and Y axes. I've even made it to calculate the Screen to World Points and store its World vector, but I'm not really sure how to proceed.

Any advice will be greatly appreciated.

Thank you.

Android Help / Unity Dual Joystick Output to PlayMaker FSM: How to?
« on: April 12, 2014, 05:05:33 AM »

I have a basic scene in Unity: plane, light, camera, character and Dual Joystick prefab from Standard Assets (mobile). Using a remote controller installed in my Android device, I can control the joysticks and I have changes in the X-Y position of the control, as I can see in the Inspector.

My question is how can I pass the values at the Joysticks to an FSM in order to use them? Something like:

posx = left.joystick.position.x

Thank you.

Pages: 1 2 [3]