ifrotz / iosfrotz

Frotz for iOS source (formerly at code.google.com/p/iphonefrotz)
Other
49 stars 16 forks source link

Add option to auto-enter after voice dictation (and auto abbrev Enchanter directions) #260

Open ifrotz opened 9 years ago

ifrotz commented 9 years ago

Excerpt from an old frotz-discuss post I never dd follow up on.

Enchanter is the only game I know of which mysteriously doesn't accept long form off-cardinal directions (northeast, etc.) (Well, Starcross doesn't either, but those directions aren't used at all in the game so it's not a problem.) It would be pretty easy to hardcode a check for Enchanter (by filename or game header version number) and substitute those 4 commands with their abbreviated versions before the game parsed them.

Regarding the 'enter' problem, I noticed this too but at the time there was no way to even tell if text had been input using voice recognition. Fortunately, the iOS 5.1 update appears to have added a way to do this (although I have not had a chance to play with it yet) using UIDictationPhrase and some dictation callbacks added to the UITextInput protocol. If you can improve voice recognition using this, I'd be happy to accept patches. Please be sure to null-test any APIs you use to make sure they exist before calling them, because I compile Frotz with a deployment target so that it works on older iOS versions. Previously I supported all the way back to 3.0, but I will probably bump the oldest supported version to 4.2.1 (the latest OS still supported by 1st gen devices) with the next release, so it's okay to assume any APIs older than 4.2.1 exist without testing.