… | |
… | |
45 | push @face, $face |
45 | push @face, $face |
46 | if $face; |
46 | if $face; |
47 | } |
47 | } |
48 | } |
48 | } |
49 | |
49 | |
50 | # sort by size, smallest first, because it'S the fastest to download... |
50 | # sort by size, smallest first, because it's the fastest to download... |
51 | [ sort { (cf::face::get_data_size $a) <=> (cf::face::get_data_size $b) } @face ] |
51 | [ sort { ($cf::face::SIZE[0][$a]) <=> ($cf::face::SIZE[0][$b]) } @face ] |
52 | } |
52 | } |
53 | |
53 | |
54 | our %MUSIC_QUEUE; |
54 | our %MUSIC_QUEUE; |
55 | |
55 | |
56 | our $MUSIC_SCHEDULER = cf::async_ext { |
56 | our $MUSIC_SCHEDULER = cf::async_ext { |
… | |
… | |
63 | cf::get_slot 0.01, -10, "music scheduler"; |
63 | cf::get_slot 0.01, -10, "music scheduler"; |
64 | |
64 | |
65 | my $pl = cf::player::find_active $_ or next; |
65 | my $pl = cf::player::find_active $_ or next; |
66 | my $ob = $pl->ob; |
66 | my $ob = $pl->ob; |
67 | my $ns = $pl->ns or next; |
67 | my $ns = $pl->ns or next; |
68 | $ns->extcmd or next; |
|
|
69 | my $map = $ob->map; |
68 | my $map = $ob->map; |
70 | my $rgn = $ob->region; |
69 | my $rgn = $ob->region; |
71 | |
70 | |
72 | my $id = join "\x00", $map->path, $rgn->name; |
71 | my $id = join "\x00", $map->path, $rgn->name; |
73 | |
72 | |