Search Unity

i have problem OnTriggerStay2D, it don't call Frequently and i don't know why , someone help me????

Discussion in '2D' started by fire1991man, May 8, 2015.

  1. fire1991man

    fire1991man

    Joined:
    May 31, 2013
    Posts:
    18
    i have 2 cell object like pic 1. i attact FallScript like pic 2. when it colision i see log like below:

    _allowFall: True
    OnTriggerEnter2D
    _allowFall: True
    OnTriggerStay2D
    _allowFall: False
    OnTriggerStay2D
    _allowFall: False
    OnTriggerStay2D
    _allowFall: False
    OnTriggerStay2D
    _allowFall: False
    OnTriggerStay2D
    _allowFall: False
    then ..
    _allowFall: False
    _allowFall: False
    _allowFall: False
    _allowFall: False
    _allowFall: False
    _allowFall: False
    _allowFall: False

    I don'tt know OnTriggerStay2D don't call more. can Someone help me???
     

    Attached Files:

  2. mgear

    mgear

    Joined:
    Aug 3, 2010
    Posts:
    9,445
    Maybe the Rigidbody2D goes to sleep.
    Try other sleeping modes.

    Or why do you need to have OnTriggerStay2D() called more times?
     
  3. fire1991man

    fire1991man

    Joined:
    May 31, 2013
    Posts:
    18
    thx you , i want to test some function in unity . i change spleeping modes to never sleep and it call frequently. thx you so much