playMaker

Author Topic: Falling Detector Problems[SOLVED]  (Read 2501 times)

Rabagast

  • Hero Member
  • *****
  • Posts: 683
    • Homepage
Falling Detector Problems[SOLVED]
« on: January 14, 2015, 04:20:45 PM »
I have a fall detector which check if the player is grounded or not. When it's not grounded, I disable the jump FSM and play the animation falling, but when I have many platform tiles after each other, and the player cross the platforms, then it runs the FSM on the falling detector which disable the jump FSM. So that mean the player is not grounded while he is crossing the platforms. Is it a way to solve this? Or another way to do this?
« Last Edit: January 19, 2015, 01:45:44 AM by jeanfabre »
Check out our homepage. http://www.walsberg.no
Or my personal game blog for news about my games. http://retro-tetro.walsberg.no

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2511
  • Mender of the past
    • Cleverous
Re: Falling Detector Problems
« Reply #1 on: January 15, 2015, 11:18:34 AM »
Make sure your platform colliders are touching. Gaps would cause the grounded check to flip.
Products by Cleverous
|| Vault Core : Database
|| Vault Inventory : Multiplayer Inventory
|| Vault Attributes : Character Stats
|| That Hurt! : Dmg Floaties
|| Quinn : 3D

Rabagast

  • Hero Member
  • *****
  • Posts: 683
    • Homepage
Re: Falling Detector Problems
« Reply #2 on: January 16, 2015, 08:18:17 AM »
It's no gaps between the platforms, but I fixed that problem.

I discovered another problem also.
Sometimes when the player walks over to the next platform (tile) it collides with the collider of the platform and the player stop the movement. It's very strange, because it's only happen now and then. I hate this kind of problem. It's so difficult to solve.

I can run and jump on the platform without any problems, but suddenly it stops on the collider as it should be an obstacle. Then if I jump or move to the other direction and then back, then it doesn't stop.
Check out our homepage. http://www.walsberg.no
Or my personal game blog for news about my games. http://retro-tetro.walsberg.no

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: Falling Detector Problems
« Reply #3 on: January 16, 2015, 08:30:37 AM »
Hi,

 Is it not a problem of logic more than collisions? are you sure you don't have any variable checks that prevents inputs to operate? or is it 100% a physics simulation issue with colliders?

 Bye,

 Jean

Rabagast

  • Hero Member
  • *****
  • Posts: 683
    • Homepage
Re: Falling Detector Problems
« Reply #4 on: January 16, 2015, 11:09:53 AM »
Hi, Jean!
I don't know, but I use a fall detector which check if the player is falling. I use a trigger. When it's grounded I play the animation idle. When it's not grounded, I play the animation falling. I also disable the jumping when the jump FSM is finished and enable it again when the player is grounded. And this fsm runs every time I cross the platforms.

I found an easy solution. Just use ProCore's Prototype I downloaded from Asset Store. Then I don't need to use many tiles after each other. Works like a dream. :-)


Check out our homepage. http://www.walsberg.no
Or my personal game blog for news about my games. http://retro-tetro.walsberg.no

Rabagast

  • Hero Member
  • *****
  • Posts: 683
    • Homepage
Re: Falling Detector Problems[SOLVED]
« Reply #5 on: January 22, 2015, 01:43:52 PM »
I think I found the problem why the player sometimes stops between the platform tiles. I'm not really sure yet. I test it right now.
But do you think it can be the Box Collider 2D I use? I changed it to a Circle Collider 2D. So far it works good. :-)
Check out our homepage. http://www.walsberg.no
Or my personal game blog for news about my games. http://retro-tetro.walsberg.no

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2511
  • Mender of the past
    • Cleverous
Re: Falling Detector Problems[SOLVED]
« Reply #6 on: January 22, 2015, 01:44:50 PM »
It's a known issue in the 2d collider from what I've read. Had the same problem, there are some relevant threads on the Unity forums.
Products by Cleverous
|| Vault Core : Database
|| Vault Inventory : Multiplayer Inventory
|| Vault Attributes : Character Stats
|| That Hurt! : Dmg Floaties
|| Quinn : 3D