home *** CD-ROM | disk | FTP | other *** search
- class com.Sounds
- {
- var winLevel;
- var clickToFace;
- var clickToEndPoint;
- var lineComplite;
- var lineNoComplite;
- function Sounds(obj)
- {
- this.winLevel = new Sound(obj);
- this.winLevel.attachSound("winLevel");
- this.winLevel.onSoundComplete = this.emptyFuncForSound;
- this.clickToFace = new Sound(obj);
- this.clickToFace.attachSound("clickToFace");
- this.clickToFace.onSoundComplete = this.emptyFuncForSound;
- this.clickToEndPoint = new Sound(obj);
- this.clickToEndPoint.attachSound("clickToEndPoint");
- this.clickToEndPoint.onSoundComplete = this.emptyFuncForSound;
- this.lineComplite = new Sound(obj);
- this.lineComplite.attachSound("lineComplite");
- this.lineComplite.onSoundComplete = this.emptyFuncForSound;
- this.lineNoComplite = new Sound(obj);
- this.lineNoComplite.attachSound("lineNoComplite");
- this.lineNoComplite.onSoundComplete = this.emptyFuncForSound;
- }
- function playSound(type)
- {
- this.lineNoComplite.setVolume(60);
- switch(type)
- {
- case "clickToFace":
- this.clickToFace.start();
- break;
- case "clickToEndPoint":
- this.clickToEndPoint.start();
- break;
- case "lineComplite":
- this.lineComplite.start();
- break;
- case "lineNoComplite":
- this.lineNoComplite.start();
- break;
- case "winLevel":
- this.lineNoComplite.setVolume(30);
- this.winLevel.start();
- }
- }
- function emptyFuncForSound()
- {
- }
- }
-