Using the “Universal Windows Platform” Build Platform option I have created a simple working Unity test app on a modern Windows 10 system. It happens to use speech recognition. Using the “PC, Mac & Linux Standalone” Platform option I have done a “Master” Build of it and successfully run the resulting executable on a separate Windows laptop using Unity WebPlayer.
I now want to create an iOS version of this test app that will run using a Unity Webplayer on a Mac Mini. I’ve attempted to complete a Build using the Unity “iOS” Build Platform and have run into problems associated with the speech recognition elements of my script. The Build is failing with errors such as “KeywordRecognizer could not be found”. The reference to KeywordRecognizer comes from the 10th line in the excerpt of my script cc’d below.
NOTE: When doing the initial Build Settings for the iOS Build, Unity prompted me that I needed to download a “Unity iOS Support” suite (The instructions explicitly had me download and run the .exe file “UnitySetup-IOS-Support-for-Editor-2017.2p2.exe” to accomplish this). The download completed as expected and I restarted the Build itself. As mentioned above, it failed to build and put out numerous error messages similar to the example above such as “‘PhraseRecognizerEventArgs’ could not be found”. In addition, I got an error message that read “‘Windows’ does not exist in ‘Unity Engine’”
Please note the using statement “using UnityEngine.Windows.Speech;” below in the script excerpt. I believe that within the referenced code “UnityEngine.Windows.Speech” the code for “KeywordRecognizer” is found for the Windows version of this script. I further believe that the download of “Unity iOS Support” did not have any code to support KeywordRecognizer. The terms “KeywordRecognizer” and “PhraseRecognizerEventArgs” are clearly Speech related. So my question is as follows…
QUESTION:What additional downloads do I need to complete to support the Speech requirements of my script when I do the iOS version of the Unity Build?
SCRIPT EXCERPT:
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using UnityEngine;
using UnityEngine.Windows.Speech;
public class MoveOpponent01B : MonoBehaviour
{
private KeywordRecognizer keywordRecognizer;
private Dictionary<string, Action> actions = new Dictionary<string, Action>();
public GameObject waypoints;
int current = 0;
float rotSpeed;
public float speed;
float WPradius = .1f;
int go = 0;
All community help is greatly appreciated. Thx.
Cheers,
Bob G.