playMaker

Author Topic: Simple Object Rotation from Mouse Position...  (Read 553 times)

holyfingers

  • Playmaker Newbie
  • *
  • Posts: 27
  • 3D-artist and fledgling Unity Dev.
    • View Profile
    • holyfingers.co.uk
Simple Object Rotation from Mouse Position...
« on: October 20, 2016, 03:05:19 AM »
Hi there,

I've written up a short, simple tutorial for rotating an object in two, separate axes via mouse input: http://www.holyfingers.co.uk/main/blog/2016/10/19/on-the-turn/



You'll need the GetMouseDeltaPosition action from here: https://github.com/jeanfabre/PlayMakerCustomActions_U4/blob/master/Assets/PlayMaker%20Custom%20Actions/Input/GetMouseDeltaPosition.cs

I've attached the scene as well.

Cheers,

Nick
Twitter: @holyfingers

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 1356
    • View Profile
Re: Simple Object Rotation from Mouse Position...
« Reply #1 on: October 20, 2016, 08:49:57 AM »
Hi,
Great!
I have added it to the User Tutorials wiki

One thing tho.
You should avoid using Itween, it is outdated, very laggy and will be removed from playmaker in a future version.

You can look into DOTween and you can find the actions for it here
Greetings,
DjayDino.

Feel free to Donate me

Playmaker Discord Channel

More PM Tutorials : http://www.jinxtergames.com/

holyfingers

  • Playmaker Newbie
  • *
  • Posts: 27
  • 3D-artist and fledgling Unity Dev.
    • View Profile
    • holyfingers.co.uk
Re: Simple Object Rotation from Mouse Position...
« Reply #2 on: October 20, 2016, 10:09:07 AM »
Thanks for the heads up! I'll give DOTween a look over and update the tutorial when I get a moment!

Cheers,

Nick
Twitter: @holyfingers

holyfingers

  • Playmaker Newbie
  • *
  • Posts: 27
  • 3D-artist and fledgling Unity Dev.
    • View Profile
    • holyfingers.co.uk
Re: Simple Object Rotation from Mouse Position...
« Reply #3 on: October 24, 2016, 03:14:47 AM »
Updated the tutorial to include an alternative using DOTween:



Cheers,

Nick
Twitter: @holyfingers