mirror of
https://github.com/Anuken/Mindustry.git
synced 2026-01-25 14:01:03 -08:00
!dir.exists() and new line
This commit is contained in:
parent
4709b5dddc
commit
fea9f51513
1 changed files with 2 additions and 1 deletions
|
|
@ -108,6 +108,7 @@ public class Scripts implements Disposable{
|
|||
|
||||
private class ScriptModuleProvider extends UrlModuleSourceProvider{
|
||||
private Pattern directory = Pattern.compile("^(.+?)/(.+)");
|
||||
|
||||
public ScriptModuleProvider(){
|
||||
super(null, null);
|
||||
}
|
||||
|
|
@ -125,7 +126,7 @@ public class Scripts implements Disposable{
|
|||
String script = matched.group(2);
|
||||
if(required == null || root == required.root.child("scripts")){ // Mod not found, or already using a mod
|
||||
Fi dir = root.child(matched.group(1));
|
||||
if(dir == null) return null; // Mod and folder not found
|
||||
if(!dir.exists()) return null; // Mod and folder not found
|
||||
return loadSource(mod, script, dir, validator);
|
||||
}
|
||||
return loadSource(required, script, required.root.child("scripts"), validator);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue