playMaker

Author Topic: Camera Rotation Problem [VIDEO] [SOLVED]  (Read 110 times)

miguelfanclub

  • Playmaker Newbie
  • *
  • Posts: 34
    • View Profile
Camera Rotation Problem [VIDEO] [SOLVED]
« on: September 10, 2017, 03:25:55 PM »
Hi again.

Im improoving my character movement.
Character is moving 4m in fixed movement and rotating 90ยบ everytime you rotate.
It works perfectly using the keys.

Now Im trying to rotate the character also by moving the camera towards the edges of the screen (i have a tolerance to not to be too intrusive) so the character and the camera will auto rotate and player will be looking again to the center (0.0.0 self)

It works pretty well, but I have annoying behaviour that I cant fix.

I think its related to the mouselook script that the camera has attached.
I can reproduce the bug if I move the mouse while the "auto movement" is taking place. During the movement, "mouselook" is deactivated and I also control that no keys can be pressed, when movement is ended, "moselook" is again activated.

I could be sure if i can totally "disconect" the mouse imput while the movement is happening. Dont know.

In sec 10 you can clearly see what happens, also on 30.

Video Link:
https://youtu.be/ySxyfy1pkcg

Also, the scene doesn work when I build it (i cant rotate at all) so something must be wrong...
Any Idea?
Thanks!
« Last Edit: September 11, 2017, 11:44:14 AM by miguelfanclub »

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 2260
    • View Profile
    • jinxtergames
Re: Camera Rotation Problem [VIDEO]
« Reply #1 on: September 10, 2017, 08:17:53 PM »
Hi,
A next frame event might be useful after movement ended and before activating the mouse.

But i am not sure as i can't see the ohter fsm/states.

for build, what platform are you building to?
also do you have some Get/Set Properties actions?

miguelfanclub

  • Playmaker Newbie
  • *
  • Posts: 34
    • View Profile
Re: Camera Rotation Problem [VIDEO] [SOLVED]
« Reply #2 on: September 11, 2017, 11:44:01 AM »
Thanks djay. I was trying to investigate more and I discovered I was calling mouse look twice on an FSM and that was creating the issue. Now it works.

It drove me crazy yesterday after been working on the same stuff for like 15h.

Thanks

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 2260
    • View Profile
    • jinxtergames
Re: Camera Rotation Problem [VIDEO] [SOLVED]
« Reply #3 on: September 11, 2017, 07:10:24 PM »
Hi,
Yeah i know the feeling :)