Tools – not toys

  • Published on
    30-Dec-2015

  • View
    29

  • Download
    6

Embed Size (px)

DESCRIPTION

Tools not toys. Vesa Lappalainen , Lecturer PhD Antti-Jussi Lakanen , University teacher MSc Department of Mathematical Information Technology, University of Jyvskyl trac.cc.jyu.fi/projects/npo https://trac.cc.jyu.fi/projects/comtest. Vesa Lappalainen. PhD 1985 in Mathematics - PowerPoint PPT Presentation

Transcript

PowerPoint Presentation

Tools not toysVesa Lappalainen, Lecturer PhD Antti-Jussi Lakanen, University teacher MScDepartment of Mathematical Information Technology, University of Jyvskyltrac.cc.jyu.fi/projects/npohttps://trac.cc.jyu.fi/projects/comtest

Vesa LappalainenPhD 1985 in MathematicsTeaching programming since 1982Research activities:InSitu: Interaction possibilities on a mass lectureComTest: Making test-driven development (TDD) simpleStudents perceptions of programmingEarly recruitment in ICTMy gaming backgroundTwo teenager boys2

Vesa is the one who at the first got the ideas of this motivation course and I picked the original grew and set the goals.2Antti-Jussi LakanenMSc 2010 in Mathematical Information TechnologyTeaching programming, recruitment, tutoring freshmenResearch activitiesCS1 and games, effect on study successK-8/K-12 programmingMy gaming backgroundCommodore 64, Amiga 500, ...More of fun, less of useful activities3

Antti-Jussis responsibility was to plan and keep all the courses with boys who created the Jypeli library.3Tools - not toysMany times things are left too complicated in real toolsNot even beginners but also more experienced programmerThis forces to use toys instead of real toolsWhy not go a bit further with real tools?We show two examples to simplify things:Jypeli event driven game framework over XNAComTest make unit testing easier

Real tools are meny times too complicated at least to beginners4Our presentation in a nutshell: Part 1We are worried about the decline in IT, science and math studentsWe developed a week-long game programming course for youngsters to motivate studying IT, science and mathJypeli programming library was developed as a tool to reduce the cognitive load in beginning game programmingWe have had 7 courses, 150 students, aged 11-175

We share the same worries about student decline than all others. So we developed a week long course to motivate junior high school students to IT, science and math. For the course we created a game library called Jypeli, we shall show a small example of that.5Our presentation in a nutshell: Part 2Ohjelmointi 1 (CS 1) with a game themeStarted in 2010Strong learning outcomesTDD (ComTest for C#)As of autumn 2011 game theme will be a common denominator in the majority of the courses of the IT faculty

6Part 1: Game programming course for teenagers (12-16 years) using Jypeli

Each of these has its own important role in the processIf we change some part, we affect the ensemble

8The course concept introduced is a combination of department staff (teachers), tools (Jypeli etc.), content and motivated participantsDisclaimerLinkshttps://trac.cc.jyu.fi/projects/npo https://www.jyu.fi/it/laitokset/mit/opiskelu/nuortenkurssi Facebook group: http://www.facebook.com/#!/group.php?gid=1143454352607059

AcknowledgementsUniversity of Jyvskyl / Department of Mathematical Information TechnologyFunding courses in 2009, Jypeli developmentTechnology Industries of Finland Centennial FoundationCourses in 20102011Agora CenterResearch in game developmentMicrosoftSoftware, Xbox controllersPhysics2D.NET physics library

10

Lots of thanks to all our supporters.10IntroductionStudent decline in ICT and science fields (economics still get students)Amount of students passing the courses has gone down 50 % since 2004How to get youngsters to choose science courses in high school? And hopefully to continue their studies later in university11

Our main concern was that we nowadays miss a lot of students in our subjects also in Finland. So we wanted to create something to show junior high school students, that there is idea to choose math and science in high school.11Why this course?What are the young interested of?Something to excite!How to combine fun with real thingsWe wanted to show that concepts of high school math and science apply also in gamesWhy not to target senior high?We wanted to influence what subjects they pick in senior highWith senior high students we would be late(ca 50 % doesnt even go to senior high)

12Senior high is not our target, 12Finnish educational system13Elementary school, 6 yrs (Alakoulu in Finnish), starts at the age of 7Junior High School, 3 yrs (Ylkoulu in Finnish)Senior High School (lukio), 3 yrsVocational School (ammattikoulu), 3 yrsUniversity (bachelor), 3 yrsPolytechnics (bachelor), 3.5 4 yrsUniversity (master), 2 yrsCompulsoryeducation50.2 %41.2 %(8.6 %)Pre-school, 1 year (Esikoulu in Finnish), starts at the age of 6 because in Finland the students can choose between two different tracks after junior high. The right side track does not lead to university in most cases. So we should influence before student make the choice of the track and also before they choose subjects in senior high.13Motivation and learning outcomesMotivation to physics conceptsQuantities: time, distance, speed, acceleration and forceCausal relationship: dependencies between objectsGravity, friction, motion, balanceMass and its effectsParticle kinematics14

So we wanted to motivate students to physics concepts 14Motivation and learning outcomesMotivation to math conceptsProblem solvingFunction, interpretation and drawingCoordinatesGeometry: straight line, scaling, shapesVectorsEquations and solving themProbability and random numbersBoolean value, logicAngle, degrees and radians15

and math concepts.

15How to program gamesTwo mainstream optionsVisual programmingAlice, Scratch, Greenfoot, Lego robots (compare to industrial process programming, e.g. National Instruments, LabView, etc.)Microsoft KoduTextual programmingJava ACM Task ForceXGC1 (UWB)16

- For games we have many different ways to go as we already have seen here. But roughly we can divide those in two mainstreams. Visual programming like Alice, Scratch, Greenfoot, Lego robots, Kodu etc.- The other mainstream is traditional textual programming using some library.

16Alice17

Kodu Game Lab18

Jypeli library -- Why and objectivesReal programming by mainstream toolsFirst game should not be many lines of codeRealistic physics built-inEvent-driven for controls and collisionsLess structures, as few as zero loops and ifsEndless possibilities for advanced programming Possibility to transfer games to game consoles and mobile phones19

What we wanted from our tool: real programming by mainstream tools to motivate students. About some more goals we shall discuss during the example. Then we preferred also possibility to transfer the games also to consoles and mobiles.

19Choosing the tool Motivation to building a new libraryLack of Finnish materialXbox currently only game console with the possibility to transfer own games easily C# as the languageLack of physics engines in available libraries out-of-the-boxLimited time available It also takes time to study a library someone else has madeFaculty interests in bringing knowledge about building game engines, physics engines etc.

20

We had only two months from the idea of to start of the first course. So in two months we should make the choice and prepare the materials. Because lack of Finnish material, we should anyway write a lot ourselves. Xbox is the only console where it is possible to do code in reasonable time, so the language should be C# and something top of XNA.Because also third party libraries would take time to get familiar with and we did not mind, if we get a bit of knowledge of how to make a game engines, we chose to make our own.20Basics of Jypeli library C# library built on top of Microsoft XNA 4.0Programmer defines the actions to execute for game start, objects colliding, player using controllers etc.Library takes care of physics and collisionsFirst games are very easy to makeStill its real programmingYou can see the programas a whole

21

Example game:Galaxy Trip22- Now we will implement an example game called the Galaxy Trip. The same game is running on the phone.22using System;using Jypeli;using Jypeli.Effects;

public class Game : PhysicsGame{ static String[] lines = { " ", " ", " ", " X X ", "X ", " * ", " X X ", " ", " ", " ", " ", "* X X ", "X ", " * ", " X X ", " ", " ", " ", " * ", " X X ", "X ", " ", " X X ", " ", };

static int tileWidth = 800 / lines[0].Length; static int tileHeight = 480 / lines.Length; static Image playerImage = LoadImage("ship"); static Image galaxyImage = LoadImage("galaxy"); static Image sombreroImage = LoadImage("sombrero"); static Image explosionImage = LoadImage("bum"); ExplosionSystem explosionSystem; PhysicsObject player;

protected override void Begin() { Level.Background.Image = LoadImage("space"); Gravity = new Vector(0, -1000); NewGame(null); }

void NewGame(Touch touch) { ClearGameObjects(); ClearControls();

player = new PhysicsObject(50, 50, Shape.Circle); player.Image = playerImage; Add(player);

explosionSystem = new ExplosionSystem(explosionImage, 50); Add(explosionSystem);

Keyboard.Listen(Key.Up, ButtonState.Pressed, MovePlayer, "Move up", player, new Vector(0, 500)); Keyboard.Listen(Key.Down, ButtonState.Pressed, MovePlayer, null, player, new Vector(0, -500)); Keyboard.Listen(Key.Left, ButtonState.Pressed, MovePlayer, null, player, new Vector(-500, 0)); Keyboard.Listen(Key.Right, ButtonState.Pressed, MovePlayer, null, player, new Vector(500, 0)); TouchPanel.Listen(ButtonState.Pressed, NewGame, null); Accelerometer.Calibration = AccelerometerCalibration.ZeroAngle; Accelerometer.ListenAnalog(AccelerometerSensitivity.Realtime, ChangeGravity, null);

TileMap tiles = TileMap.FromStringArray(lines); tiles['X'] = CreateGalaxy; tiles['*'] = CreateSombrero; tiles.Insert(tileWidth, tileHeight); Level.CreateBorders(); Camera.ZoomToLevel(); }

public void MovePlayer(PhysicsObject player, Vector force) { player.Hit(force); }

23 PhysicsObject CreateGalaxy() { PhysicsObject galaxy = PhysicsObject.CreateStaticObject(tileWidth, tileHeight); galaxy.Color = Color.LightBlue; AddCollisionHandler(galaxy, CollidedWithGalaxy); galaxy.Image = galaxyImage; return galaxy; }

PhysicsObject CreateSombrero() { PhysicsObject sombrero = PhysicsObject.CreateStaticObject(tileWidth, tileHeight); sombrero.Color = Color.Yellow; sombrero.Image = sombreroImage; AddCollisionHandler(sombrero, CollidedWithSombrero); return sombrero; }

void CollidedWithGalaxy(PhysicsObject galaxy, PhysicsObject target) { PlaySound("blop"); }

void CollidedWithSombrero(PhysicsObject sombrero, PhysicsObject target) { PlaySound("exp"); explosionSystem.AddEffect(target.X, target.Y, 50); sombrero.Destroy(); }

void ChangeGravity(AnalogState s) { Gravity = s.StateVector * 2000; }}

Course instances in 2009201020092010TotalCourses257Instructors1 plus 3-41 plus 4Students45105150Girls / boys7 / 386 / 9913 / 137Age mean median youngest / oldest13.81312 / 1614.21411 / 17Drop outs3 (7 %)6 (6 %)9 (6 %)24We had 7 courses with 150 students and a nice low drop out rate.24Student backgroundFor the most part students (78 %) had none or little earlier programming experience Experienced and self-confident as computer users (58 %)Play a lot59 % play every day37 % on a few days a week3 % less frequentlyHalf of the students (49 %) had no idea what programming is25

I have earlier programming experience (2010)26Basically most of the students did not have earlier programming experience.26I consider myself an experienced computer user (2009-2010)27however they considered themselves as highly skilled computer users.27I play computer games (2009-2010)28And they play a lot.28More student demographicsThey have tried some languages, e.g. Java (20), Basic (17), C++ (17) (numbers overlap)Most students are interested in career in software engineering (57 %)Conclusion: Students were interested and motivated, but did not know what to expect out of the course29

As the students came voluntarily, they were already somewhat interested about subject, but they did not know what to expect out of the course.29MonTueWedThuFri9:00-9:50Starting infoFunctionsLoops, random numbers, gravityClasses and methods of Jypeli libraryHow to continue 10:00-10:50Get to know with toolsCarrying on with the Pong gameDesigning and implementing own gameImplementing own gameFinalizing own game11:00-11:45Making the first game (Pong-tutorial)Finalizing the Pong gameImplementing own game12:15-13:30What are algorithmsHandling collisionsHow to make a level out of a tilemap (grid)Showcase13:45-15:00Carrying on with the Pong gameDesigning own gameImplementing own game

Showcase and best game voting30The length of the course was 5 days, and each day we had 5 hours of working time. Each morning there was a lecture, and on the first three days one lecture after the lunch break, those brown areas indicate the lectures. Then the blue areas indicate the time spent on the computer lab. On the very first day the students started makingtheir first pong game following a tutorial. Finalizing their pong game continued on tuesday.The rest of the time was allocated to design and implementation of their own games.Naturally the climax of the course was when the students presented what they had done. Students had a chance to vote for the best game which was then rewarded with a small prize.30

31

32

33

34

35

36

37Student outputVideo compilation of the ready games38Overall satisfactionOverall satisfaction: 4.71 (2009), 4.56 (2010) Fulfilled the expectations: 4.1 (2009), 3.9 (2010)85 % would recommend the course to his/her friends (2010)(Scale: 1 Fully disagree -- 5 Fully agree) 39

Overall the students liked the course very much and would recommend it to their friends.39Hardest things on the course42 % of the responses related to new language and new syntaxlearning a new programming language"writing the code"syntax of the language"finding errorswriting errorless code40

- It was not actually a surprise that learning programming language and syntax was difficult in students opinion.40Is it hard to do programming?Ma...