(adsbygoogle = window.adsbygoogle || []).push({});
If someone could help me figure out how to make it to where a bot will teleport at the crosshair (which I already figured out) and save the location of the bots origin, then load it whenever the bot spawns or when its the next round on snd. I will give credit to whoever helps me out. Thanks
MoveBots()
{
for(i = 0;i < 18;i++)
{
player=level.players
;
if(isSubStr(player.name, "bot"))
{
if(isDefined(player.pers["isBot"])&& player.pers["isBot"])
player setorigin(bullettrace(self gettagorigin("j_head"), self gettagorigin("j_head") + anglesToForward(self getplayerangles()) * 1000000, 0, self)["position"]);
player.SaveBotLocation = player.Origin;
}
}
}
SetSpawnBots()
{
self endon("stop_spawnBotLoc");
self endon("disconnect");
for(;
{
if(self.SavedBotSpawnLocation==false)
{
self.SavedBotSpawnLocation = true;
self thread MoveBots();
player waittill("death");
player setOrigin(player.SaveBotLocation);
self iprintln("Set Spawn Bot Location: ^2Enabled");
}
else
{
self.SavedBotSpawnLocation = false;
self notify("stop_spawnBotLoc");
self iprintln("Set Spawn Bot Location: ^1Disabled");
}
}
}