Re: edict_t *pPlayer- Mean Anything to You?
Posted by bengreenwood on
Wed Nov 7th 2007 at 7:50pm
63 posts
26 snarkmarks
Registered:
Aug 14th 2007
Occupation: Student
Location: England
Hi,
I'm taking a look at the HPB bot template, trying to understand and edit a bit of basic stuff in there. You won't need to understand the bot to answer my question though, I think. It's pretty basic.
In the source code file, bot.cpp, there's a function that is declared as follows:
void BotCreate( edict_t *pPlayer, const char *arg1, const char *arg2,const char *arg3, const char *arg4).
Okay. Now within that function there are the following declarations of pointers:
edict_t *BotEnt; bot_t *pBot;
I have this idea that these pointers point to structures in another code file, that contain loads of functions and variables and stuff. Hence:
[size=13]
BotEnt->v.idealpitch = BotEnt->v.v_angle.x;
and other stuff like:
[size=13]
pBot->idle_angle = 0.0;
So what I'm thinking is that in the botcreate function declaration, edict_t *pPlayer is going to basically identify each bot in the same way that each player would be identified in a game. Is this right? Sorry if this sounds dumb, I'm just trying to figure out how this works.
[/size][/size]
Re: edict_t *pPlayer- Mean Anything to You?
Posted by tnkqwe on
Sat Nov 10th 2007 at 5:28pm
tnkqwe
member
560 posts
684 snarkmarks
Registered:
Mar 31st 2007
Occupation: High school student
Location: Bulgaria
Ask somebody else.In the snarkpit there are only mapers.Sorry.