First, is it possible to make the AI attack a region instead of an object? And second, can I do something like this:
Code: Select all
AIlobby = AddAIGoal(Team, "type", 100)
-- After a certain amount of time
AIlobby = AddAIGoal(Team, "type", 10)Moderator: Moderators

Code: Select all
AIlobby = AddAIGoal(Team, "type", 100)
-- After a certain amount of time
AIlobby = AddAIGoal(Team, "type", 10)

So in theory, this would make the weight lower?Maveritchell wrote:Pretty sure all your second line there is going to do is give that AI goal a weight of 110. Since weights are all relative, that won't mean anything in isolation, but if you've got two different types set up, you'll obviously be adjusting the ratio there. (In short, no, you can't change absolute weight without clearing goals first.)
AI have two "goto"-type goals, "defend" and "destroy." Destroy is more precise, so if you want your AI to really go to a place, use that one. If you're okay with your AI hanging out in a very general area, you can use defend. Defend is very loose, though.
Code: Select all
AIlobby = AddAIGoal(Team, "type", -90)

Not possible.change the objective weight without deleting the goal
No, it will add a second goal with a weight of 10. Since both goals are the same, it's similar to one goal with a weight of 110, but it's taking up an extra goal slot. Remember, only a limited number of AI goals are allowed.Pretty sure all your second line there is going to do is give that AI goal a weight of 110
No, I'm fairly certain negative weights will crash the game. At the very least it won't do what you want it to do.So in theory, this would make the weight lower?

I believe you're off-the-mark here. I've cleared and swapped AI goals midstream based on player action, and the AI has responded to the new goal accordingly (without killing the AI).[RDH]Zerted wrote:If you do, make sure to kill all the bots after resetting the goals. Only when an AI dies or completes its goal does it get a new one.