|User experience is an important aspect of game development, and techniques in Artificial Intelligence have been proved to increase the agent performance and have the potential to affect user experience in games. In this thesis, we aim to improve the user experience of the computer game known as StateCraft by extending the computer controlled opponent with the Emotion module and the Prisoner's Dilemma module. We conducted simulations and user tests to study the effects of these modules on the agent performance and user experience. The Emotion module gives the autonomous agent in StateCraft emotions. Existing research shows that emotions affect the decision making of the agent and make it appear more human-like. Statistic analysis of the simulation data indicates that agents perform worse in general with emotions than without. Based on the study performed on the user test of StateCraft with and without the Emotion module, we are not able to make a clear conclusion on the user experience, but the results indicate that playing against emotional agents is more fun, hence increases the user experience. The Prisoner's Dilemma module gives the autonomous agent in StateCraft an understanding of the concept of the Prisoner's Dilemma. StateCraft contains several situations similar to the ones expressed in the Prisoner's Dilemma, and we wished to study whether the agent would perform differently if it understood this concept. The module was implemented with two strategies for the Prisoner's Dilemma module, Tit-For-Tat and Freidman, which both modify the behaviour of the agent according to the original specification of the strategies. Statistic analysis of the simulation data shows that Tit-For-Tat and Freidman lead to a more balanced game when all the agents are using the same strategy. The results from the user test with and without the Prisoner's Dilemma module were ambiguous, and thus indicate that further research is required to study the effects of these strategies on user experience.