Fix for [#24654] Sound Actuator doesn't find the file when Blender is reopened.
This commit is contained in:
@@ -467,7 +467,7 @@ int unpackVFont(ReportList *reports, VFont *vfont, int how)
|
||||
return (ret_value);
|
||||
}
|
||||
|
||||
int unpackSound(ReportList *reports, bSound *sound, int how)
|
||||
int unpackSound(Main *bmain, ReportList *reports, bSound *sound, int how)
|
||||
{
|
||||
char localname[FILE_MAXDIR + FILE_MAX], fi[FILE_MAX];
|
||||
char *newname;
|
||||
@@ -486,7 +486,7 @@ int unpackSound(ReportList *reports, bSound *sound, int how)
|
||||
freePackedFile(sound->packedfile);
|
||||
sound->packedfile = 0;
|
||||
|
||||
sound_load(NULL, sound);
|
||||
sound_load(bmain, sound);
|
||||
|
||||
ret_value = RET_OK;
|
||||
}
|
||||
@@ -536,6 +536,6 @@ void unpackAll(Main *bmain, ReportList *reports, int how)
|
||||
|
||||
for(sound=bmain->sound.first; sound; sound=sound->id.next)
|
||||
if(sound->packedfile)
|
||||
unpackSound(reports, sound, how);
|
||||
unpackSound(bmain, reports, sound, how);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user