Abstract. Serious video games have been proposed as a means to engage students with the Science, Technology, Engineering, Mathematics (STEM) curric-ulum, but there is limited research on the required game elements and teaching practices. In particular, there is limited evidence on the effects of the storytelling element and of student involvement in making games on the learning performance and on the attitudes of the students. For this purpose, we designed a between groups experiment with eighty students (12 to 13 years old). They formed three equivalent groups of twenty students each who practiced with a serious game in three different ways. The first group played the storytelling game, the second played the same game but with no story, and the third was engaged with modifying the game code. Finally, the last (control) group practiced traditionally by solving exercises on paper. We found that girls with low grades benefited the most by playing the game and by engaging with the code and that the game making group wishes to repeat the exercise. Further research should perform similar studies with a focus on involving students in serious game modification, over longer periods of time and for additional curriculum topics.