Hi, I’m using the CharacterMotor script that comes with Unity. I’m also mostly using PlayMaker to set up my character. Anyway, It seems like I am unable to access the gravity parameter of the CharacherMotor component with PlayMaker.
My question is; is it possible to make this parameter accessible with PlayMaker, or should I write a script?
For example, I have a water zone trigger, so ‘on trigger enter’ I’d like to lower the gravity value. I wrote this script but it doesn’t work:
using UnityEngine;
using System.Collections;
public class WaterEnter : MonoBehaviour
{
void OnTriggerEnter(Collider other)
{
CharacterMotor gravity = other.gameObject.GetComponent<CharacterMotor>();
if (gravity)
{
gravity = 10;
}
}
}