"Java Game Project: Puzzle Game Development Video Tutorial" has the function of freely selecting pictures. You can choose your favorite pictures according to your own interests to play the game. In order to reduce the difficulty, a digital prompt function is added to the game. In the game interface, the left half is the game area, and the right half is the original picture preview. When the game starts, the system will randomly allocate a missing piece and disrupt the order of the pictures. The user can move and restore the original picture. The number of steps and time will be counted in the game for players to compare. This game is completely operated by the mouse, making it easy to get started.
Course playback address: http://www.php.cn/course/619.html
This video was created by Chuanzhi Podcast teacher Zhou Yu. The teacher’s teaching style:
The teacher’s lectures are friendly and natural, unpretentious, without pretense or deliberate exaggeration. It is a eloquent talk, a detailed discussion, a silent emotional exchange between teachers and students in an atmosphere of equality, collaboration, and harmony, and the desire and exploration of knowledge are integrated into a simple and real teaching situation. , students gain knowledge through quiet thinking and silent approval.
The more difficult part in this video is the main interface of the game:
MainApp Launcher
main():
Create the main interface Interface class object
Display interface
-------------------
PictureMainFrame main interface
init() interface initialization operation:
Specify the game window size
Specify the game title
Specify the display position of the game window
Specify the game window size Add a component method for a fixed size
addCompoment():
Complete the component settings for the button area
Complete the component settings for the game state
addPicturePreview() Add puzzle game preview and puzzle interface:
Complete the setting of the preview image on the right
Complete the setting of the coordinate puzzle image
I also recommend it to everyone here Download source code resources: http://www.php.cn/xiazai/code/2046
This courseware contains the code of the entire project, as well as documents, instructions, etc.~
The above is the detailed content of Video and resource recommendations for Java development puzzle game projects. For more information, please follow other related articles on the PHP Chinese website!