mirror of
https://github.com/Sarjuuk/aowow.git
synced 2025-11-29 15:58:16 +08:00
Sounds/DetailPage
* fixed generating links to play via the WoW API * fixed usage of not yet available PlaySoundKitID() when selecting file from list * while internally it is pretty laissez-faire about cases in file paths, suddenly WoW DOES care, when it comes to its LUA API. so .. don't cast to lowercase when storing sounds in DB
This commit is contained in:
@@ -43,9 +43,11 @@ class SoundList extends BaseType
|
||||
|
||||
if ($this->fileBuffer)
|
||||
{
|
||||
$files = DB::Aowow()->select('SELECT id AS ARRAY_KEY, `id`, `file` AS title, `type` FROM ?_sounds_files sf WHERE id IN (?a)', array_keys($this->fileBuffer));
|
||||
$files = DB::Aowow()->select('SELECT id AS ARRAY_KEY, `id`, `file` AS title, `type`, `path` FROM ?_sounds_files sf WHERE id IN (?a)', array_keys($this->fileBuffer));
|
||||
foreach ($files as $id => $data)
|
||||
{
|
||||
// 3.3.5 bandaid - need fullpath to play via wow API, remove for cata and later
|
||||
$data['path'] = str_replace('\\', '\\\\', $data['path'] ? $data['path'] . '\\' . $data['title'] : $data['title']);
|
||||
// skipp file extension
|
||||
$data['title'] = substr($data['title'], 0, -4);
|
||||
// enum to string
|
||||
|
||||
Reference in New Issue
Block a user