playMaker

Author Topic: Character angled to the ground glitching  (Read 1890 times)

Mitsuray

  • Playmaker Newbie
  • *
  • Posts: 4
Character angled to the ground glitching
« on: May 26, 2021, 07:35:34 PM »
Hello everyone ! I keep lurking this forums for help and usually I end up succeeding with whatever I needed through previous posts, having that said I just can't seem to fix this issue :


The project was more complex but I tried recreating an extra simple version of my character to try and pinpoint the problem but to no avail. As soon as the character land anywhere else (besides the starting point) it starts glitching as seen on the gif (sometimes later stabilizing)

I am basically Raycasting towards the floor, storing the Hit Normal, created a vector3 thats 0,1,0 to get vectorUp, Get Quaternion From Rotation (from vectorUp to hitNormal) storing the result and setting the rotation of my child (the character itself) with this result.



I am also storing if the Raycast hit anything or not, if it didn't, it'll change the State to a new one where it resets the character's rotation so it's standing vertically until the Raycast gets a hit once again. (these 2 are always jumping from one to another as soon as the glitching starts, logically)



The Empty Object "pivotAngle" is centered to the character while the "lePivot" is standing in front of it on the Z axis, this is used in combination with Look At 2 so lePivot is always oriented towards where the character should turn with Get Axis Vector while the character has a Smooth Look At towards lePivot so then it moves locally in the Z direction.

Thanks in advance, if any further information is needed just say so.
:)
« Last Edit: May 28, 2021, 06:09:24 PM by Mitsuray »

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7618
    • jinxtergames
Re: Character angled to the ground glitching
« Reply #1 on: May 28, 2021, 09:29:04 AM »
Hi.
The link is not showing your gif.

Mitsuray

  • Playmaker Newbie
  • *
  • Posts: 4
Re: Character angled to the ground glitching
« Reply #2 on: May 28, 2021, 10:20:47 AM »
Strange, tried changing the link a little, tell me if it works now.

Sorry for the inconvenience.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7618
    • jinxtergames
Re: Character angled to the ground glitching
« Reply #3 on: May 28, 2021, 02:33:38 PM »
Hi.
Now it can not be reached "This site can’t be reached" message

maybe try imgur (gif) or youtube (mp4)

Mitsuray

  • Playmaker Newbie
  • *
  • Posts: 4
Re: Character angled to the ground glitching
« Reply #4 on: May 28, 2021, 06:10:07 PM »
Okay, recorded and uploaded on youtube, sorry for the trouble :)

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7618
    • jinxtergames
Re: Character angled to the ground glitching
« Reply #5 on: May 29, 2021, 04:32:53 PM »
Hi.
Can you show the states/actions?

Mitsuray

  • Playmaker Newbie
  • *
  • Posts: 4
Re: Character angled to the ground glitching
« Reply #6 on: May 29, 2021, 06:32:43 PM »
When the raycast hits anything (grounded):




If the raycast doesn't hit anything :



The states can be seen on the video, it's literally just the 2 bouncing from one to another (from Angling to Vertical)

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7618
    • jinxtergames
Re: Character angled to the ground glitching
« Reply #7 on: May 30, 2021, 07:21:16 AM »
Hi.
i can not see the raycast action settings.

Its probably also better to separate the raycast in a separate Fsm and store a bool

Then on the other fsm use 'Fsm Bool Test' ([urlhttps://hutonggames.fogbugz.com/default.asp?W1181]Ecosystem[/url])