hedgewars/uPhysFSLayer.pas
changeset 9988 317d46a2afd2
parent 9531 7fcdedc45589
child 9993 76ad55807c24
--- a/hedgewars/uPhysFSLayer.pas	Tue Jan 14 11:45:52 2014 +0100
+++ b/hedgewars/uPhysFSLayer.pas	Tue Jan 14 22:56:13 2014 +0100
@@ -150,7 +150,14 @@
 
     i:= PHYSFS_mount(Str2PChar(UserPathPrefix), nil, false);
     // need access to teams and frontend configs (for bindings)
-    AddFileLog('[PhysFS] mount ' + UserPathPrefix + ': ' + inttostr(i)); 
+    AddFileLog('[PhysFS] mount ' + UserPathPrefix + ': ' + inttostr(i));
+
+    if cTestLua then
+        begin
+            i:= PHYSFS_mount(Str2PChar(ExtractFileDir(cScriptName)), nil, false);
+            AddFileLog('[PhysFS] mount ' + ExtractFileDir(cScriptName) + ': ' + inttostr(i));
+            cScriptName := ExtractFileName(cScriptName);
+        end;
 end;
 
 procedure freeModule;