Abstract
Many video games rely on a Domain Specific Language (DSL) to implement particular features such as artificial intelligence or time and synchronization primitives. Building a compiler for a DSL is a time-consuming task, and adding new features to a DSL is hard due to the low flexibility of the implementation choice. In this paper, we introduce an alternative to hand-made implementations of compilers for DSLs for game development: the Metacasanova metacompiler. We show the advantages of this metacomplier in terms of simplicity of designing and coding requirements, and in terms of performance of the resulting code, whose efficiency is comparable with hand-made implementations in commercial general purpose languages.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
References
Abbadi, M., Giacomo, F., Cortesi, A., Spronck, P., Costantini, G., Maggiore, G.: Casanova: a simple, high-performance language for game development. In: Göbel, S., Ma, M., Baalsrud Hauge, J., Oliveira, M.F., Wiemeyer, J., Wendel, V. (eds.) JCSG 2015. LNCS, vol. 9090, pp. 123–134. Springer, Heidelberg (2015). doi:10.1007/978-3-319-19126-3_11
Bioware. Nwscript api reference (2002). http://www.nwnlexicon.com/
Blizzard Entertainment. Jass api reference (1999). http://jass.sourceforge.net/doc/
Book, E., Shorre, D.V., Sherman, S.J.: The cwic/36o system, a compiler for writing and implementing compilers. SIGPLAN Not. 5(6), 11–29 (1970)
Czarnecki, K., Eisenecker, U.W.: Generative Programming: Methods, Tools, and Applications. ACM Press/Addison-Wesley Publishing Co., New York (2000)
Games, F.: Civlization iv scripting api reference, October 2008. http://wiki.massgate.net/Our_Python_files_and_Event_Structure
Di Giacomo, F.: Casanova 2.5 source code (2016). https://github.com/vs-team/metacompiler/tree/master/Sources/Content/Content/CNV3
Kelly, J.P., Botea, A., Koenig, S.: Offline planning with hierarchical task networks in video games. In: AIIDE (2008)
Maggiore, G., Bugliesi, M., Orsini, R.: Monadic scripting in f# for computer games. In: TTSS 115th International Workshop on Harnessing Theories for Tool Support in Software, p. 35 (2011)
Maggiore, G., Spanò, A., Orsini, R., Bugliesi, M., Abbadi, M., Steffinlongo, E.: A formal specification for casanova, a language for computer games. In: Proceedings of the 4th ACM SIGCHI Symposium on Engineering Interactive Computing Systems, EICS 2012, pp. 287–292. ACM, New York (2012)
Massive Entertainment. World in conflict script reference, September 2007. http://civ4bug.sourceforge.net/PythonAPI/
Microsoft Corporation. Msdn. https://msdn.microsoft.com/en-us/library/windows/desktop/ms686774(v=vs.85).aspx
Sheard, T., Benaissa, Z., Pasalic, E.: Dsl implementation using staging and monads. In: Second Conference on Domain-Specific Languages DSL 1999, pp. 81–94. ACM (1999)
Sweeney, T., Hendriks, M.: Unrealscript Language Reference. Epic MegaGames Inc., Cary (1998)
Tulip, J., Bekkema, J., Nesbitt, K.: Multi-threaded game engine design. In: Proceedings of the 3rd Australasian conference on Interactive Entertainment, pp. 9–14. Murdoch University (2006)
van Deursen, A., Klint, P., Visser, J.: Domain-specific languages: an annotated bibliography. SIGPLAN Not. 35(6), 26–36 (2000)
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2017 ICST Institute for Computer Sciences, Social Informatics and Telecommunications Engineering
About this paper
Cite this paper
Di Giacomo, F., Abbadi, M., Cortesi, A., Spronck, P., Maggiore, G. (2017). Building Game Scripting DSL’s with the Metacasanova Metacompiler. In: Poppe, R., Meyer, JJ., Veltkamp, R., Dastani, M. (eds) Intelligent Technologies for Interactive Entertainment. INTETAIN 2016 2016. Lecture Notes of the Institute for Computer Sciences, Social Informatics and Telecommunications Engineering, vol 178. Springer, Cham. https://doi.org/10.1007/978-3-319-49616-0_22
Download citation
DOI: https://doi.org/10.1007/978-3-319-49616-0_22
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-49615-3
Online ISBN: 978-3-319-49616-0
eBook Packages: Computer ScienceComputer Science (R0)