Java Programming

 

         

 

Thursday, December 12th

 

Friday last day for any makeup work!

Open Eclipse to be sure it is installed and working on your computer.

Labeling Exercise - make a copy and show me once you have filled in the blanks.

Sections 3.1-3.5 Quiz Friday!

Friday we will discuss what is on the final exam, what should you be able to do.

Continue work on your full page of notes for the exam.

Alice Game Demo??

Java API - to find out about any Java classes and methods check the Java API.

By popular demand - How to remove objects from the world
If the following is placed in the Crab act method then when the crabs reach the edge of the world they are REMOVED!

if (atWorldEdge())
getWorld().removeObject(this);

Adding Keyboard Controls

How to see what your variables are doing
System.out.println("counter number = " + count);

Section 3: Lesson 5 - Randomization and Constructors vocabulary:
- A technique that allows a class to use a method from another class or object. The dot between the class/object name and the method name indicates that the method comes from a different class or object.
- A special kind of method that is automatically executed whenever a new instance of the class is created.
- A keyword that indicates that a new object is being created.
- Symbols that compare two random values in a method.

Complete Section 3: Lesson 5 - Randomization and Constructors slides.
Complete Section 3: Lesson 5 - Randomization and Constructors practice and project.
For step 19 check the Greenfoot class API to find the code for the key press check.
You can also type Greenfoot. and then press Ctrl + space and it will pop up a code completion box
Show these to your instructor for teacher check.

Section 3: Lesson 6 - Defining Methods vocabulary:
- A new method that a class didn't already possess; these methods are written in the class's source code below the act() method.

Complete Section 3: Lesson 6 - Defining Methods slides.
Complete Section 3: Lesson 6 - Defining Methods practice and project.
Show these to your instructor for teacher check.

Section 3: Lesson 7 - Sound and Keyboard Control vocabulary:
- A method that will play a sound file.

Complete Section 3: Lesson 7 - Sound and Keyboard Control slides.
Complete Section 3: Lesson 7 - Sound and Keyboard Control practice and project.
Show these to your instructor for teacher check.

 

Homework

Review Declaring Procedures and Control Statements and Functions

 

What

In this lesson, you will learn how to:
•How to download and install Greenfoot
• Describe the components of the Greenfoot interactive development environment
• Create an instance of a class
• Describe classes and subclasses
• Recognize Java syntax used to correctly create a subclass

 

Why

Learning to program, and learning programming concepts while creating a game can be fun. Using Greenfoot, you will learn basic Java programming techniques to create fun and interactive games.

 

How

By completing the slides, quiz and practice exercises.