MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / AddNewScript

Method AddNewScript

editor/ScriptLevelInterface.cpp:1003–1018  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1001}
1002
1003bool CScriptLevelInterface::AddNewScript(void) {
1004 char filename[255];
1005
1006 if (!Network_up) {
1007 OutrageMessageBox("You need to say Yes on the initial data update, in order to\nadd files\n");
1008 return false;
1009 }
1010
1011 // Get the filename of the representing image
1012 CString filter = "Descent III Script Source (*.cpp)|*.cpp|Descent III Compiled Script (*.dll)|*.dll||";
1013
1014 if (!OpenFileDialog(this, (LPCTSTR)filter, filename, Current_files_dir, sizeof(Current_files_dir)))
1015 return false;
1016
1017 return AddNewGameFile(filename, "scripts");
1018}
1019
1020bool DeleteGamefile(char *tempbuffer) {
1021 int tl;

Callers

nothing calls this directly

Calls 3

OutrageMessageBoxFunction · 0.85
OpenFileDialogFunction · 0.85
AddNewGameFileFunction · 0.85

Tested by

no test coverage detected