MCPcopy Create free account
hub / github.com/JACoders/OpenJK / Com_WriteCam

Function Com_WriteCam

code/qcommon/common.cpp:203–222  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

201}
202
203void Com_WriteCam ( const char *text )
204{
205 static char mapname[MAX_QPATH];
206 // camerafile
207 if ( !camerafile )
208 {
209 extern cvar_t *sv_mapname;
210
211 //NOTE: always saves in working dir if using one...
212 Com_sprintf( mapname, MAX_QPATH, "maps/%s_cam.map", sv_mapname->string );
213 camerafile = FS_FOpenFileWrite( mapname );
214 }
215
216 if ( camerafile )
217 {
218 FS_Printf( camerafile, "%s", text );
219 }
220
221 Com_Printf( "%s\n", mapname );
222}
223
224void Com_FlushCamFile()
225{

Callers

nothing calls this directly

Calls 4

Com_sprintfFunction · 0.70
FS_FOpenFileWriteFunction · 0.70
FS_PrintfFunction · 0.70
Com_PrintfFunction · 0.70

Tested by

no test coverage detected