SA-MP Forums Archive
Bot Question. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Bot Question. (/showthread.php?tid=340231)



Bot Question. - Injectio73 - 06.05.2012

Heelllooo

I want to change the ID of my Bot.
But i heard i need to make Blank Bots and kick them.
But how i do this?!


Re: Bot Question. - sleepysnowflake - 06.05.2012

Question: Why would you change its ID? Maybe there is an other way ...


AW: Bot Question. - Injectio73 - 06.05.2012

Because it has ID 0 ... but i would like to change it to ... 500^^

Other Way? ...


AW: Bot Question. - Injectio73 - 06.05.2012

Help PLease


Re: Bot Question. - Kyle - 06.05.2012

You can't it's sa-mp default.


AW: Bot Question. - Injectio73 - 06.05.2012

I can!! I Read that i can make Blank Bots. And then i can kick them (automatictly). So my Bot has ID 10 or something else


Re: Bot Question. - TzAkS. - 06.05.2012

Edited


Re: Bot Question. - Jonny5 - 06.05.2012

Quote:
Originally Posted by TzAkS.
Посмотреть сообщение
You need to create another vehicle instead of that boat and you will do it like this
Код:
AddStaticVehicle(........);//this is the first vehicle,your boat and you will change it with another vehicle
// another cars
AddStaticVehicle(...);//here you need to put your boat after last line with addstaticvehicle or createvehicle
If you don`t change the first line with AddStaticVehicle all cars will be confused with 1 ID.
WHAT
he said BOT not BOAT




Quote:
Originally Posted by Injectio73
Посмотреть сообщение
Because it has ID 0 ... but i would like to change it to ... 500^^

Other Way? ...
this does not explain WHY you would need todo this, your gonna introduce a ton of
code just to change the ID of a bot?

Not sure if you can connect a bot outside of OnGameModeInit()
but if you can you could probably kick him when a player connected and then re add him,
but if player 10 is joining and player 2 leaves before your bot connects he will get ID 2

its not easy todo and I dont see WHY one would need todo this.


Re: Bot Question. - TzAkS. - 06.05.2012

Lol,didn`t read that )

Код:
for(new i; i < 30; i++)
{
   new string[16];
   format(string,sizeof(string),"Bot%d",i);
   ConnectNPC(string,"npcidle");
}
ConnectNPC("NPC","NPC");
for(new i; i < 30; i++)
{
   Kick(i);
}



AW: Re: Bot Question. - Injectio73 - 06.05.2012

Quote:
Originally Posted by TzAkS.
Посмотреть сообщение
Lol,didn`t read that )

Код:
for(new i; i < 30; i++)
{
   new string[16];
   format(string,sizeof(string),"Bot%d",i);
   ConnectNPC(string,"npcidle");
}
ConnectNPC("NPC","NPC");
for(new i; i < 30; i++)
{
   Kick(i);
}
How does it Work? What i must doing?