Sound Events – Story Tellers iOS Starter Kit Documentation

Sound and Text-to-Speech Events

Story Tellers iOS Starter Kit 2 Documentation

  • PlayBackgroundSound – the value will be the sound file minus extension (the code will add .mp3 to the end).

Sound events in Sprite Kit

  • StopBackgroundSound – the value will be the sound file minus extension  (the code will add .mp3 to the end).
  • PlayOrStopBackgroundSound – the value will be the sound file minus extension (the code will add .mp3 to the end).
  • PlayOrStopNarrationSound – the value will be the sound file minus extension (the code will add .mp3 to the end).
  • PlayNarrationSound – the value will be the sound file minus extension (the code will add .mp3 to the end).
  • StopNarrationSound – the value will be the sound file minus extension (the code will add .mp3 to the end).

Note: you can choose whether or not narration and background sounds stop when the page transitions using Page Settings properties.

  • PlaySound –  the value will be the sound file PLUS extension (the source can be any supported sound format).

Sound events in Sprite Kit

  • PlaySoundFromPool – enter the name of a pool array containing an unlimited number of sound files. For example…

Play Random Sounds with Sprite Kit

  • PlaySoundFromPreference –  enter the name of a saved value which notes the sound file. For example…

Play sound file in SpriteKit

As some point prior to calling PlaySoundFromPreference, the app should set a value for PreferredSound (or whatever you named this preference).

saving sound file preference in iOS9 starter kit 2

 

 


 

To find out more on sound properties you can set on a per-page basis, go here  (for example, whether or not the background sound continues or restarts on each page).

Text-to-Speech Events

You can watch a video on these cool new features…

 

  • Speak – the value will be any text you want spoken.

text to speech options in the iOS Childrens Book Starter Kit 1

  • SpeakLabel –  the name of the SKLabelNode you want to have spoken

text to speech options in the iOS Childrens Book Starter Kit 2

text to speech options in the iOS Childrens Book Starter Kit 3

  • SpeakPreference – the value can be ANY saved value.

text to speech options in the iOS Childrens Book Starter Kit 4

 

Changing the Speech Voice 

  • SpeechRate –  a decimal number value, default is 0.38. This property can be an event or set in the page’s Settings dictionary
  • SpeechVolume – a decimal number value, default is 1.  This property can be an event or set in the page’s Settings dictionary
  • SpeechPitch – a decimal number value, default is 1.70.  This property can be an event or set in the page’s Settings dictionary
  • SpeechVoice – a voice code or country name for a new voice.  This property can be an event or set in the page’s Settings dictionary
  • OutputVoiceCodes – An event property which will output all the country name and voice codes.
  • AllowRunOnSpeech – For the page’s Settings dictionary.  Set YES and events that call text to speak will not interrupt the current speaking. So for example,  calling a Speak event back to back will run the speech one after the other.

text to speech options in the iOS Childrens Book Starter Kit 5




Know what an affiliate program is? You make money just by sharing links to our site! Win. Win.

Earn when you refer any buyer here! 30 day tracking. Commissions are 33%-50% and recur on subscription products!


Uh oh, missing your affiliate ID. Create one real quick