本文整理汇总了C++中Con_ClearNotify函数的典型用法代码示例。如果您正苦于以下问题:C++ Con_ClearNotify函数的具体用法?C++ Con_ClearNotify怎么用?C++ Con_ClearNotify使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了Con_ClearNotify函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: SCR_EndLoadingPlaque
/*
===============
SCR_EndLoadingPlaque
================
*/
void SCR_EndLoadingPlaque (void)
{
scr_disabled_for_loading = qfalse;
scr_fullupdate = 0;
Con_ClearNotify ();
CDAudio_Resume();
}
示例2: SCR_BeginLoadingPlaque
/*
===============
SCR_BeginLoadingPlaque
================
*/
void SCR_BeginLoadingPlaque (void)
{
CDAudio_Pause();
S_StopAllSounds (qtrue);
if (cls.state != ca_connected)
return;
if (cls.signon != SIGNONS)
return;
// redraw with no console and the loading plaque
Con_ClearNotify ();
scr_centertime_off = 0;
scr_con_current = 0;
scr_drawloading = qtrue;
scr_fullupdate = 0;
Sbar_Changed ();
SCR_UpdateScreen ();
scr_drawloading = qfalse;
scr_disabled_for_loading = qtrue;
scr_disabled_time = realtime;
scr_fullupdate = 0;
}
示例3: CL_InitCGame
/*
====================
CL_InitCGame
Should only be called by CL_StartHunkUsers
====================
*/
void CL_InitCGame(void)
{
const char *info;
const char *mapname;
int t1, t2;
t1 = Sys_Milliseconds();
// put away the console
Con_Close();
// find the current mapname
info = cl.gameState.stringData + cl.gameState.stringOffsets[CS_SERVERINFO];
mapname = Info_ValueForKey(info, "mapname");
Com_sprintf(cl.mapname, sizeof(cl.mapname), "maps/%s.bsp", mapname);
// load the dll
cgvm = VM_Create("cgame", CL_CgameSystemCalls, VMI_NATIVE);
if (!cgvm)
{
Com_Error(ERR_DROP, "VM_Create on cgame failed");
}
cls.state = CA_LOADING;
// init for this gamestate
// use the lastExecutedServerCommand instead of the serverCommandSequence
// otherwise server commands sent just before a gamestate are dropped
// bani - added clc.demoplaying, since some mods need this at init time, and drawactiveframe is too late for them
VM_Call(cgvm, CG_INIT, clc.serverMessageSequence, clc.lastExecutedServerCommand, clc.clientNum, clc.demoplaying, qtrue);
// reset any CVAR_CHEAT cvars registered by cgame
if (!clc.demoplaying && !cl_connectedToCheatServer)
{
Cvar_SetCheatState();
}
// we will send a usercmd this frame, which
// will cause the server to send us the first snapshot
cls.state = CA_PRIMED;
t2 = Sys_Milliseconds();
Com_Printf("CL_InitCGame: %5.2f seconds\n", (t2 - t1) / 1000.0);
// have the renderer touch all its images, so they are present
// on the card even if the driver does deferred loading
re.EndRegistration();
// make sure everything is paged in
if (!Sys_LowPhysicalMemory())
{
Com_TouchMemory();
}
// clear anything that got printed
Con_ClearNotify();
// update the memory usage file
CL_UpdateLevelHunkUsage();
}
示例4: CL_InitCGame
/*
====================
CL_InitCGame
Should only be called by CL_StartHunkUsers
====================
*/
void CL_InitCGame( void ) {
const char *info;
const char *mapname;
int t1, t2;
vmInterpret_t interpret;
t1 = Sys_Milliseconds();
// put away the console
Con_Close();
// find the current mapname
info = cl.gameState.stringData + cl.gameState.stringOffsets[ CS_SERVERINFO ];
mapname = Info_ValueForKey( info, "mapname" );
Com_sprintf( cl.mapname, sizeof( cl.mapname ), "maps/%s.bsp", mapname );
// load the dll or bytecode
if ( cl_connectedToPureServer != 0 ) {
// if sv_pure is set we only allow qvms to be loaded
interpret = VMI_COMPILED;
}
else {
interpret = Cvar_VariableValue( "vm_cgame" );
}
cgvm = VM_Create( "cgame", CL_CgameSystemCalls, interpret );
if ( !cgvm ) {
Com_Error( ERR_DROP, "VM_Create on cgame failed" );
}
cls.state = CA_LOADING;
// init for this gamestate
// use the lastExecutedServerCommand instead of the serverCommandSequence
// otherwise server commands sent just before a gamestate are dropped
VM_Call( cgvm, CG_INIT, clc.serverMessageSequence, clc.lastExecutedServerCommand, clc.clientNum );
// reset any CVAR_CHEAT cvars registered by cgame
if ( !clc.demoplaying && !cl_connectedToCheatServer )
Cvar_SetCheatState();
// we will send a usercmd this frame, which
// will cause the server to send us the first snapshot
cls.state = CA_PRIMED;
t2 = Sys_Milliseconds();
Com_DPrintf( "CL_InitCGame: %5.2f seconds\n", (t2-t1)/1000.0 );
// have the renderer touch all its images, so they are present
// on the card even if the driver does deferred loading
re.EndRegistration();
// make sure everything is paged in
if (!Sys_LowPhysicalMemory()) {
Com_TouchMemory();
}
// clear anything that got printed
Con_ClearNotify ();
CL_WriteClientLog( va("`~=-----------------=~`\n MAP: %s \n`~=-----------------=~`\n", mapname ) );
}
示例5: SCR_BeginLoadingPlaque
/*
===============
SCR_BeginLoadingPlaque
================
*/
void SCR_BeginLoadingPlaque (void)
{
S_StopAllSounds (true);
CDAudio_Stop (); // Stop the CD music
if (cls.state != ca_connected)
return;
if (cls.signon != SIGNONS)
return;
// redraw with no console and the loading plaque
Con_ClearNotify ();
// remove all center prints
con_lastcenterstring[0] = 0;
scr_centerstring[0] = 0;
scr_centertime_off = 0;
scr_con_current = 0;
scr_drawloading = true;
Sbar_Changed ();
SCR_UpdateScreen ();
scr_drawloading = false;
scr_disabled_for_loading = true;
scr_disabled_time = realtime;
SCR_SetTimeout (SCR_DEFTIMEOUT);
}
示例6: SCR_EndLoadingPlaque
/*
===============
SCR_EndLoadingPlaque
================
*/
void SCR_EndLoadingPlaque (void)
{
scr_disabled_for_loading = false;
scr_fullupdate = 0;
scr_topupdate = 0;
Con_ClearNotify ();
}
示例7: SCR_EndLoadingPlaque
/*
================
SCR_EndLoadingPlaque
================
*/
void SCR_EndLoadingPlaque (qboolean clear)
{
cls.disable_screen = 0;
// mattx86: a work-around for notify lines + console + not breaking this function
if (clear)
Con_ClearNotify ();
}
示例8: Con_Close
/*
* Con_Close
*/
void Con_Close( void )
{
scr_con_current = 0;
Con_ClearTyping();
Con_ClearNotify();
Key_ClearStates();
}
示例9: Client_PrepRefresh
/*
-----------------------------------------------------------------------------
Function:
Parameters:
Returns:
Notes:
-----------------------------------------------------------------------------
*/
PUBLIC void Client_PrepRefresh( const char *r_mapname )
{
char mapname[ 32 ];
if( ! r_mapname || ! *r_mapname )
{
return;
}
if( g_version->value == SPEAROFDESTINY )
{
spritelocation = SODSPRITESDIRNAME;
}
else
{
spritelocation = WL6SPRITESDIRNAME;
}
my_strlcpy( mapname, r_mapname, sizeof( mapname ) ); // skip "maps/"
// [email protected]# fix crash bug if you type something short...
if ( strlen( mapname ) > 4 && !strcmp( mapname + strlen( mapname ) - 4, ".map" ) ) {
mapname[ strlen( mapname ) - 4 ] = '\0'; // cut off ".map"
}
// register models, pics, and skins
R_BeginRegistration( mapname );
if( r_world == NULL )
{
return;
}
Com_Printf( "Map: %s\n", r_world->mapName );
Level_ScanInfoPlane( r_world ); // Spawn items/guards
Com_Printf( "Spawning Entities\n" );
PL_Spawn( r_world->pSpawn, r_world ); // Spawn Player
Com_Printf( "Caching Textures and Sounds\n" );
Level_PrecacheTextures_Sound( r_world );
// clear any lines of console text
Con_ClearNotify();
if( r_world->musicName )
{
Sound_StartBGTrack( r_world->musicName, r_world->musicName );
}
Player.playstate = ex_playing;
}
示例10: SCR_CenterPrint
/*
==============
SCR_CenterPrint
Called for important messages that should stay in the center of the screen
for a few moments
==============
*/
void SCR_CenterPrint (char *str)
{
char *s;
char line[64];
int i, j, l;
strncpy (scr_centerstring, str, sizeof(scr_centerstring)-1);
scr_centertime_off = scr_centertime->value;
scr_centertime_start = cl.time;
// count the number of lines for centering
scr_center_lines = 1;
s = str;
while (*s)
{
if (*s == '\n')
scr_center_lines++;
s++;
}
// echo it to the console
Com_Printf("\n\n\35\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\37\n\n");
s = str;
do
{
// scan the width of the line
for (l=0 ; l<40 ; l++)
if (s[l] == '\n' || !s[l])
break;
for (i=0 ; i<(40-l)/2 ; i++)
line[i] = ' ';
for (j=0 ; j<l ; j++)
{
line[i++] = s[j];
}
line[i] = '\n';
line[i+1] = 0;
Com_Printf ("%s", line);
while (*s && *s != '\n')
s++;
if (!*s)
break;
s++; // skip the \n
} while (1);
Com_Printf("\n\n\35\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\36\37\n\n");
Con_ClearNotify ();
}
示例11: Con_Resize
/*
================
Con_Resize
================
*/
void Con_Resize (console_t *con)
{
int i, j, width, oldwidth, oldtotallines, numlines, numchars;
char tbuf[CON_TEXTSIZE];
//GAJA STRIP width = (vid.width >> 3) - 2;
if (width == con_linewidth)
return;
if (width < 1) // video hasn't been initialized yet
{
width = 38;
con_linewidth = width;
con_totallines = CON_TEXTSIZE / con_linewidth;
Q_memset (con->text, ' ', CON_TEXTSIZE);
}
else
{
oldwidth = con_linewidth;
con_linewidth = width;
oldtotallines = con_totallines;
con_totallines = CON_TEXTSIZE / con_linewidth;
numlines = oldtotallines;
if (con_totallines < numlines)
numlines = con_totallines;
numchars = oldwidth;
if (con_linewidth < numchars)
numchars = con_linewidth;
Q_memcpy (tbuf, con->text, CON_TEXTSIZE);
Q_memset (con->text, ' ', CON_TEXTSIZE);
for (i=0 ; i<numlines ; i++)
{
for (j=0 ; j<numchars ; j++)
{
con->text[(con_totallines - 1 - i) * con_linewidth + j] =
tbuf[((con->current - i + oldtotallines) %
oldtotallines) * oldwidth + j];
}
}
Con_ClearNotify ();
}
con->current = con_totallines - 1;
con->display = con->current;
}
示例12: Con_Close
void Con_Close( void )
{
if ( !com_cl_running->integer )
{
return;
}
Field_Clear( &g_consoleField );
Con_ClearNotify();
cls.keyCatchers &= ~KEYCATCH_CONSOLE;
con.finalFrac = 0; // none visible
con.displayFrac = 0;
}
示例13: Con_ToggleChat_f
/*
================
Con_ToggleChat_f
================
*/
void Con_ToggleChat_f (void)
{
Key_ClearTyping ();
if (key_dest == key_console)
{
if (cls.state == ca_active)
key_dest = key_game;
}
else
key_dest = key_console;
Con_ClearNotify ();
}
示例14: Con_ToggleConsole_f
/*
================
Con_ToggleConsole_f
================
*/
void Con_ToggleConsole_f (void) {
// closing a full screen console restarts the demo loop
if ( cls.state == CA_DISCONNECTED && Key_GetCatcher( ) == KEYCATCH_CONSOLE ) {
CL_StartDemoLoop();
return;
}
if( con_autoclear->integer )
Field_Clear( &g_consoleField );
g_consoleField.widthInChars = g_console_field_width;
Con_ClearNotify ();
Key_SetCatcher( Key_GetCatcher( ) ^ KEYCATCH_CONSOLE );
}
示例15: CL_ScreenShot_f
/*
==================
CL_ScreenShot_f
normal screenshot
==================
*/
void CL_ScreenShot_f( void )
{
int i;
string checkname;
// scan for a free filename
for( i = 0; i <= 9999; i++ )
{
CL_ScreenshotGetName( i, checkname );
if( !FS_FileExists( checkname )) break;
}
Con_ClearNotify();
re->ScrShot( checkname, VID_SCREENSHOT );
}