11
Games in Java Department of Computer Science Professor Yi Chen HappyKim Jennifer Villacis Elisabeth Domond Jose Munoz-Lopez Pong Jesus Gonzalez James Laskey Frustration Erwin Aguilar Reuben Orihuela

PAYS 2014 Research Powerpoint

Embed Size (px)

Citation preview

Page 1: PAYS 2014 Research Powerpoint

Games in JavaDepartment of Computer Science

Professor Yi Chen

HappyKimJennifer Villacis

Elisabeth DomondJose Munoz-Lopez

PongJesus GonzalezJames Laskey

FrustrationErwin Aguilar

Reuben Orihuela

Page 2: PAYS 2014 Research Powerpoint

Basic Introduction to Java• Class= a functioning part of a project• Method= a command• Variable = name for an object• Line (X1,Y1,X2,Y2, canvas);• FramedRect (x, y, width, height, canvas)• FilledRect• FramedOval/FilledOval• Text

• Set Size• Set Font• Set Color

• Oval1.setColor(Color.ORANGE)• Public void begin (): Starts effects once

canvas is opened. Other options include:• onMouseClick• onMousePress/onMouseRelease• onMouseEnter/onMouseExit• onMouseDrag

Page 3: PAYS 2014 Research Powerpoint

Sample Exercises

Page 4: PAYS 2014 Research Powerpoint

Pong

Page 5: PAYS 2014 Research Powerpoint

PongWhy?Pong is one of the first classic games to achieve mainstream popularity.The coding of Pong is a fun and enjoyable experience!Design:Pong: The skeleton of the game, it displays the frame and controls the paddles.MovingPongBall: Controls the movement of the pong ball.

Challenges:1.It was difficult to code for the ball to stay within the boundaries and bounce off the paddles.2.Controlling the direction of the ball and where it would head towards.3.Having the top paddle be controlled by the mouse keys.4.Finalizing the game and making sure it runs smoothly without lag.

Page 6: PAYS 2014 Research Powerpoint

Frustration

Page 7: PAYS 2014 Research Powerpoint

FrustrationWhy? • The purpose of our game is to frustrate

people as much as possible.Design: Frustration controller(contains methods)Falling tile (contains object animations)Challenges: • Making the original idea a reality • Coding in the correct order

Page 8: PAYS 2014 Research Powerpoint
Page 9: PAYS 2014 Research Powerpoint

HappyKimWhy?• It is a very well known game, so we

thought it would be fun to recreate it. • We thought it would be simple to

work with and to add our own designs and animations.

Design:Classes:

Controller-contains all the methodsBird- used to control falling ball animationTubes- used to create the tubesTubes Controller- used to control the motion of the tubes

Challenges:• It was difficult to program the “bird”

falling object to jump at specific shifts.

• In addition, it was difficult to program the motion of the tubes and to generate random tube heights.

Page 10: PAYS 2014 Research Powerpoint

ConclusionWe would like to give a special Thank You to:

Sergio Marin

Dr. Maria Tucker

Professor Chen

Dunmi Alabi

Page 11: PAYS 2014 Research Powerpoint