-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmusic.js
More file actions
43 lines (38 loc) · 673 Bytes
/
Copy pathmusic.js
File metadata and controls
43 lines (38 loc) · 673 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
let main_sound, main_length, ice_bool, ice_interval;
main_sound = true;
ice_bool = true;
function main_theme()
{
if (!main_sound) return;
music();
setInterval('music()', 288000)
main_sound = false;
}
function music()
{
let b = new Audio();
b.src = 'main_theme.mp3';
b.volume = 0.5;
b.play()
}
function sound_boom()
{
let b = new Audio();
b.src = 'boom.wav';
b.volume = 0.5;
b.play()
}
function take_damage_h()
{
let b = new Audio();
b.src = 'hero_atacked.mp3';
b.volume = 1;
b.play()
}
function sound_key()
{
let b = new Audio();
b.src = 'key.wav';
b.volume = 0.9;
b.play()
}