2,
Can set override for this Method handleParametersRegistrationManually() ? It cause my prefab Animate Property data lost…
I want to AnimateProperty set localposition and localEulerAngles is offset value not final value….
ex:
gameobject source x = 10 or any value and set key1 x=-5, key2 x=5
AnimateProperties class:
result is always x=10(any value) -> x=-5 and x=-4, x=-3,…go to x=5
My Custom AnimateProperties class:
result is x=10(any value) -5 and x=10(any value)-4, -3…go to x=10(any value) + 5
This is I changed….
private bool handleParametersRegistrationManually{
get { return (animatedParametersTarget != this) /*Added By Me ====>*/|| (GetType() == typeof(ActionClips.SK_AnimateProperty)); }
}
I write my class SK_AnimateProperty : AnimateProperties and Editor is
class SK_AnimateProperty
{
[HideInInspector]
public Vector3 positionOffset { get; set; }
[HideInInspector]
public bool havePositionOffset = false;
[HideInInspector]
public Vector3 angleOffse { get; set; }
[HideInInspector]
public bool haveAngleOffset = false;
protected override void OnUpdate(float time)
{
if (havePositionOffset)
{
actor.transform.position = Position<This is Property, do source position + offset value>;
}
if (haveAngleOffset)
{
actor.transform.localEulerAngles = Angle<This is Property, do source angle + offset value>;
}
}
}
class SK_AnimatePropertyEditor
{
public override void OnInspectorGUI(){
base.OnInspectorGUI();
if (!action.isValid){
if (GUILayout.Button( !action.isValid? “Select Property” : “Add Property” )){
EditorTools.ShowAnimatedPropertySelectionMenu(action.actor.gameObject, AnimatedParameter.supportedTypes, (prop, target)=>{
3,
Is possible to combine Rotate in FollowPath Clip ?
ex:
I can set node1<pointX=5, rotY=90>, node2<pointX=10, rotY=180>
result is pointX=5,6,7..10, rotY=90.91,92….180…
Author
Posts
Viewing 1 post (of 1 total)
You must be logged in to reply to this topic.
Login
Register
By registering on this website you agree to our Privacy Policy.