static public MegaBezFloatKeyControl LoadBezFloatKeyControl(BinaryReader br)
    {
        con = new MegaBezFloatKeyControl();

        MegaParse.Parse(br, Parse);
        return(con);
    }
Пример #2
0
	static public MegaBezFloatKeyControl LoadBezFloatKeyControl(BinaryReader br)
	{
		con = new MegaBezFloatKeyControl();

		MegaParse.Parse(br, Parse);
		return con;
	}
    bool AnimCallback(BinaryReader br, string id)
    {
        MegaMorph mr = (MegaMorph)target;

        switch (id)
        {
        case "Chan":
            int cn = br.ReadInt32() + startchan;
            if (cn < mr.chanBank.Count)
            {
                currentChan = mr.chanBank[cn];
            }
            else
            {
                Debug.LogWarning("Morph File has animation data for a missing target, check your original file and delete unused channels");
                currentChan = null;
            }
            break;

        case "Anim":
            MegaBezFloatKeyControl con = LoadAnim(br);
            if (currentChan != null)
            {
                currentChan.control = con;
            }
            break;

        default: return(false);
        }

        return(true);
    }