コード例 #1
0
ファイル: contest.c プロジェクト: SamRH/openTRI
/* Simple thread */
int main(int argc, char **argv)
{
	SetupCallbacks();
	
	triLogInit();
	triConsoleInit();
	
	CVARF( cl_fps, 60.0 );
	CVARS( cl_name, "Raphael" );
	CVARS_RD( sv_name, "triEngine" );
	
	triCVarRegister( &cl_fps );
	triCVarRegister( &cl_name );
	triCVarRegister( &sv_name );
	

	printf("\nPlease type 'tty' to connect to the ingame console.\n");
	printf("\nType '~.' to return to PSPLink shell.\n");
	printf("Inside the console, type 'exit' to quit the program.\n");
	printf("Type 'cmds' to get a list of available commands.\n");
	printf("Type 'cvars' to get a list of registered cvars.\n");
	
	triConsoleToggle();
	
	while (triConsoleVisible())
	{
		triConsoleUpdate();
		
		sceKernelDelayThread(250*1000);
	}

	triConsoleClose();
	triMemoryShutdown();
	sceKernelExitGame();
	return 0;
}
コード例 #2
0
ファイル: triConsole.c プロジェクト: badboy/p-twit
triChar* cmd_exit()
{
	triConsolePrint( "Exiting the console\n" );
	triConsoleToggle();
	return(0);
}