Closed TheOreoSlayer closed 1 year ago
I was wondering for any feedback if you think this code would work for assigning a case difficulty to a bot depending on the bots name. Any feed back would be appreciated.
main() { level thread botDifficultySetter(); }
botDifficultySetter() { while(1) { level waittill("connected", player); if(player.bot) { if(player.bot.name == "LessMellow") { player.bot.difficulty = 4; } else if(player.bot.name == "VeganLettuce") { player.bot.difficulty = 5; } else if(player.bot.name == "Mattererla") { player.bot.difficulty = 6; } else if(player.bot.name == "SuckKallis") { player.bot.difficulty = 7; } else { player.bot.difficulty = randomIntRange(4, 7); } } } }
// update bot's skill cvar self setClientDvar( "bot_skill", self.pers["bots"]["skill"]["base"] ); } wait 0.1; }
}
I was wondering for any feedback if you think this code would work for assigning a case difficulty to a bot depending on the bots name. Any feed back would be appreciated.
main() { level thread botDifficultySetter(); }
botDifficultySetter() { while(1) { level waittill("connected", player); if(player.bot) { if(player.bot.name == "LessMellow") { player.bot.difficulty = 4; } else if(player.bot.name == "VeganLettuce") { player.bot.difficulty = 5; } else if(player.bot.name == "Mattererla") { player.bot.difficulty = 6; } else if(player.bot.name == "SuckKallis") { player.bot.difficulty = 7; } else { player.bot.difficulty = randomIntRange(4, 7); } } } }
}