Game Development Community

AIClient versus AIPlayer

by Stephen Clark · in Torque Game Engine · 02/10/2004 (10:22 am) · 4 replies

Am I understanding this correctly that the old AIClient was a true client and therefore used the inventory manager, etc? As opposed to the newer AIPlayer which is I guess more "internal" to the C code/server?

My issue is that it doesnt appear that AIPlayers get inventory, etc...

Am I correct?

Thanks,

Stephen

#1
02/10/2004 (10:43 am)
AIPlayer is a subclass of Player, whereas AIClient is a subclass of GameConnection. So they're two sides of the same story, if that makes any sense. :)
#2
02/10/2004 (1:05 pm)
I think most of the inventory stuff hangs off ShapeBase which would be your player object, which is subclassed by AIPlayer so it should work. The situations when the client is involved is in changing to another item (where the client initiates the event) and in messaging (when the server tells the client it has changed item).

One thing worth checking is that you are setting up your ai players in the same way as human players - check all the maxInv calls are the same for instance. Sometimes the setup for an ai player goes through a different code path and things are missed out. Worth a shot...
#3
02/10/2004 (1:15 pm)
Thanks guys... I will check my datablock for my bots, but I thought I did...

So according to Ben, then AIPlayer should use all the inventory stuff, or is that solely script? I thought the inv. manager was in the engine code mostly..

regardless, thanks!

-s
#4
02/10/2004 (3:12 pm)
The inventory stuff should hang off the object the AI is controlling.