Expose the same ReadJSONFile function to simulation, GUI and rmgen.

This way globalscripts/ can use the same code in all contexts, all paths
are absolute and only one function name is needed.
Remove ReadCivJSONFile which is redundant with this function as well.
Restrict read access of rmgen/ to rmgen/ and simulation/, refs
4275a8a33c, 89055ef858.

Refs #4868
Differential Revision: https://code.wildfiregames.com/D1085
Reviewed By: wraitii
Partial agreement with leper

This was SVN commit r20576.
This commit is contained in:
elexis
2017-12-03 23:02:27 +00:00
parent 5e85ca5d7b
commit 0cfe9ab153
10 changed files with 78 additions and 67 deletions
+1 -2
View File
@@ -65,7 +65,6 @@ void GuiScriptingInit(ScriptInterface& scriptInterface)
JSI_SavedGame::RegisterScriptFunctions(scriptInterface);
JSI_Simulation::RegisterScriptFunctions(scriptInterface);
JSI_Sound::RegisterScriptFunctions(scriptInterface);
JSI_VFS::RegisterReadOnlyScriptFunctions(scriptInterface);
JSI_VFS::RegisterWriteScriptFunctions(scriptInterface);
JSI_VFS::RegisterScriptFunctions_GUI(scriptInterface);
JSI_VisualReplay::RegisterScriptFunctions(scriptInterface);
}