4 // api_info.cpp - info for api routines
9 * This file is part of Metamod.
11 * Metamod is free software; you can redistribute it and/or modify it
12 * under the terms of the GNU General Public License as published by the
13 * Free Software Foundation; either version 2 of the License, or (at
14 * your option) any later version.
16 * Metamod is distributed in the hope that it will be useful, but
17 * WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with Metamod; if not, write to the Free Software Foundation,
23 * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 * In addition, as a special exception, the author gives permission to
26 * link the code of this program with the Half-Life Game Engine ("HL
27 * Engine") and Modified Game Libraries ("MODs") developed by Valve,
28 * L.L.C ("Valve"). You must obey the GNU General Public License in all
29 * respects for all of the code used other than the HL Engine and MODs
30 * from Valve. If you modify this file, you may extend this exception
31 * to your version of the file, but you are not obligated to do so. If
32 * you do not wish to do so, delete this exception statement from your
37 #include <extdll.h> // always
39 #include "api_info.h" // me
41 // trace flag, loglevel, name
42 dllapi_info_t dllapi_info = {
43 { mFALSE, 3, "GameDLLInit" }, // pfnGameInit
44 { mFALSE, 10, "DispatchSpawn" }, // pfnSpawn
45 { mFALSE, 16, "DispatchThink" }, // pfnThink
46 { mFALSE, 9, "DispatchUse" }, // pfnUse
47 { mFALSE, 11, "DispatchTouch" }, // pfnTouch
48 { mFALSE, 9, "DispatchBlocked" }, // pfnBlocked
49 { mFALSE, 10, "DispatchKeyValue" }, // pfnKeyValue
50 { mFALSE, 9, "DispatchSave" }, // pfnSave
51 { mFALSE, 9, "DispatchRestore" }, // pfnRestore
52 { mFALSE, 20, "DispatchObjectCollsionBox" }, // pfnSetAbsBox
53 { mFALSE, 9, "SaveWriteFields" }, // pfnSaveWriteFields
54 { mFALSE, 9, "SaveReadFields" }, // pfnSaveReadFields
55 { mFALSE, 9, "SaveGlobalState" }, // pfnSaveGlobalState
56 { mFALSE, 9, "RestoreGlobalState" }, // pfnRestoreGlobalState
57 { mFALSE, 9, "ResetGlobalState" }, // pfnResetGlobalState
58 { mFALSE, 3, "ClientConnect" }, // pfnClientConnect
59 { mFALSE, 3, "ClientDisconnect" }, // pfnClientDisconnect
60 { mFALSE, 3, "ClientKill" }, // pfnClientKill
61 { mFALSE, 3, "ClientPutInServer" }, // pfnClientPutInServer
62 { mFALSE, 9, "ClientCommand" }, // pfnClientCommand
63 { mFALSE, 11, "ClientUserInfoChanged" }, // pfnClientUserInfoChanged
64 { mFALSE, 3, "ServerActivate" }, // pfnServerActivate
65 { mFALSE, 3, "ServerDeactivate" }, // pfnServerDeactivate
66 { mFALSE, 14, "PlayerPreThink" }, // pfnPlayerPreThink
67 { mFALSE, 14, "PlayerPostThink" }, // pfnPlayerPostThink
68 { mFALSE, 18, "StartFrame" }, // pfnStartFrame
69 { mFALSE, 9, "ParmsNewLevel" }, // pfnParmsNewLevel
70 { mFALSE, 9, "ParmsChangeLevel" }, // pfnParmsChangeLevel
71 { mFALSE, 9, "GetGameDescription" }, // pfnGetGameDescription
72 { mFALSE, 9, "PlayerCustomization" }, // pfnPlayerCustomization
73 { mFALSE, 9, "SpectatorConnect" }, // pfnSpectatorConnect
74 { mFALSE, 9, "SpectatorDisconnect" }, // pfnSpectatorDisconnect
75 { mFALSE, 9, "SpectatorThink" }, // pfnSpectatorThink
76 { mFALSE, 3, "Sys_Error" }, // pfnSys_Error
77 { mFALSE, 13, "PM_Move" }, // pfnPM_Move
78 { mFALSE, 9, "PM_Init" }, // pfnPM_Init
79 { mFALSE, 9, "PM_FindTextureType" }, // pfnPM_FindTextureType
80 { mFALSE, 12, "SetupVisibility" }, // pfnSetupVisibility
81 { mFALSE, 12, "UpdateClientData" }, // pfnUpdateClientData
82 { mFALSE, 16, "AddToFullPack" }, // pfnAddToFullPack
83 { mFALSE, 9, "CreateBaseline" }, // pfnCreateBaseline
84 { mFALSE, 9, "RegisterEncoders" }, // pfnRegisterEncoders
85 { mFALSE, 9, "GetWeaponData" }, // pfnGetWeaponData
86 { mFALSE, 15, "CmdStart" }, // pfnCmdStart
87 { mFALSE, 15, "CmdEnd" }, // pfnCmdEnd
88 { mFALSE, 9, "ConnectionlessPacket" }, // pfnConnectionlessPacket
89 { mFALSE, 9, "GetHullBounds" }, // pfnGetHullBounds
90 { mFALSE, 9, "CreateInstancedBaselines" }, // pfnCreateInstancedBaselines
91 { mFALSE, 3, "InconsistentFile" }, // pfnInconsistentFile
92 { mFALSE, 20, "AllowLagCompensation" }, // pfnAllowLagCompensation
96 newapi_info_t newapi_info = {
97 { mFALSE, 16, "OnFreeEntPrivateData" }, // pfnOnFreeEntPrivateData
98 { mFALSE, 3, "GameShutdown" }, // pfnGameShutdown
99 { mFALSE, 14, "ShouldCollide" }, // pfnShouldCollide
103 engine_info_t engine_info = {
104 { mFALSE, 13, "PrecacheModel" }, // pfnPrecacheModel
105 { mFALSE, 13, "PrecacheSound" }, // pfnPrecacheSound
106 { mFALSE, 18, "SetModel" }, // pfnSetModel
107 { mFALSE, 34, "ModelIndex" }, // pfnModelIndex
108 { mFALSE, 10, "ModelFrames" }, // pfnModelFrames
109 { mFALSE, 14, "SetSize" }, // pfnSetSize
110 { mFALSE, 9, "ChangeLevel" }, // pfnChangeLevel
111 { mFALSE, 9, "GetSpawnParms" }, // pfnGetSpawnParms
112 { mFALSE, 9, "SaveSpawnParms" }, // pfnSaveSpawnParms
113 { mFALSE, 9, "VecToYaw" }, // pfnVecToYaw
114 { mFALSE, 14, "VecToAngles" }, // pfnVecToAngles
115 { mFALSE, 9, "MoveToOrigin" }, // pfnMoveToOrigin
116 { mFALSE, 9, "ChangeYaw" }, // pfnChangeYaw
117 { mFALSE, 9, "ChangePitch" }, // pfnChangePitch
118 { mFALSE, 32, "FindEntityByString" }, // pfnFindEntityByString
119 { mFALSE, 9, "GetEntityIllum" }, // pfnGetEntityIllum
120 { mFALSE, 9, "FindEntityInSphere" }, // pfnFindEntityInSphere
121 { mFALSE, 19, "FindClientInPVS" }, // pfnFindClientInPVS
122 { mFALSE, 9, "EntitiesInPVS" }, // pfnEntitiesInPVS
123 { mFALSE, 40, "MakeVectors" }, // pfnMakeVectors
124 { mFALSE, 9, "AngleVectors" }, // pfnAngleVectors
125 { mFALSE, 13, "CreateEntity" }, // pfnCreateEntity
126 { mFALSE, 13, "RemoveEntity" }, // pfnRemoveEntity
127 { mFALSE, 13, "CreateNamedEntity" }, // pfnCreateNamedEntity
128 { mFALSE, 9, "MakeStatic" }, // pfnMakeStatic
129 { mFALSE, 9, "EntIsOnFloor" }, // pfnEntIsOnFloor
130 { mFALSE, 9, "DropToFloor" }, // pfnDropToFloor
131 { mFALSE, 9, "WalkMove" }, // pfnWalkMove
132 { mFALSE, 14, "SetOrigin" }, // pfnSetOrigin
133 { mFALSE, 12, "EmitSound" }, // pfnEmitSound
134 { mFALSE, 12, "EmitAmbientSound" }, // pfnEmitAmbientSound
135 { mFALSE, 20, "TraceLine" }, // pfnTraceLine
136 { mFALSE, 9, "TraceToss" }, // pfnTraceToss
137 { mFALSE, 9, "TraceMonsterHull" }, // pfnTraceMonsterHull
138 { mFALSE, 9, "TraceHull" }, // pfnTraceHull
139 { mFALSE, 9, "TraceModel" }, // pfnTraceModel
140 { mFALSE, 15, "TraceTexture" }, // pfnTraceTexture // CS: when moving
141 { mFALSE, 9, "TraceSphere" }, // pfnTraceSphere
142 { mFALSE, 9, "GetAimVector" }, // pfnGetAimVector
143 { mFALSE, 9, "ServerCommand" }, // pfnServerCommand
144 { mFALSE, 9, "ServerExecute" }, // pfnServerExecute
145 { mFALSE, 11, "engClientCommand" }, // pfnClientCommand // d'oh, ClientCommand in dllapi too
146 { mFALSE, 9, "ParticleEffect" }, // pfnParticleEffect
147 { mFALSE, 9, "LightStyle" }, // pfnLightStyle
148 { mFALSE, 9, "DecalIndex" }, // pfnDecalIndex
149 { mFALSE, 15, "PointContents" }, // pfnPointContents // CS: when moving
150 { mFALSE, 22, "MessageBegin" }, // pfnMessageBegin
151 { mFALSE, 22, "MessageEnd" }, // pfnMessageEnd
152 { mFALSE, 30, "WriteByte" }, // pfnWriteByte
153 { mFALSE, 23, "WriteChar" }, // pfnWriteChar
154 { mFALSE, 24, "WriteShort" }, // pfnWriteShort
155 { mFALSE, 23, "WriteLong" }, // pfnWriteLong
156 { mFALSE, 23, "WriteAngle" }, // pfnWriteAngle
157 { mFALSE, 23, "WriteCoord" }, // pfnWriteCoord
158 { mFALSE, 25, "WriteString" }, // pfnWriteString
159 { mFALSE, 23, "WriteEntity" }, // pfnWriteEntity
160 { mFALSE, 9, "CVarRegister" }, // pfnCVarRegister
161 { mFALSE, 21, "CVarGetFloat" }, // pfnCVarGetFloat
162 { mFALSE, 9, "CVarGetString" }, // pfnCVarGetString
163 { mFALSE, 10, "CVarSetFloat" }, // pfnCVarSetFloat
164 { mFALSE, 9, "CVarSetString" }, // pfnCVarSetString
165 { mFALSE, 15, "AlertMessage" }, // pfnAlertMessage
166 { mFALSE, 17, "EngineFprintf" }, // pfnEngineFprintf
167 { mFALSE, 14, "PvAllocEntPrivateData" }, // pfnPvAllocEntPrivateData
168 { mFALSE, 9, "PvEntPrivateData" }, // pfnPvEntPrivateData
169 { mFALSE, 9, "FreeEntPrivateData" }, // pfnFreeEntPrivateData
170 { mFALSE, 9, "SzFromIndex" }, // pfnSzFromIndex
171 { mFALSE, 10, "AllocString" }, // pfnAllocString
172 { mFALSE, 9, "GetVarsOfEnt" }, // pfnGetVarsOfEnt
173 { mFALSE, 14, "PEntityOfEntOffset" }, // pfnPEntityOfEntOffset
174 { mFALSE, 19, "EntOffsetOfPEntity" }, // pfnEntOffsetOfPEntity
175 { mFALSE, 14, "IndexOfEdict" }, // pfnIndexOfEdict
176 { mFALSE, 17, "PEntityOfEntIndex" }, // pfnPEntityOfEntIndex
177 { mFALSE, 9, "FindEntityByVars" }, // pfnFindEntityByVars
178 { mFALSE, 14, "GetModelPtr" }, // pfnGetModelPtr
179 { mFALSE, 9, "RegUserMsg" }, // pfnRegUserMsg
180 { mFALSE, 9, "AnimationAutomove" }, // pfnAnimationAutomove
181 { mFALSE, 9, "GetBonePosition" }, // pfnGetBonePosition
182 { mFALSE, 9, "FunctionFromName" }, // pfnFunctionFromName
183 { mFALSE, 9, "NameForFunction" }, // pfnNameForFunction
184 { mFALSE, 9, "ClientPrintf" }, // pfnClientPrintf
185 { mFALSE, 9, "ServerPrint" }, // pfnServerPrint
186 { mFALSE, 13, "Cmd_Args" }, // pfnCmd_Args
187 { mFALSE, 13, "Cmd_Argv" }, // pfnCmd_Argv
188 { mFALSE, 13, "Cmd_Argc" }, // pfnCmd_Argc
189 { mFALSE, 9, "GetAttachment" }, // pfnGetAttachment
190 { mFALSE, 9, "CRC32_Init" }, // pfnCRC32_Init
191 { mFALSE, 9, "CRC32_ProcessBuffer" }, // pfnCRC32_ProcessBuffer
192 { mFALSE, 9, "CRC32_ProcessByte" }, // pfnCRC32_ProcessByte
193 { mFALSE, 9, "CRC32_Final" }, // pfnCRC32_Final
194 { mFALSE, 16, "RandomLong" }, // pfnRandomLong
195 { mFALSE, 14, "RandomFloat" }, // pfnRandomFloat // CS: when firing
196 { mFALSE, 14, "SetView" }, // pfnSetView
197 { mFALSE, 9, "Time" }, // pfnTime
198 { mFALSE, 9, "CrosshairAngle" }, // pfnCrosshairAngle
199 { mFALSE, 10, "LoadFileForMe" }, // pfnLoadFileForMe
200 { mFALSE, 10, "FreeFile" }, // pfnFreeFile
201 { mFALSE, 9, "EndSection" }, // pfnEndSection
202 { mFALSE, 9, "CompareFileTime" }, // pfnCompareFileTime
203 { mFALSE, 9, "GetGameDir" }, // pfnGetGameDir
204 { mFALSE, 9, "Cvar_RegisterVariable" }, // pfnCvar_RegisterVariable
205 { mFALSE, 9, "FadeClientVolume" }, // pfnFadeClientVolume
206 { mFALSE, 14, "SetClientMaxspeed" }, // pfnSetClientMaxspeed
207 { mFALSE, 9, "CreateFakeClient" }, // pfnCreateFakeClient
208 { mFALSE, 9, "RunPlayerMove" }, // pfnRunPlayerMove
209 { mFALSE, 9, "NumberOfEntities" }, // pfnNumberOfEntities
210 { mFALSE, 17, "GetInfoKeyBuffer" }, // pfnGetInfoKeyBuffer
211 { mFALSE, 13, "InfoKeyValue" }, // pfnInfoKeyValue
212 { mFALSE, 9, "SetKeyValue" }, // pfnSetKeyValue
213 { mFALSE, 12, "SetClientKeyValue" }, // pfnSetClientKeyValue
214 { mFALSE, 9, "IsMapValid" }, // pfnIsMapValid
215 { mFALSE, 9, "StaticDecal" }, // pfnStaticDecal
216 { mFALSE, 9, "PrecacheGeneric" }, // pfnPrecacheGeneric
217 { mFALSE, 10, "GetPlayerUserId" }, // pfnGetPlayerUserId
218 { mFALSE, 9, "BuildSoundMsg" }, // pfnBuildSoundMsg
219 { mFALSE, 9, "IsDedicatedServer" }, // pfnIsDedicatedServer
220 { mFALSE, 9, "CVarGetPointer" }, // pfnCVarGetPointer
221 { mFALSE, 9, "GetPlayerWONId" }, // pfnGetPlayerWONId
222 { mFALSE, 9, "Info_RemoveKey" }, // pfnInfo_RemoveKey
223 { mFALSE, 15, "GetPhysicsKeyValue" }, // pfnGetPhysicsKeyValue
224 { mFALSE, 14, "SetPhysicsKeyValue" }, // pfnSetPhysicsKeyValue
225 { mFALSE, 15, "GetPhysicsInfoString" }, // pfnGetPhysicsInfoString
226 { mFALSE, 13, "PrecacheEvent" }, // pfnPrecacheEvent
227 { mFALSE, 9, "PlaybackEvent" }, // pfnPlaybackEvent
228 { mFALSE, 31, "SetFatPVS" }, // pfnSetFatPVS
229 { mFALSE, 31, "SetFatPAS" }, // pfnSetFatPAS
230 { mFALSE, 50, "CheckVisibility" }, // pfnCheckVisibility
231 { mFALSE, 37, "DeltaSetField" }, // pfnDeltaSetField
232 { mFALSE, 38, "DeltaUnsetField" }, // pfnDeltaUnsetField
233 { mFALSE, 9, "DeltaAddEncoder" }, // pfnDeltaAddEncoder
234 { mFALSE, 45, "GetCurrentPlayer" }, // pfnGetCurrentPlayer
235 { mFALSE, 14, "CanSkipPlayer" }, // pfnCanSkipPlayer
236 { mFALSE, 9, "DeltaFindField" }, // pfnDeltaFindField
237 { mFALSE, 37, "DeltaSetFieldByIndex" }, // pfnDeltaSetFieldByIndex
238 { mFALSE, 38, "DeltaUnsetFieldByIndex" }, // pfnDeltaUnsetFieldByIndex
239 { mFALSE, 9, "SetGroupMask" }, // pfnSetGroupMask
240 { mFALSE, 9, "engCreateInstancedBaseline" }, // pfnCreateInstancedBaseline // d'oh, CreateInstancedBaseline in dllapi too
241 { mFALSE, 9, "Cvar_DirectSet" }, // pfnCvar_DirectSet
242 { mFALSE, 9, "ForceUnmodified" }, // pfnForceUnmodified
243 { mFALSE, 9, "GetPlayerStats" }, // pfnGetPlayerStats
244 { mFALSE, 3, "AddServerCommand" }, // pfnAddServerCommand
246 { mFALSE, 9, "Voice_GetClientListening" }, // Voice_GetClientListening
247 { mFALSE, 9, "Voice_SetClientListening" }, // Voice_SetClientListening
248 // Added for HL 1109 (no SDK update):
249 { mFALSE, 9, "GetPlayerAuthId" }, // pfnGetPlayerAuthId
250 // Added 2003/11/10 (no SDK update):
251 { mFALSE, 30, "SequenceGet" }, // pfnSequenceGet
252 { mFALSE, 30, "SequencePickSentence" }, // pfnSequencePickSentence
253 { mFALSE, 30, "GetFileSize" }, // pfnGetFileSize
254 { mFALSE, 30, "GetApproxWavePlayLen" }, // pfnGetApproxWavePlayLen
255 { mFALSE, 30, "IsCareerMatch" }, // pfnIsCareerMatch
256 { mFALSE, 30, "GetLocalizedStringLength" }, // pfnGetLocalizedStringLength
257 { mFALSE, 30, "RegisterTutorMessageShown" }, // pfnRegisterTutorMessageShown
258 { mFALSE, 30, "GetTimesTutorMessageShown" }, // pfnGetTimesTutorMessageShown
259 { mFALSE, 30, "ProcessTutorMessageDecayBuffer" }, // pfnProcessTutorMessageDecayBuffer
260 { mFALSE, 30, "ConstructTutorMessageDecayBuffer" }, // pfnConstructTutorMessageDecayBuffer
261 { mFALSE, 9, "ResetTutorMessageDecayData" }, // pfnResetTutorMessageDecayData