| OLD | NEW |
| 1 part of game; | 1 part of game; |
| 2 | 2 |
| 3 class _Audio { | 3 class _Audio { |
| 4 static const List<String> _AUDIO_NAMES = | 4 static const List<String> _AUDIO_NAMES = |
| 5 const ['Pop0', 'Pop1', 'Pop2', 'Pop3', 'Pop4', 'Pop5', 'Pop6', 'Pop7', 'Po
p8', | 5 const ['Pop0', 'Pop1', 'Pop2', 'Pop3', 'Pop4', 'Pop5', 'Pop6', 'Pop7', 'Po
p8', |
| 6 'Bomb0', 'Bomb1', 'Bomb2', 'Bomb3', 'Bomb4', | 6 'Bomb0', 'Bomb1', 'Bomb2', 'Bomb3', 'Bomb4', |
| 7 GameAudio.THROW_DART, GameAudio.FLAG, GameAudio.UNFLAG, GameAudio.C
LICK, GameAudio.WIN]; | 7 GameAudio.THROW_DART, GameAudio.FLAG, GameAudio.UNFLAG, GameAudio.C
LICK, GameAudio.WIN]; |
| 8 | 8 |
| 9 final AudioLoader _audioLoader; | 9 final AudioLoader _audioLoader; |
| 10 final Map<String, AudioBuffer> _buffers = new Map(); | 10 final Map<String, AudioBuffer> _buffers = new Map(); |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 } | 113 } |
| 114 } | 114 } |
| 115 } catch (e) { | 115 } catch (e) { |
| 116 print("Error getting client info: ${e}"); | 116 print("Error getting client info: ${e}"); |
| 117 } | 117 } |
| 118 return null; | 118 return null; |
| 119 } | 119 } |
| 120 | 120 |
| 121 static String _getAudioPath(String name) { | 121 static String _getAudioPath(String name) { |
| 122 assert(_audioFormat != null); | 122 assert(_audioFormat != null); |
| 123 return 'audio/${_audioFormat}/$name.${_audioFormat}'; | 123 return '${_ASSET_DIR}audio/${_audioFormat}/$name.${_audioFormat}'; |
| 124 } | 124 } |
| 125 | 125 |
| 126 static Iterable<String> _getAudioPaths(Iterable<String> names) { | 126 static Iterable<String> _getAudioPaths(Iterable<String> names) { |
| 127 return names.map(_getAudioPath); | 127 return names.map(_getAudioPath); |
| 128 } | 128 } |
| 129 } | 129 } |
| OLD | NEW |