code

equ trap_Print								  -2	; UI_PRINT 
equ trap_Error								  -1	; UI_ERROR 
equ trap_Milliseconds						  -3	; UI_MILLISECONDS 
equ trap_Cvar_Register						 -51	; UI_CVAR_REGISTER 
equ trap_Cvar_Update						 -52	; UI_CVAR_UPDATE 
equ trap_Cvar_Set							  -4	; UI_CVAR_SET 
equ trap_Cvar_VariableValue					  -5	; UI_CVAR_VARIABLEVALUE 
equ trap_Cvar_VariableStringBuffer			  -6	; UI_CVAR_VARIABLESTRINGBUFFER 
equ trap_Cvar_SetValue						  -7	; UI_CVAR_SETVALUE 
equ trap_Cvar_Reset							  -8	; UI_CVAR_RESET 
equ trap_Cvar_Create						  -9	; UI_CVAR_CREATE 
equ trap_Cvar_InfoStringBuffer				 -10	; UI_CVAR_INFOSTRINGBUFFER 
equ trap_Argc								 -11	; UI_ARGC 
equ trap_Argv								 -12	; UI_ARGV 
equ trap_Cmd_ExecuteText					 -13	; UI_CMD_EXECUTETEXT 
equ trap_FS_FOpenFile						 -14	; UI_FS_FOPENFILE 
equ trap_FS_Read							 -15	; UI_FS_READ 
equ trap_FS_Write							 -16	; UI_FS_WRITE 
equ trap_FS_FCloseFile						 -17	; UI_FS_FCLOSEFILE 
equ trap_FS_GetFileList						 -18	; UI_FS_GETFILELIST 
equ trap_R_RegisterModel					 -19	; UI_R_REGISTERMODEL 
equ trap_R_RegisterSkin						 -20	; UI_R_REGISTERSKIN 
equ trap_R_RegisterFont						 -56	; UI_R_REGISTERFONT 
equ trap_R_RegisterShaderNoMip				 -21	; UI_R_REGISTERSHADERNOMIP 
equ trap_R_ClearScene						 -22	; UI_R_CLEARSCENE 
equ trap_R_AddRefEntityToScene				 -23	; UI_R_ADDREFENTITYTOSCENE 
equ trap_R_AddPolyToScene					 -24	; UI_R_ADDPOLYTOSCENE 
equ trap_R_AddLightToScene					 -25	; UI_R_ADDLIGHTTOSCENE 
equ trap_R_RenderScene						 -26	; UI_R_RENDERSCENE 
equ trap_R_SetColor							 -27	; UI_R_SETCOLOR 
equ trap_R_DrawStretchPic					 -28	; UI_R_DRAWSTRETCHPIC 
equ trap_R_ModelBounds						 -61	; UI_R_MODELBOUNDS 
equ trap_R_GetTextWidth						 -57	; UI_R_GETTEXTWIDTH 
equ trap_R_GetTextHeight					 -58	; UI_R_GETTEXTHEIGHT 
equ trap_R_DrawText							 -59	; UI_R_DRAWTEXT 
equ trap_R_DrawTextWithCursor				 -60	; UI_R_DRAWTEXTWITHCURSOR 
equ trap_UpdateScreen						 -29	; UI_UPDATESCREEN 
equ trap_CM_LerpTag							 -30	; UI_CM_LERPTAG 
equ trap_S_StartLocalSound					 -33	; UI_S_STARTLOCALSOUND 
equ trap_S_RegisterSound					 -32	; UI_S_REGISTERSOUND 
equ trap_Key_KeynumToStringBuf				 -34	; UI_KEY_KEYNUMTOSTRINGBUF 
equ trap_Key_GetBindingBuf					 -35	; UI_KEY_GETBINDINGBUF 
equ trap_Key_SetBinding						 -36	; UI_KEY_SETBINDING 
equ trap_Key_IsDown							 -37	; UI_KEY_ISDOWN 
equ trap_Key_GetOverstrikeMode				 -38	; UI_KEY_GETOVERSTRIKEMODE 
equ trap_Key_SetOverstrikeMode				 -39	; UI_KEY_SETOVERSTRIKEMODE 
equ trap_Key_ClearStates					 -40	; UI_KEY_CLEARSTATES 
equ trap_Key_GetCatcher						 -41	; UI_KEY_GETCATCHER 
equ trap_Key_SetCatcher						 -42	; UI_KEY_SETCATCHER 
equ trap_GetClipboardData					 -43	; UI_GETCLIPBOARDDATA 
equ trap_GetClientState						 -45	; UI_GETCLIENTSTATE 
equ trap_GetGlconfig						 -44	; UI_GETGLCONFIG 
equ trap_GetConfigString					 -46	; UI_GETCONFIGSTRING 
equ trap_LAN_GetServerCount					 -72	; UI_LAN_GETSERVERCOUNT 
equ trap_LAN_GetServerAddressString			 -73	; UI_LAN_GETSERVERADDRESSSTRING 
equ trap_LAN_GetServerInfo					 -74	; UI_LAN_GETSERVERINFO 
equ trap_LAN_GetServerPing					 -90	; UI_LAN_GETSERVERPING 
equ trap_LAN_GetPingQueueCount				 -47	; UI_LAN_GETPINGQUEUECOUNT 
equ trap_LAN_ServerStatus					 -89	; UI_LAN_SERVERSTATUS 
equ trap_LAN_SaveCachedServers				 -79	; UI_LAN_SAVECACHEDSERVERS 
equ trap_LAN_LoadCachedServers				 -78	; UI_LAN_LOADCACHEDSERVERS 
equ trap_LAN_ResetPings						 -77	; UI_LAN_RESETPINGS 
equ trap_LAN_ClearPing						 -48	; UI_LAN_CLEARPING 
equ trap_LAN_GetPing						 -49	; UI_LAN_GETPING 
equ trap_LAN_GetPingInfo					 -50	; UI_LAN_GETPINGINFO 
equ trap_LAN_MarkServerVisible				 -75	; UI_LAN_MARKSERVERVISIBLE 
equ trap_LAN_ServerIsVisible				 -91	; UI_LAN_SERVERISVISIBLE 
equ trap_LAN_UpdateVisiblePings				 -76	; UI_LAN_UPDATEVISIBLEPINGS 
equ trap_LAN_AddServer						 -80	; UI_LAN_ADDSERVER 
equ trap_LAN_RemoveServer					 -81	; UI_LAN_REMOVESERVER 
equ trap_LAN_CompareServers					 -92	; UI_LAN_COMPARESERVERS 
equ trap_MemoryRemaining					 -53	; UI_MEMORY_REMAINING 
equ trap_GetCDKey							 -54	; UI_GET_CDKEY 
equ trap_SetCDKey							 -55	; UI_SET_CDKEY 
equ trap_PC_AddGlobalDefine					 -62	; UI_PC_ADD_GLOBAL_DEFINE 
equ trap_PC_LoadSource						 -63	; UI_PC_LOAD_SOURCE 
equ trap_PC_FreeSource						 -64	; UI_PC_FREE_SOURCE 
equ trap_PC_ReadToken						 -65	; UI_PC_READ_TOKEN 
equ trap_PC_SourceFileAndLine				 -66	; UI_PC_SOURCE_FILE_AND_LINE 
equ trap_PC_LoadGlobalDefines				 -67	; UI_PC_LOAD_GLOBAL_DEFINES 
equ trap_PC_RemoveAllGlobalDefines			 -68	; UI_PC_REMOVE_ALL_GLOBAL_DEFINES 
equ trap_S_StopBackgroundTrack				 -69	; UI_S_STOPBACKGROUNDTRACK 
equ trap_S_StartBackgroundTrack				 -70	; UI_S_STARTBACKGROUNDTRACK 
equ trap_RealTime							 -71	; UI_REAL_TIME 
equ trap_CIN_PlayCinematic					 -82	; UI_CIN_PLAYCINEMATIC 
equ trap_CIN_StopCinematic					 -83	; UI_CIN_STOPCINEMATIC 
equ trap_CIN_RunCinematic					 -84	; UI_CIN_RUNCINEMATIC 
equ trap_CIN_DrawCinematic					 -85	; UI_CIN_DRAWCINEMATIC 
equ trap_CIN_SetExtents						 -86	; UI_CIN_SETEXTENTS 
equ trap_R_RemapShader						 -87	; UI_R_REMAP_SHADER 
equ trap_VerifyCDKey						 -88	; UI_VERIFY_CDKEY 
equ trap_G2_ListModelSurfaces				-118	; UI_G2_LISTSURFACES 
equ trap_G2_ListModelBones					-117	; UI_G2_LISTBONES 
equ trap_G2_SetGhoul2ModelIndexes			-123	; UI_G2_SETMODELS 
equ trap_G2API_AddBolt						-119	; UI_G2_ADDBOLT 
equ trap_G2API_RemoveBolt					-120	; UI_G2_REMOVEBOLT 
equ trap_G2API_AttachG2Model				-121	; UI_G2_ATTACHG2MODEL 
equ trap_G2_HaveWeGhoul2Models				-122	; UI_G2_HAVEWEGHOULMODELS 
equ trap_G2API_GetBoltMatrix				-124	; UI_G2_GETBOLT 
equ trap_G2API_InitGhoul2Model				-125	; UI_G2_INITGHOUL2MODEL 
equ trap_G2API_CleanGhoul2Models			-126	; UI_G2_CLEANMODELS 
equ trap_G2API_SetBoneAngles				-127	; UI_G2_ANGLEOVERRIDE 
equ trap_G2API_SetBoneAnim					-128	; UI_G2_PLAYANIM 
equ trap_G2API_GetGLAName					-129	; UI_G2_GETGLANAME 
equ trap_G2API_CopyGhoul2Instance			-130	; UI_G2_COPYGHOUL2INSTANCE 
equ trap_G2API_CopySpecifiUIhoul2Model		-131	; UI_G2_COPYSPECIFICGHOUL2MODEL 
equ trap_G2API_DuplicateGhoul2Instance		-132	; UI_G2_DUPLICATEGHOUL2INSTANCE 
equ trap_G2API_RemoveGhoul2Model			-133	; UI_G2_REMOVEGHOUL2MODEL 
equ trap_G2API_SetSurfaceOnOff				-139	; UI_G2_SETSURFACEONOFF 
equ trap_G2API_GetAnimFileNameIndex			-142	; UI_G2_GETANIMFILENAMEINDEX 
equ trap_G2API_RegisterSkin					-140	; UI_G2_REGISTERSKIN 
equ trap_G2API_SetSkin						-141	; UI_G2_SETSKIN 
equ trap_GP_Parse							-134	; UI_GP_PARSE 
equ trap_GP_ParseFile						-135	; UI_GP_PARSE_FILE 
equ trap_GP_Clean							-136	; UI_GP_CLEAN 
equ trap_GP_Delete							-137	; UI_GP_DELETE 
equ trap_GP_GetBaseParseGroup				-138	; UI_GP_GET_BASE_PARSE_GROUP 
equ trap_GPG_GetName						-143	; UI_GPG_GET_NAME 
equ trap_GPG_GetNext						-144	; UI_GPG_GET_NEXT 
equ trap_GPG_GetInOrderNext					-145	; UI_GPG_GET_INORDER_NEXT 
equ trap_GPG_GetInOrderPrevious				-146	; UI_GPG_GET_INORDER_PREVIOUS 
equ trap_GPG_GetPairs						-147	; UI_GPG_GET_PAIRS 
equ trap_GPG_GetInOrderPairs				-148	; UI_GPG_GET_INORDER_PAIRS 
equ trap_GPG_GetSubGroups					-149	; UI_GPG_GET_SUBGROUPS 
equ trap_GPG_GetInOrderSubGroups			-150	; UI_GPG_GET_INORDER_SUBGROUPS 
equ trap_GPG_FindSubGroup					-151	; UI_GPG_FIND_SUBGROUP 
equ trap_GPG_FindPair						-152	; UI_GPG_FIND_PAIR 
equ trap_GPG_FindPairValue					-153	; UI_GPG_FIND_PAIRVALUE 
equ trap_GPV_GetName						-154	; UI_GPV_GET_NAME 
equ trap_GPV_GetNext						-155	; UI_GPV_GET_NEXT 
equ trap_GPV_GetInOrderNext					-156	; UI_GPV_GET_INORDER_NEXT 
equ trap_GPV_GetInOrderPrevious				-157	; UI_GPV_GET_INORDER_PREVIOUS 
equ trap_GPV_IsList							-158	; UI_GPV_IS_LIST 
equ trap_GPV_GetTopValue					-159	; UI_GPV_GET_TOP_VALUE 
equ trap_GPV_GetList						-160	; UI_GPV_GET_LIST 
equ trap_Parental_Update					-165	; UI_PARENTAL_UPDATE 
equ trap_Parental_SetPassword				-166	; UI_PARENTAL_SET_PASSWORD 
equ trap_Parental_GetPassword				-167	; UI_PARENTAL_GET_PASSWORD 
equ trap_VM_LocalAlloc						-168	; UI_VM_LOCALALLOC 
equ trap_VM_LocalAllocUnaligned				-169	; UI_VM_LOCALALLOCUNALIGNED 
equ trap_VM_LocalTempAlloc					-170	; UI_VM_LOCALTEMPALLOC 
equ trap_VM_LocalTempFree					-171	; UI_VM_LOCALTEMPFREE 
equ trap_VM_LocalStringAlloc				-172	; UI_VM_LOCALSTRINGALLOC 
equ trap_NET_Available						-173	; UI_NET_AVAILABLE 
equ trap_Version_GetDescription				-174	; UI_VERSION_GET_DESCRIPTION 
equ trap_Version_GetNumSites				-175	; UI_VERSION_GET_NUM_SITES 
equ trap_Version_GetSite					-176	; UI_VERSION_GET_SITE 
equ trap_Version_Download					-177	; UI_VERSION_DOWNLOAD 
equ trap_PunkBuster_Enable					-178	; UI_PB_ENABLE 
equ trap_PunkBuster_Disable					-179	; UI_PB_DISABLE 
equ trap_PunkBuster_IsEnabled				-180	; UI_PB_ISENABLED 
equ trap_GetTeamCount						-181	; UI_GET_TEAM_COUNT 
equ trap_GetTeamScore						-182	; UI_GET_TEAM_SCORE 


; hardcoded functions
equ memset									-101	; UI_MEMSET 
equ memcpy									-102	; UI_MEMCPY 
equ strncpy									-103	; UI_STRNCPY 
equ sin										-104	; UI_SIN 
equ cos										-105	; UI_COS 
equ atan2									-106	; UI_ATAN2 
equ sqrt									-107	; UI_SQRT 
equ matrixmultiply							-116	; UI_MATRIXMULTIPLY 
equ anglevectors							-109	; UI_ANGLEVECTORS 
equ perpendicularvector						-110	; UI_PERPENDICULARVECTOR 
equ floor									-108	; UI_FLOOR 
equ ceil									-111	; UI_CEIL 
equ acos									-114	; UI_ACOS 
equ asin									-115	; UI_ASIN 
