diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-04-20 14:36:00 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-04-20 14:36:00 +0400 |
commit | 870115be85c196183bd81b9d111a4aafc7900df3 (patch) | |
tree | 7bd0e70a8dda048928fdc83e5cf05f1591251641 | |
parent | 0d5075676e7dd39efd5f46428920ca45d320977f (diff) |
hidden durian feature for entering a new path when linked libs are not found.
-rw-r--r-- | source/blender/blenloader/intern/readfile.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c index 66111d21ccb..99891fb62e2 100644 --- a/source/blender/blenloader/intern/readfile.c +++ b/source/blender/blenloader/intern/readfile.c @@ -12199,6 +12199,28 @@ static void read_libraries(FileData *basefd, ListBase *mainlist) BKE_reportf(basefd->reports, RPT_INFO, "read library: '%s', '%s'\n", mainptr->curlib->filename, mainptr->curlib->name); fd= blo_openblenderfile(mainptr->curlib->filename, basefd->reports); + + /* allow typing in a new lib path */ + if(G.rt==-666) { + while(fd==NULL) { + char newlib_path[240] = { 0 }; + printf("Missing library: '%s', '%s'\n", mainptr->name, G.sce); + printf(" abs: %s\n", mainptr->curlib->filename); + printf(" rel: %s\n", mainptr->curlib->name); + printf(" enter a new path:\n"); + scanf("%s", newlib_path); + + strcpy(mainptr->curlib->name, newlib_path); + strcpy(mainptr->curlib->filename, newlib_path); + cleanup_path(G.sce, mainptr->curlib->filename); + + fd= blo_openblenderfile(mainptr->curlib->filename, basefd->reports); + + if(fd) { + printf("found: '%s', party on macuno!\n"); + } + } + } if (fd) { fd->reports= basefd->reports; |