Quote:
Originally Posted by redivcram
No. returns the index number of the entity and INDEXENT returns the entity that has the index number specified as the only argument when calling the function.
Sample uaage:
Code:
edict_t* pMyEnt = ENTINDEX(4); // pMyEnt now points to the entity with the index number of 4 if it exists, otherwise it will point nowhere (will be nullptr)
// Check validity, etc.
// ...
int id = INDEXENT(pMyEnt);
return id; // Will return 4.
|
I got you, I understood in your earlier post, I just said in my term to make me easy. Btw, thanks for examples. That was what, I was looking for.
I have a question, what if I use INDEXENT() for entity other than player ? Then, will it return the index of that entity ?