Question by
TaesikYoon · Jan 21, 2016 at 12:16 AM ·
c#dataassetdatabase
ScriptableObject's asset selection doesn't work!
I made a simple ScriptableObject that can store 'AnimatorController'. but asset selection doesn't work but other type objects.
can you tell me why I'cant store AnimatorController to ScriptableObject?
here's my simple ScriptableObject and behaviour.
using UnityEngine;
using System.Collections;
public class myScriptableObject : ScriptableObject {
public AnimatorController animCtrl;// it doesn't work.
public AnimationClip animClip; // it works.
public ToolBox toolBox; // and this one too.
}
using UnityEngine;
using System.Collections;
public class myScriptableObjectBehaviour : MonoBehaviour {
public myScriptableObject myScriptableObj;
void Start() {
Debug.log(myScriptableObj.animCtrl);
Debug.log(myScriptableObj.animClip);
Debug.log(myScriptableObj.toolBox);
}
}
Comment
Your answer
Follow this Question
Related Questions
Reset PlayerPrefs on Build? 2 Answers
How to save player1's stats separate from player2's i.e. Health, Damage, Etc.. 1 Answer
How to have a script that creates scriptable objects but also works in the build. 0 Answers
How to properly split string received from server to update Vector3? 2 Answers
I want to import CFD data. 1 Answer