Skip to main content

Integrating Rule-Based AI Tools into Mainstream Game Development

  • Conference paper
  • First Online:
Rules and Reasoning (RuleML+RR 2018)

Abstract

Rule-based declarative formalisms enjoy several advantages when compared with imperative solutions, especially when dealing with AI-based application development: solid theoretical bases, no need for algorithm design or coding, explicit and easily modifiable knowledge bases, executable declarative specifications, fast prototyping, quick error detection, modularity. For these reasons, ways for combining declarative paradigms, such as Answer Set Programming (ASP), with traditional ones have been significantly studied in the recent years; there are however relevant contexts, in which this road is unexplored, such as development of real-time games. In such a setting, the strict requirements on reaction times, the presence of computer-human interactivity and a generally increased impedance between the two development paradigms make the task nontrivial. In this work we illustrate how to embed rule-based reasoning modules into the well-known Unity game development engine. To this end, we present an extension of EmbASP, a framework to ease the integration of declarative formalisms with generic applications. We prove the viability of our approach by developing a proof-of-concept Unity game that makes use of ASP-based AI modules.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD 54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

Notes

  1. 1.

    https://unity3d.com/unity.

  2. 2.

    Among which:

    https://assetstore.unity.com/packages/tools/ai/real-ai-112677,

    https://assetstore.unity.com/packages/tools/ai/reaction-ai-66353.

  3. 3.

    https://www.mat.unical.it/calimeri/projects/embasp.

  4. 4.

    https://github.com/vilbeyli/Pacman.

  5. 5.

    All the development material, including logic programs, source code and a fully playable version of the game are available at https://github.com/DeMaCS-UNICAL/Pac-Man-Unity-EmbASP.

References

  1. Brewka, G., Eiter, T., Truszczynski, M.: Answer set programming at a glance. Commun. ACM 54(12), 92–103 (2011). http://doi.acm.org/10.1145/2043174.2043195

  2. Buccafurri, F., Leone, N., Rullo, P.: Strong and weak constraints in disjunctive datalog. In: Dix, J., Furbach, U., Nerode, A. (eds.) LPNMR 1997. LNCS, vol. 1265, pp. 2–17. Springer, Heidelberg (1997). https://doi.org/10.1007/3-540-63255-7_2

    Chapter  Google Scholar 

  3. Calimeri, F., et al.: Asp-core-2: Input language format (2012)

    Google Scholar 

  4. Calimeri, F., Gebser, M., Maratea, M., Ricca, F.: Design and results of the fifth answer set programming competition. Artif. Intell. 231, 151–181 (2016). https://doi.org/10.1016/j.artint.2015.09.008

  5. Febbraro, O., Leone, N., Grasso, G., Ricca, F.: JASP: A framework for integrating answer set programming with java. In: Brewka, G., Eiter, T., McIlraith, S.A. (eds.) Principles of Knowledge Representation and Reasoning: Proceedings of the Thirteenth International Conference, KR 2012, Rome, Italy, June 10–14, 2012. AAAI Press (2012). http://www.aaai.org/ocs/index.php/KR/KR12/paper/view/4520

  6. Fuscà, D., Germano, S., Zangari, J., Anastasio, M., Calimeri, F., Perri, S.: A framework for easing the development of applications embedding answer set programming. In: Proceedings of the 18th International Symposium on Principles and Practice of Declarative Programming, Edinburgh, United Kingdom, pp. 38–49 (2016)

    Google Scholar 

  7. Gebser, M., Kaminski, R., Kaufmann, B., Schaub, T.: Clingo = ASP + control: Preliminary report. CoRR abs/1405.3694 (2014). http://arxiv.org/abs/1405.3694

  8. Gelfond, M., Lifschitz, V.: Classical negation in logic programs and disjunctive databases. New Gener. Comput. 9(3/4), 365–386 (1991). https://doi.org/10.1007/BF03037169

  9. Ricca, F.: The DLV java wrapper. In: de Vos, M., Provetti, A. (eds.) Proceedings ASP03 - Answer Set Programming: Advances in Theory and Implementation, pp. 305–316. Messina, Italy, September 2003. http://CEUR-WS.org/Vol-78/

  10. Schüller, P., Weinzierl, A.: Answer set application programming: a case study on tetris. In: Vos, M.D., Eiter, T., Lierler, Y., Toni, F. (eds.) Proceedings of the Technical Communications of the 31st International Conference on Logic Programming (ICLP 2015). CEUR Workshop Proceedings, Cork, Ireland, vol. 1433. CEUR-WS.org (2015), 31 August–4 September 2015. http://ceur-ws.org/Vol-1433/tc_17.pdf

  11. Thimm, M.: Tweety: a comprehensive collection of java libraries for logical aspects of artificial intelligence and knowledge representation. In: Baral, C., Giacomo, G.D., Eiter, T. (eds.) Principles of Knowledge Representation and Reasoning: Proceedings of the Fourteenth International Conference, KR 2014, Vienna, Austria. AAAI Press, 20–24 July 2014. http://www.aaai.org/ocs/index.php/KR/KR14/paper/view/7811

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Francesco Pacenza .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2018 Springer Nature Switzerland AG

About this paper

Check for updates. Verify currency and authenticity via CrossMark

Cite this paper

Calimeri, F., Germano, S., Ianni, G., Pacenza, F., Perri, S., Zangari, J. (2018). Integrating Rule-Based AI Tools into Mainstream Game Development. In: Benzmüller, C., Ricca, F., Parent, X., Roman, D. (eds) Rules and Reasoning. RuleML+RR 2018. Lecture Notes in Computer Science(), vol 11092. Springer, Cham. https://doi.org/10.1007/978-3-319-99906-7_23

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-99906-7_23

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-99905-0

  • Online ISBN: 978-3-319-99906-7

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics