Added new json files and sound events.

This commit is contained in:
flash 2022-09-08 20:51:49 +00:00
parent 0c11a98275
commit d4962e48b5
3 changed files with 77 additions and 3 deletions

View file

@ -7,6 +7,9 @@ events[error] = rogueamp:fuckbitch
events[server] = ajaxchat:server events[server] = ajaxchat:server
events[incoming] = ajaxchat:incoming events[incoming] = ajaxchat:incoming
events[outgoing] = ajaxchat:outgoing events[outgoing] = ajaxchat:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; AIM ; AIM
[aim] [aim]
@ -17,6 +20,9 @@ events[error] = kf4:fuckyou
events[server] = aim:server events[server] = aim:server
events[incoming] = aim:incoming events[incoming] = aim:incoming
events[outgoing] = aim:outgoing events[outgoing] = aim:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Inkling Girl ; Inkling Girl
[woomy] [woomy]
@ -27,6 +33,9 @@ events[error] = woomy:error
events[server] = woomy:server events[server] = woomy:server
events[incoming] = woomy:incoming events[incoming] = woomy:incoming
events[outgoing] = woomy:outgoing events[outgoing] = woomy:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Pictochat ; Pictochat
[nds] [nds]
@ -37,6 +46,9 @@ events[error] = nds:error
events[server] = nds:server events[server] = nds:server
events[incoming] = nds:incoming events[incoming] = nds:incoming
events[outgoing] = nds:outgoing events[outgoing] = nds:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; osu! ; osu!
[osu] [osu]
@ -47,6 +59,9 @@ events[error] = osu:error
events[server] = osu:server events[server] = osu:server
events[incoming] = osu:incoming events[incoming] = osu:incoming
events[outgoing] = osu:outgoing events[outgoing] = osu:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Windows 2000/ME ; Windows 2000/ME
[win2k] [win2k]
@ -57,6 +72,9 @@ events[error] = win2k:error
events[server] = win2k:server events[server] = win2k:server
events[incoming] = win2k:incoming events[incoming] = win2k:incoming
events[outgoing] = win2k:outgoing events[outgoing] = win2k:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Windows XP ; Windows XP
[winxp] [winxp]
@ -67,6 +85,9 @@ events[error] = winxp:error
events[server] = winxp:server events[server] = winxp:server
events[incoming] = winxp:incoming events[incoming] = winxp:incoming
events[outgoing] = winxp:outgoing events[outgoing] = winxp:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Windows Vista/7 ; Windows Vista/7
[win7] [win7]
@ -77,6 +98,9 @@ events[error] = win7:error
events[server] = win7:server events[server] = win7:server
events[incoming] = win7:incoming events[incoming] = win7:incoming
events[outgoing] = win7:outgoing events[outgoing] = win7:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Windows 8 ; Windows 8
[win8] [win8]
@ -87,6 +111,9 @@ events[error] = win8:error
events[server] = win8:server events[server] = win8:server
events[incoming] = win8:incoming events[incoming] = win8:incoming
events[outgoing] = win8:outgoing events[outgoing] = win8:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Aizawa Inori ; Aizawa Inori
[inori] [inori]
@ -97,6 +124,9 @@ events[error] = inori:error
events[server] = inori:server events[server] = inori:server
events[incoming] = inori:incoming events[incoming] = inori:incoming
events[outgoing] = inori:outgoing events[outgoing] = inori:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Madobe Nanami ; Madobe Nanami
[nanami] [nanami]
@ -107,6 +137,9 @@ events[error] = nanami:error
events[server] = nanami:server events[server] = nanami:server
events[incoming] = nanami:incoming events[incoming] = nanami:incoming
events[outgoing] = nanami:outgoing events[outgoing] = nanami:outgoing
events[kick] = touhou:pichuun
events[timeout] = misc:explode
events[unban] = dokuro:pipiru
; Tada ; Tada
[tada] [tada]

View file

@ -87,7 +87,7 @@ match[] = "lc; is:i am with the science team"
match[] = "lc; is:i'm with the science team!" match[] = "lc; is:i'm with the science team!"
match[] = "lc; is:i am with the science team!" match[] = "lc; is:i am with the science team!"
[snd-booyah] [ali-booyah]
type = alias type = alias
for[] = woomy for[] = woomy
for[] = ngyes for[] = ngyes

View file

@ -73,6 +73,34 @@ if($reqPath === '/common.json') {
json_out($common); json_out($common);
} }
if($reqPath === '/sounds2.json') {
$sndLibData = file_get_contents(FTM_PATH_PRV . '/sound-library.ini');
$sndPackData = file_get_contents(FTM_PATH_PRV . '/sound-packs.ini');
etag_data('sounds2', $sndLibData . $sndPackData);
$sndLib = parse_ini_string($sndLibData, true, INI_SCANNER_TYPED);
$sndPacks = parse_ini_string($sndPackData, true, INI_SCANNER_TYPED);
$library = [];
foreach($sndLib as $name => $info)
$library[] = [
'name' => $name,
'title' => $info['title'],
'sources' => $info['sources'],
];
$packs = [];
foreach($sndPacks as $name => $info)
$packs[] = [
'name' => $name,
'title' => $info['title'],
'events' => $info['events'],
];
json_out(compact('library', 'packs'));
}
if($reqPath === '/sounds.json') { if($reqPath === '/sounds.json') {
$sndLibData = file_get_contents(FTM_PATH_PRV . '/sound-library.ini'); $sndLibData = file_get_contents(FTM_PATH_PRV . '/sound-library.ini');
$sndPackData = file_get_contents(FTM_PATH_PRV . '/sound-packs.ini'); $sndPackData = file_get_contents(FTM_PATH_PRV . '/sound-packs.ini');
@ -100,17 +128,30 @@ if($reqPath === '/sounds.json') {
} }
$packs = []; $packs = [];
foreach($sndPacks as $name => $info) { foreach($sndPacks as $name => $info)
$packs[] = [ $packs[] = [
'id' => $name, 'id' => $name,
'name' => $info['title'], 'name' => $info['title'],
'events' => $info['events'], 'events' => $info['events'],
]; ];
}
json_out(compact('library', 'packs')); json_out(compact('library', 'packs'));
} }
if($reqPath === '/texttriggers.json') {
$textTriggersPath = FTM_PATH_PRV . '/text-triggers.ini';
etag_file('texttriggers', $textTriggersPath);
$triggers = parse_ini_file($textTriggersPath, true, INI_SCANNER_TYPED);
if($triggers === false)
$triggers = [];
else
$triggers = array_values($triggers);
json_out($triggers);
}
if($reqPath === '/soundtriggers.json') { if($reqPath === '/soundtriggers.json') {
$textTriggersPath = FTM_PATH_PRV . '/text-triggers.ini'; $textTriggersPath = FTM_PATH_PRV . '/text-triggers.ini';
etag_file('soundtriggers', $textTriggersPath); etag_file('soundtriggers', $textTriggersPath);