当前位置: 首页>>代码示例>>C++>>正文


C++ Cmd_RemoveCommand函数代码示例

本文整理汇总了C++中Cmd_RemoveCommand函数的典型用法代码示例。如果您正苦于以下问题:C++ Cmd_RemoveCommand函数的具体用法?C++ Cmd_RemoveCommand怎么用?C++ Cmd_RemoveCommand使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了Cmd_RemoveCommand函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: FS_Shutdown

/*
================
FS_Shutdown

Frees all resources and closes all files
================
*/
void FS_Shutdown( void ) {
	searchpath_t	*p, *next;
	int	i;

	for(i = 0; i < MAX_FILE_HANDLES; i++) {
		if (fsh[i].fileSize) {
			FS_FCloseFile(i);
		}
	}

	// free everything
	for ( p = fs_searchpaths ; p ; p = next ) {
		next = p->next;

		if ( p->pack ) {
			unzClose(p->pack->handle);
			Z_Free( p->pack->buildBuffer );
			Z_Free( p->pack );
		}
		if ( p->dir ) {
			Z_Free( p->dir );
		}
		Z_Free( p );
	}

	// any FS_ calls will now be an error until reinitialized
	fs_searchpaths = NULL;

	Cmd_RemoveCommand( "path" );
	Cmd_RemoveCommand( "dir" );
	Cmd_RemoveCommand( "fdir" );
	Cmd_RemoveCommand( "touchFile" );

	initialized = qfalse;
}
开发者ID:BishopExile,项目名称:OpenJK,代码行数:42,代码来源:files_common.cpp

示例2: INT_Shutdown

/**
 * @brief Closing actions for alien interests-subsystem
 */
void INT_Shutdown (void)
{
#ifdef DEBUG
	Cmd_RemoveCommand("debug_interestlist");
	Cmd_RemoveCommand("debug_interestset");
#endif
}
开发者ID:MyWifeRules,项目名称:ufoai-1,代码行数:10,代码来源:cp_alien_interest.cpp

示例3: S_Shutdown

void S_Shutdown(void)
{
	int		i;
	sfx_t	*sfx;

	if (!sound_started)
		return;

	SNDDMA_Shutdown();

	sound_started = 0;

	Cmd_RemoveCommand("play");
	Cmd_RemoveCommand("stopsound");
	Cmd_RemoveCommand("soundlist");
	Cmd_RemoveCommand("soundinfo");

	// free all sounds
	for (i=0, sfx=known_sfx ; i < num_sfx ; i++,sfx++)
	{
		if (!sfx->name[0])
			continue;
		memset (sfx, 0, sizeof(*sfx));
	}

	num_sfx = 0;
}
开发者ID:petmac,项目名称:quake2-lite,代码行数:27,代码来源:snd_dma.c

示例4: Com_ShutdownZoneMemory

void Com_ShutdownZoneMemory(void)
{
	assert(s_Initialized);

	// Remove commands
	Cmd_RemoveCommand("zone_stats");
	Cmd_RemoveCommand("zone_details");
	Cmd_RemoveCommand("zone_memmap");

	if (s_Stats.m_CountAlloc)
	{
		// Free all memory
//		CM_ReleaseVisData();
		Z_TagFree(TAG_ALL);
	}
	
	// Clear some globals
	memset(&s_Stats, 0, sizeof(s_Stats));
	memset(s_FreeOverflow, 0, sizeof(s_FreeOverflow));
	s_LastOverflowIndex = 0;
	s_LinkBase = NULL;

	// Free the pool
#ifndef _GAMECUBE
	GlobalFree(s_PoolBase);
	CloseHandle(s_Mutex);
#endif

	s_PoolBase = NULL;
	s_Initialized = false;
}
开发者ID:AlexCSilva,项目名称:jediacademy,代码行数:31,代码来源:z_memman_console.cpp

示例5: IN_Shutdown

void
IN_Shutdown(void)
{
	Cmd_RemoveCommand("force_centerview");
	Cmd_RemoveCommand("+mlook");
	Cmd_RemoveCommand("-mlook");

	Com_Printf("Shutting down input.\n");

#if SDL_VERSION_ATLEAST(2, 0, 0)
	IN_Haptic_Shutdown();

	if (controller)
	{
		back_button_id = -1;
		SDL_GameControllerClose(controller);
		controller  = NULL;
	}

	if (joystick)
	{
		SDL_JoystickClose(joystick);
		joystick = NULL;
	}
#endif
}
开发者ID:DrItanium,项目名称:yquake2,代码行数:26,代码来源:input.c

示例6: S_Shutdown

/**
 * @sa S_Init
 * @sa S_Restart_f
 */
void S_Shutdown (void)
{
    if (!s_env.initialized)
        return;

    M_Shutdown();

    S_Stop();

    Mix_AllocateChannels(0);

    S_FreeSamples();

    Mix_CloseAudio();

    if (SDL_WasInit(SDL_INIT_EVERYTHING) == SDL_INIT_AUDIO)
        SDL_Quit();
    else
        SDL_QuitSubSystem(SDL_INIT_AUDIO);

    Mem_DeletePool(cl_soundSysPool);

    Cmd_RemoveCommand("snd_play");
    Cmd_RemoveCommand("snd_restart");

#if COMPARE_VERSION(1, 2, 10)
    Mix_Quit();
#endif

    s_env.initialized = false;
}
开发者ID:jklemmack,项目名称:ufoai,代码行数:35,代码来源:s_main.cpp

示例7: S_Shutdown

void S_Shutdown(void)
{
	if (!sound_started)
		return;

	Cmd_RemoveCommand("play");
	Cmd_RemoveCommand("stopsound");
	Cmd_RemoveCommand("soundlist");
	Cmd_RemoveCommand("soundinfo");

	S_FreeAllSounds();

#ifdef USE_OPENAL
	if(alSound)
	{
		ALSnd_Shutdown();
		alSound = false;
	}
	else
#endif
	{
		SNDDMA_Shutdown();
	}

	sound_started = false;
}
开发者ID:hifi-unmaintained,项目名称:aprq2,代码行数:26,代码来源:snd_dma.c

示例8: INS_Shutdown

/**
 * @brief Closing operations for installations subsystem
 */
void INS_Shutdown (void)
{
	LIST_Delete(&ccs.installations);
#ifdef DEBUG
	Cmd_RemoveCommand("debug_listinstallation");
	Cmd_RemoveCommand("debug_finishinstallation");
#endif
}
开发者ID:kevlund,项目名称:ufoai,代码行数:11,代码来源:cp_installation.c

示例9: Memory_ShutdownCommands

/*
* Memory_ShutdownCommands
*/
void Memory_ShutdownCommands( void )
{
	if( !commands_initialized )
		return;

	Cmd_RemoveCommand( "memlist" );
	Cmd_RemoveCommand( "memstats" );
}
开发者ID:Kaperstone,项目名称:warsow,代码行数:11,代码来源:mem.c

示例10: FS_Shutdown

void
FS_Shutdown(void)
{
	int i;
	fsHandle_t *handle;
	fsSearchPath_t *next;
	fsPack_t *pack;

	/* Unregister commands. */
	Cmd_RemoveCommand("dir");
	Cmd_RemoveCommand("link");
	Cmd_RemoveCommand("path");

	/* Close all files. */
	for (i = 0, handle = fs_handles; i < MAX_HANDLES; i++, handle++)
	{
		if (handle->file != NULL)
		{
			fclose(handle->file);
		}

#ifdef ZIP
		if (handle->zip != NULL)
		{
			unzCloseCurrentFile(handle->zip);
			unzClose(handle->zip);
		}
#endif
	}

	/* Free the search paths. */
	while (fs_searchPaths != NULL)
	{
		if (fs_searchPaths->pack != NULL)
		{
			pack = fs_searchPaths->pack;

			if (pack->pak != NULL)
			{
				fclose(pack->pak);
			}

#ifdef ZIP
			if (pack->pk3 != NULL)
			{
				unzClose(pack->pk3);
			}
#endif

			Z_Free(pack->files);
			Z_Free(pack);
		}

		next = fs_searchPaths->next;
		Z_Free(fs_searchPaths);
		fs_searchPaths = next;
	}
}
开发者ID:Jenco420,项目名称:yquake2,代码行数:58,代码来源:filesystem.c

示例11: UI_Shutdown

/**
 * @brief Reset and free the UI data hunk
 * @note Even called in case of an error when CL_Shutdown was called - maybe even
 * before CL_InitLocal (and thus UI_Init) was called
 * @sa CL_Shutdown
 * @sa UI_Init
 */
void UI_Shutdown (void)
{
	/* MN is not yet initialized */
	if (ui_global.adata == nullptr)
		return;

	const uiBehaviour_t* confunc = UI_GetNodeBehaviour("confunc");

	/* remove all confunc commands */
	uiNode_t** nodes[] = {ui_global.windows, ui_global.components};
	for (int nodeType = 0; nodeType < 2; ++nodeType) {
		for (int i = 0; i < ui_global.numWindows; i++) {
			uiNode_t* node = nodes[nodeType][i];
			while (node) {
				/* remove the command */
				if (node->behaviour == confunc) {
					/* many nodes to one command is allowed */
					if (Cmd_Exists(node->name)) {
						Cmd_RemoveCommand(node->name);
					}
				}

				/* recursive next */
				if (node->firstChild != nullptr) {
					node = node->firstChild;
					continue;
				}
				while (node) {
					if (node->next != nullptr) {
						node = node->next;
						break;
					}
					node = node->parent;
				}
			}
		}
	}
	UI_ShutdownLua();
	UI_FontShutdown();
	UI_ResetInput();
	UI_ResetTimers();

#ifdef DEBUG
	Cmd_RemoveCommand("debug_uimemory");
#endif
	Cmd_RemoveCommand("ui_restart");

	Mem_Free(ui_global.adata);
	OBJZERO(ui_global);

	/* release pools */
	Mem_FreePool(ui_sysPool);
	Mem_FreePool(ui_dynStringPool);
	Mem_FreePool(ui_dynPool);
	ui_sysPool = nullptr;
	ui_dynStringPool = nullptr;
	ui_dynPool = nullptr;
}
开发者ID:ufoai,项目名称:ufoai,代码行数:65,代码来源:ui_main.cpp

示例12: FF_Shutdown

////-----------
/// FF_Shutdown
//---------------
//	Shut force feedback system down and free resources.
//
//	Assumptions:
//	*	Always called if FF_Init returns qfalse. ALWAYS. (Or memory leaks occur)
//	*	Never called twice in succession. (always in response to previous assumption)
//
//	Parameters:
//		None
//
//	Returns:
//		None
//
void FF_Shutdown(void)
{
#ifdef FF_CONSOLECOMMAND
	Cmd_RemoveCommand( "ff_stopall" );
	Cmd_RemoveCommand( "ff_info" );
#endif

	gFFSystem.Shutdown();
}
开发者ID:3ddy,项目名称:Jedi-Academy,代码行数:24,代码来源:ff.cpp

示例13: Cl_ShutdownKeys

/*
 * Cl_ShutdownKeys
 */
void Cl_ShutdownKeys(void) {

	Cl_WriteHistory();

	Cmd_RemoveCommand("bind");
	Cmd_RemoveCommand("unbind");
	Cmd_RemoveCommand("unbind_all");
	Cmd_RemoveCommand("bind_list");
}
开发者ID:darkshade9,项目名称:aq2w,代码行数:12,代码来源:cl_keys.c

示例14: IN_Shutdown

/*
 * Shuts the backend down
 */
void
IN_Shutdown(void)
{
	Cmd_RemoveCommand("force_centerview");
	Cmd_RemoveCommand("+mlook");
	Cmd_RemoveCommand("-mlook");

    Com_Printf("Shutting down input.\n");
}
开发者ID:bradc6,项目名称:yquake2,代码行数:12,代码来源:input.c

示例15: WIN_Shutdown

/*
===============
GLimp_Shutdown
===============
*/
void WIN_Shutdown( void )
{
	Cmd_RemoveCommand("modelist");
	Cmd_RemoveCommand("minimize");

	IN_Shutdown();

	SDL_QuitSubSystem( SDL_INIT_VIDEO );
	screen = NULL;
}
开发者ID:BruceJohnJennerLawso,项目名称:OpenJK,代码行数:15,代码来源:sdl_window.cpp


注:本文中的Cmd_RemoveCommand函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。