.:: Bots United ::.

.:: Bots United ::. (http://forums.bots-united.com/index.php)
-   Half-Life and HL1 Mods (http://forums.bots-united.com/forumdisplay.php?f=22)
-   -   Let's kill the bots (http://forums.bots-united.com/showthread.php?t=5581)

The_Hard_Mission_Guy 04-08-2006 21:54

Let's kill the bots
 
Yo Yo!
I was wondering what function/s should be called to make the bot drop dead?!

P.S just killing them without kickin' them out of the server.

The Storm 04-08-2006 22:42

Re: Let's kill the bots
 
pfnClientKill();

The_Hard_Mission_Guy 05-08-2006 00:55

Re: Let's kill the bots
 
Negative!
Neither ClientKill() nor ClientDisconnect seem to work!
any other ideas?

P.S Do you think calling pfnPlayermove after ClientKill might solve the problem?

The Storm 05-08-2006 10:11

Re: Let's kill the bots
 
If you know how to use ClientKill() there will be no problem. You must point the correct edict. Show me the code with that you try to kill the bots.

The_Hard_Mission_Guy 05-08-2006 15:11

Re: Let's kill the bots
 
I'm afraid that I can't show you the code , but I'm sure that the code points to the right edict_t ..

btw when using ClientDisconnect() the server prints on the console that the bot has left the game , nevertheless the bot stays in the server ......also worth noting that other functions like ClientPutinServer work perfectly !

Damn , why won't this bot DIE :cursing:

The Storm 05-08-2006 18:37

Re: Let's kill the bots
 
To kick bot from server you must use "kick" server command. And why you can't show me the code - is it top secret ? If you can't do it I can't help you.

The_Hard_Mission_Guy 05-08-2006 18:50

Re: Let's kill the bots
 
The "kick" command doesn't work also!.....as far as I tried from the console..
I think that it's my right to decide whether to show the code or not.....(it's not Top Secret....but half Top Secret , LOL)

anyways I'm just trying to ask why this is happening , since "YOU guys" are "expierenced" bot coders ..

OnTopic - When should ClientKill() be called ? in StartFrame() ?
What do I else need - other than the edict_t pointer- to call the funtion successfully?
Should other fucntions be called after it? or before it?
Any other possible reasons that would cause ClientKill() or ClientDisconnect() to fail?

The Storm 05-08-2006 18:59

Re: Let's kill the bots
 
SERVER_COMMAND("kick %s", STRING(pev->netname)) - this will fully kick the bot.
You need to call ClientKill() only at the time that you want to kill the bot, when and where you will call it you must deside. So far all is right but if I can't see the loop code that you make to get the needed edicts so I can't really tell you where you wrong. Nobody will stole you code if you put it here so don't worry, I don't understand what secret can be a loop for player edicts huh ???

The_Hard_Mission_Guy 05-08-2006 19:04

Re: Let's kill the bots
 
I didn't post any codes because I personally don't believe that the problem lies in the edict_t loop , but if you insist I easily can !
just Hold ON....be right back!

The Storm 05-08-2006 19:06

Re: Let's kill the bots
 
The problem is on place that maybe less expect. So little check on the code after you post it wont be a problem. ;)


All times are GMT +2. The time now is 12:49.

Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.