error: `AI' does not exist in the namespace`UnityEngine'

I am getting an error regarding a script in Unity 5.4.0b24.

Assets/Standard Assets/Character Controllers/Sources/Scripts/AICharacterControl.cs(10,28): error CS0234: The type or namespace name AI’ does not exist in the namespace `UnityEngine’. Are you missing an assembly reference?

removing this script from my project causes playmaker to give 72 errors like “pathfinding” stuff, so I can’t just delete this script.

any idea how to correct this error?

I guess it’s a mixup during Unity changing versions or between Pro and Personal versions.

Had the same problem. In my case Unity could not find

UnityEngine.AI.NavMeshAgent

Solved by pointing all the references to

UnityEngine.NavMeshAgent

instead.

I eliminated the editor error by removing the AI script, removing the Playmaker Pathfinding folder whose actions then freaked out, removing the Playmaker script NavMeshAgentAnimatorSynchronizer.cs that also freaked out, then removing the folder for the Energy Bar Toolkit that also freaked out.

Now everything seems to work fine, but I might have deleted something I will later need or that could pop up at any time. If anyone has an insight into how to add “AI” to the namespace ‘UnityEngine’ that would be the real solution.

Thank You @wiseman17

using System;
using UnityEngine;

this works for me in Unity 5.3