Writing the JavaFX Pac-Man Game Part 3

Posted: May 31st, 2009 under JavaFX, JavaFX Coding, Javafx Games.
Tags: , , , ,

The latest JavaFX article of writing the Pac-Man game is published on May 28. It is the third out of a five-article series: “Writing the Pac-Man Game in JavaFX – Part 3“.

In this article, the ghosts are introduced. The animation of the ghosts are almost the same as the Pac-Man character. It is basically moving a CustomNode and switching the images. There are three sets of images for the animation: normal, hollow and flashing. The moving algorithm of the ghosts is the heart of the code. In this article, for simplicity, a random moving algorithm is applied. A more complicated moving behavior of the ghosts will be introduced in Article 5. Click on the below image to try the program so far. The Pac-man and ghosts cannot eat each other even they meet in the maze. The feature of eating each other will be illustrated in next article. As before, you can try this semi-completed program by clicking Java Web Start button below:

Related Articles:

My JavaFX Demo Game: Pac-Man

Articles on Writing the JavaFX Pac-Man Game

Pac-Man Game WidgetFX Widget

JavaFX Game Example Code: MineSweeper

JavaFX Game Demo Example: Pac-Man

Other unrelated links:

Applicant of American Citizenship Information, software and guide.

Guide American Citizenship in United States

Canadian Citizenship Application and Practice Exam

No Comments

No comments yet.

RSS feed for comments on this post.