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

Function writeline

editor/ScriptMassCompile.cpp:206–225  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

204}
205
206void writeline(char *format, ...) {
207 char buffer[2048];
208 va_list marker;
209 va_start(marker, format);
210 std::vsprintf(buffer, format, marker);
211 va_end(marker);
212
213 MassScriptEditContent += buffer;
214 MassScriptEditContent += "\r\n";
215
216 MassScriptEdit->SetWindowText(MassScriptEditContent.GetBuffer(0));
217 Descent->defer();
218
219 int total_lines = MassScriptEdit->GetLineCount();
220 int curr_index = MassScriptEdit->GetFirstVisibleLine();
221 if ((total_lines - curr_index) > 16) {
222 // we need to scroll down a line
223 MassScriptEdit->LineScroll((total_lines - curr_index) - 16);
224 }
225}
226
227uint8_t DetermineScriptType(char *filename) {
228 CFILE *file;

Callers 6

OnBuildMethod · 0.85
OnInitDialogMethod · 0.85
Step1Method · 0.85
Step2Method · 0.85
Step3Method · 0.85
Step4Method · 0.85

Calls 2

GetBufferMethod · 0.80
deferMethod · 0.45

Tested by

no test coverage detected