I have a simple prefab created with my character, two cubes that are used for waypoints to patrol, and one large cube used a a trigger to tell that character to chase after the player. When I have this prefab in the scene by himself there are no problems. However when I place that prefab into another prefab within the scene I start getting constant Null Ref errors, all coming from iTween.
NullReferenceException: Object reference not set to an instance of an object
iTween.RetrieveArgs () (at Assets/Plugins/iTween/iTween.cs:6788)
iTween.Awake () (at Assets/Plugins/iTween/iTween.cs:6538)
UnityEngine.GameObject:AddComponent(String)
iTween:Launch(GameObject, Hashtable) (at Assets/iTween/Plugins/iTween.cs:6740)
iTween:MoveTo(GameObject, Hashtable) (at Assets/iTween/Plugins/iTween.cs:1448)
HutongGames.PlayMaker.Actions.iTweenMoveTo:DoiTween() (at Assets/Scripts/PlayMaker/Actions/iTween/iTweenMoveTo.cs:177)
HutongGames.PlayMaker.Actions.iTweenMoveTo:OnEnter() (at Assets/Scripts/PlayMaker/Actions/iTween/iTweenMoveTo.cs:106)
HutongGames.PlayMaker.FsmState:OnEnter()
HutongGames.PlayMaker.Fsm:EnterState(FsmState)
HutongGames.PlayMaker.Fsm:SwitchState(FsmState)
HutongGames.PlayMaker.Fsm:UpdateStateChanges()
HutongGames.PlayMaker.Fsm:Start()
PlayMakerFSM:Start()
The only place I am using iTween is within some of the playmaker scripts I have made. The Playmaker script simply uses iTween Move To to move to one point and once it gets there it uses it again to move back. Once the character enters the trigger collider it then goes into the chase state where I use iTween Move Update to move toward the player. The players object is stored in a global variable and the chase script uses that global variable. The other two points used for the pathing are just cube objects within the prefab of the character.
Has anyone run into this before, or have any ideas as to what might be causing the issue? Also if you need any additional information just let me know and I will get you anything you need.
Edit: Found a different error reference which I think may better display the issue that is happening.
Thanks