This project adopts es6 object-oriented development mode. As a newcomer to the game, I will use more game design modes in the project to learn game development. In order to focus on the code, the game does not use any graphics resources, and the UI components are all native to the game engine (drag and drop).
The game is introduced
The original intention of developing this game is to play the game “Wandering Diary”, which has a high score and the author is very careful. I thought it was fun, and I recommended it to a girl, who started talking to me about it every night. As a programmer who has learned a little bit about game development, I plan to copy the game and eventually complete a framework for a word game, which could become many interesting small games with different scripts.
Project introduction
The project is still under development, so I set up the general framework first. The project address
- AudioManager is the code I copied, which is not used at present. I have made a secondary encapsulation of the audio of the engine.
- Command uses the Command pattern of design mode.
- Enum defines all enumeration types in a game.
- Events define all game events.
- Func draws out common methods in the game.
- Listener Design mode observer mode (self written very easy), can be used, but not used, with the engine itself distribution.
- MonsterFactory uses the prototype pattern of design mode to define many monster prototypes.
- PlayerManager role class, which defines the attributes and behavior of the role.
- State uses a finite State machine in State mode.
- The rest of the scripts that end in Scene are the scripts that hang on the game Scene and are responsible for the main logic of the game.
I will do some interpretation of each script file later. If you are interested in the program, or would like to study together, please contact me.