Raised This Month: $51 Target: $400
 12% 

Solved CreateFakeClient spawns outside of map


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
pride95
Senior Member
Join Date: Aug 2015
Old 12-28-2017 , 15:20   CreateFakeClient spawns outside of map
Reply With Quote #1

HTML Code:
iTerrorist = CreateFakeClient("Bot");
if(iTerrorist)
{
	DispatchKeyValue(iTerrorist, "classname", "fakeclient");
	DispatchSpawn(iTerrorist);
	ActivateEntity(iTerrorist);
	CS_SwitchTeam(iTerrorist, CS_TEAM_T);
	CS_UpdateClientModel(iTerrorist);
	CS_RespawnPlayer(iTerrorist);
i dont know why he's spawned outside of the map, or stuck in the air on some maps. even with teleportentity its the same thing. i dont need a bot (bot_add_t), cause the bot should do nothing.

Last edited by pride95; 01-10-2018 at 12:02.
pride95 is offline
Eylon.A
Junior Member
Join Date: Sep 2016
Location: A
Old 01-01-2018 , 11:42   Re: CreateFakeClient spawns outside of map
Reply With Quote #2

muiterp ,etna neipas essidnepsuS .arreviv rutetcesnoc xe te sullet mutcid euqsiuQ
__________________
A

Last edited by Eylon.A; 04-15-2021 at 06:23.
Eylon.A is offline
shavit
AlliedModders Donor
Join Date: Dec 2011
Location: Israel
Old 01-01-2018 , 14:07   Re: CreateFakeClient spawns outside of map
Reply With Quote #3

AFAIK you have to use the game's bots rather than a fake client
__________________
retired
shavit is offline
OSWO
Senior Member
Join Date: Jul 2015
Location: United Kingdom, London
Old 01-03-2018 , 17:01   Re: CreateFakeClient spawns outside of map
Reply With Quote #4

Yes, you have to properly dispatch a bot through ``bot_add``, grab their index through a listener on ``player_connect``, and go from there. Pretty sure I had troubles with the forward ``OnClientConnect ... OnClientConnected``
__________________
SourceTimer | WeaponSkins++ | BasePlugins++ https://github.com/OSCAR-WOS

Last edited by OSWO; 01-03-2018 at 17:01.
OSWO is offline
shavit
AlliedModders Donor
Join Date: Dec 2011
Location: Israel
Old 01-03-2018 , 20:26   Re: CreateFakeClient spawns outside of map
Reply With Quote #5

Quote:
Originally Posted by OSWO View Post
Yes, you have to properly dispatch a bot through ``bot_add``, grab their index through a listener on ``player_connect``, and go from there. Pretty sure I had troubles with the forward ``OnClientConnect ... OnClientConnected``
That's because bots are in-game, but never get *connected*. You can catch them via OnClientPutInServer too.
__________________
retired
shavit is offline
pride95
Senior Member
Join Date: Aug 2015
Old 01-10-2018 , 12:02   Re: CreateFakeClient spawns outside of map
Reply With Quote #6

i solved with requestframe and teleportentity to the spawn (info_player_terrorist)
pride95 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 10:35.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode