//get references at start //initialize movement but don't start it yet void Start() { animator = GetComponent<Animator>(); move = GetComponent<splineMove>(); move.StartMove(); move.Pause(); progress = 0f; }
static int StartMove(IntPtr L) { try { ToLua.CheckArgsCount(L, 1); SWS.splineMove obj = (SWS.splineMove)ToLua.CheckObject <SWS.splineMove>(L, 1); obj.StartMove(); return(0); } catch (Exception e) { return(LuaDLL.toluaL_exception(L, e)); } }
// Start is called before the first frame update void Start() { move.speed = startSpeed; move.StartMove(); }
//get references void Start() { move = GetComponent<splineMove>(); if (!move) { Debug.LogWarning(gameObject.name + " missing movement script!"); return; } //set speed to an arbitrary small value //otherwise the tween can't be initialized move.speed = 0.01f; //initialize movement but don't start it yet move.StartMove(); move.Pause(); move.speed = 0f; }
//get references at start //initialize movement but don't start it yet void Start() { myMove = gameObject.GetComponent<splineMove>(); myMove.StartMove(); myMove.Pause(); }