Hello!
I'm using a custom physics interaction system, and to make things simpler, I want to use this physics sistem's own footstep system. But, for that, I must call a function from another script right here: (The script is CharacterFootEffects)
But for some reason I can't call any function from any script.
The function that I must call is this one:
(I'm using the latest version of UCC V2)
How can I fix that?
I'm using a custom physics interaction system, and to make things simpler, I want to use this physics sistem's own footstep system. But, for that, I must call a function from another script right here: (The script is CharacterFootEffects)
public virtual bool FootStep(Transform foot, bool flipFootprint)
{
// A RaycastHit is required for the SurfaceManager.
RaycastHit hit;
if (Physics.Raycast(foot.position + m_Transform.up * 0.2f, -m_Transform.up, out hit, 0.21f + m_FootOffset, m_CharacterLayerManager.IgnoreInvisibleCharacterWaterLayers, QueryTriggerInteraction.Ignore)) {
SurfaceManager.SpawnEffect(hit, m_SurfaceImpact, m_CharacterLocomotion.GravityDirection, m_CharacterLocomotion.TimeScale, foot.gameObject, m_Transform.forward, flipFootprint);
// here!
return true;
}
return false;
}
But for some reason I can't call any function from any script.
The function that I must call is this one:
public class CreateFootsteps : MonoBehaviour
{
public static void Footstepped()
{
// Do things!
}
}
(I'm using the latest version of UCC V2)
How can I fix that?