SA-MP Forums Archive
Need help plz!Server won't let me add more than a BOT?[problem solved] - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Server (https://sampforum.blast.hk/forumdisplay.php?fid=6)
+--- Forum: Server Support (https://sampforum.blast.hk/forumdisplay.php?fid=19)
+--- Thread: Need help plz!Server won't let me add more than a BOT?[problem solved] (/showthread.php?tid=126451)



Need help plz!Server won't let me add more than a BOT?[problem solved] - Epic Shower - 08.02.2010

Ok so i did everything the "How to add a BOT thread" told me to.
Everything went fine.
But everytime i add more than a bot it won't load in the server.
I've tryed it in a empty script with 2 bots also it gave no compile error and when running the server it still only loads 1 BOT.
So i guess the problem isn't in the script...
And i don't think it's either in the code here's the code i have in the script:

new MyFirstNPCVehicle;
new MysecondNPCVehicle;

public OnGameModeInit()
{

ConnectNPC("CRAZY_DRIVER","crazydriver");
ConnectNPC("NPC_BOT","Carbot");
MyFirstNPCVehicle = CreateVehicle(427, 0.0, 0.0, 5.0, 0.0, 9, 5, 5000);
MysecondNPCVehicle = CreateVehicle(468, 0.0, 0.0, 5.0, 0.0, 1, 3, 5000);
return 1;

}
public OnPlayerSpawn(playerid)
{
if(IsPlayerNPC(playerid))
{
new npcname[MAX_PLAYER_NAME];
GetPlayerName(playerid, npcname, sizeof(npcname));
if(!strcmp(npcname, "NPC_BOT", true))
{
PutPlayerInVehicle(playerid, MyFirstNPCVehicle, 0);
return 1;
}
if(!strcmp(npcname, "CRAZY_DRIVER", true))
{
PutPlayerInVehicle(playerid, MysecondNPCVehicle, 0);
return 1;
}
return 1;
}

And when running server:
(only loads 1 of them )



Re: Need help plz!Server won't let me add more than a BOT? - TTJJ - 08.02.2010

Hi there,

Have you checked your server config? There is a variable in there defining the maximum number of bots. See what it is.

TJ


Re: Need help plz!Server won't let me add more than a BOT? - Epic Shower - 08.02.2010

Wow!
Thanks alot
I forgot to check that