diff --git a/extensions/sdktools/vnatives.cpp b/extensions/sdktools/vnatives.cpp index aee2dd02..321f43d2 100644 --- a/extensions/sdktools/vnatives.cpp +++ b/extensions/sdktools/vnatives.cpp @@ -367,7 +367,7 @@ static cell_t SetClientViewEntity(IPluginContext *pContext, const cell_t *params return pContext->ThrowNativeError("Client %d is not in game", params[1]); } - edict_t *pEdict = PEntityOfEntIndex(gamehelpers->ReferenceToIndex(params[1])); + edict_t *pEdict = PEntityOfEntIndex(gamehelpers->ReferenceToIndex(params[2])); if (!pEdict || pEdict->IsFree()) { return pContext->ThrowNativeError("Entity %d is not valid", params[2]);