Specifying Goals for a character

So far, this section has depicted how to define goals for the characters. All the goals’ definitions are stored in one general XML file. Thus, in order to associate goals to the character, we need to specify in the character’s XML file what are the goals that he will have. These are some examples of the goals associated to the bully character:

<Goal name=”Bully([target])” importanceOfSuccess=”6″ importanceOfFailure=”5″ />

<Goal name=”DeceiveVictim([target])” importanceOfSuccess=”4″ importanceOfFailure=”2″ />

<Goal name=”PunishInsult([target])” importanceOfSuccess=”4″ importanceOfFailure=”3″ />

<Goal name=”SabotagePartyInvitation([inviter],[notfriend])” importanceOfSuccess=”5″

importanceOfFailure=”3″ />

In order to associate a goal to a character it’s necessary to define three attributes:

  • name – this must be the exact name of the goal as defined in the GoalLibrary
  • importanceOfSuccess – the importance of achieving the goal for the agent (ranged from 1 to 10)
  • importanceOfFailure – the importance of not being able to achieve the goal for the agent (ranged from 1 to 10)