Skip to content

Instantly share code, notes, and snippets.

@tsubaki
Created September 22, 2017 13:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tsubaki/35eb8176f38c95028fc3a5b7db3c3a21 to your computer and use it in GitHub Desktop.
Save tsubaki/35eb8176f38c95028fc3a5b7db3c3a21 to your computer and use it in GitHub Desktop.
もっと簡単な動的なバインド(Control Playable Asset Clipのみ)
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Playables;
public class EasyRebind : MonoBehaviour
{
[SerializeField] Transform bindedTransform;
public void Play (Rotation rotation)
{
rotation.transform.parent = bindedTransform;
var director = GetComponent<PlayableDirector> ();
director.Play ();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment