コード例 #1
0
 // Start is called before the first frame update
 void Start()
 {
     //AudioSourceコンポーネントを取得し、変数に格納
     Gays     = GetComponent <AudioSource>();
     selector = gameObject.GetComponent <VoiceSelector>();
     actor    = gameObject.GetComponent <VoiceActor>();
     //TimeLimiter = gameObject.AddComponent<TimeController>();
     //TimeLimiter.limit = 10;
     //TimeLimiter.effect = PlayGaya;
 }
コード例 #2
0
        /// <summary>
        /// probably hacky code, but the designer shows again, feel free to clean this up
        /// got no experience with ninject
        /// </summary>
        public override void Load()
        {
            //for the speech converter
            Bind <ISpeechSynthesizer>().ToConstant(new CradiatorSpeechSynthesizer(new SpeechSynthesizer()));

            var ss = new SpeechSynthesizer();

            var css = new CradiatorSpeechSynthesizer(ss);
            var vs  = new VoiceSelector(css);

            Bind <InstalledVoiceConverter>().ToConstant(new InstalledVoiceConverter(vs));


            //for the build breakers
            var fs = new FixerStrategy();
            var bs = new BuildBuster(new Config.ConfigSettings(), fs, new GuiltFactory());

            Bind <IBuildBuster>().ToConstant(bs);
        }
コード例 #3
0
 public void SetUp()
 {
     _speechSynth   = MockRepository.GenerateMock <ISpeechSynthesizer>();
     _voiceSelector = new VoiceSelector(_speechSynth);
 }
コード例 #4
0
 public InstalledVoiceConverter(VoiceSelector voiceSelector)
 {
     _voiceSelector = voiceSelector;
 }