论文标题
网络游戏中代码气味的探索性研究
An Exploratory Study of Code Smells in Web Games
论文作者
论文摘要
随着互联网市场的持续增长,游戏在全球范围内变得越来越受欢迎。但是,增强游戏需求的市场竞争是开发人员在性能,安全性和维护方面编写更高效的游戏。软件系统的持续发展及其增加的复杂性可能会导致不良的设计决策。研究人员分析了游戏的认知,行为和社会影响。同样,游戏玩法和游戏机制一直是增强游戏玩法的研究领域,但是在我们的知识范围内,几乎没有任何研究工作的研究工作,这些研究工作研究了游戏开发中的不良编码实践。因此,通过我们的研究,我们试图分析和确定称为代码气味的不良编码实践的存在,这些习惯可能会导致游戏中质量问题。为此,我们创建了一个用JavaScript编写的361个网络游戏的数据集。在此数据集上,我们运行JavaScript代码气味检测工具JSnose,以找到网络游戏中代码气味的出现和分布。此外,我们对9个网络游戏进行了手动研究,以发现违反现有的游戏编程模式。我们的结果表明,现有工具主要是特定语言的,在游戏的背景下还不够,因为它们无法检测到特定于游戏的反图案或不良编码实践,激励了对游戏特定的代码气味检测工具的需求。
With the continuous growth of the internet market, games are becoming more and more popular worldwide. However, increased market competition for game demands developers to write more efficient games in terms of performance, security, and maintenance. The continuous evolution of software systems and its increasing complexity may result in bad design decisions. Researchers analyzed the cognitive, behavioral and social effects of games. Also, gameplay and game mechanics have been a research area to enhance game playing, but to the extent of our knowledge, there hardly exists any research work that studies the bad coding practices in game development. Hence, through our study, we try to analyze and identify the presence of bad coding practices called code smells that may cause quality issues in games. To accomplish this, we created a dataset of 361 web games written in JavaScript. On this dataset, we run a JavaScript code smell detection tool JSNose to find the occurrence and distribution of code smell in web games. Further, we did a manual study on 9 web games to find violation of existing game programming patterns. Our results show that existing tools are mostly language-specific and are not enough in the context of games as they were not able to detect the anti-patterns or bad coding practices that are game-specific, motivating the need of game-specific code smell detection tools.