In 2015.12.25, the 10-day project training and defense of C language was formally concluded.
The C language project is to do an adventure play strange game, feeling quite deep, combined with the experience of the last site training, this time I almost have a harvest and do not understand the new Notepad records and finishing, then I will elaborate on this project's feelings and summary.
This project is not like the previous site training-it is a team project, this time the project is completely to show the personality and ideas.
At the beginning, curiosity and longing.
The first day to do the project, holding the project process completely do not know where to start, so really the first day is really almost no progress, just done with printf ("") Design game home page, the main interface style.
When you start the project the next day, you think you can try to do it by sub-module. The main task of this day is to write the background of the game story, and to complete the login and registration, the heart has a goal, indeed better than the first day, but the new problem arises, that is, the registration information can not be closed after not to be retained, the question is no answer, finally I had to register after the end, Designed a System ("CLS") to clear the screen waiting for sleep time, and then add the login code, temporarily. As for the official method, I can share it with some effective methods.
On the third day, a progress bar was designed to load the game, and the map was drawn (I used 20*20). The progress bar uses the design of a for loop to print the shape of the box to complete, and the biggest problem, in addition to the idea map, is how to let the map appear, mobs randomly appear. And the final method is to ask Niang, the appearance of the map, with the IF statement design, my map with 0 for the empty road, 1 for the wall, 3 for the small strange, 5 for the Big Strange, 4 for the boss, and to randomly appear monsters, the use of the Srand function, set random seeds, and rand ()%100+ 1 This proportional style to design the random monsters;
The fourth day, is the most painful day for me. Because today, I find a whole day to find the wrong. On this day, the main thing is to let my players move freely. And my biggest failure is no error, but my player can't move. The sense of failure continues to arise when a mistake is made once and for all, but what I can do is to keep my mind on it. And the last thing that's causing me to move is the new map I designed, Roley,rolex and i,j (the rows and columns I set) are just the opposite. But not to find, how to know that the error is actually here?
On the fifth day, a two-dimensional array to draw monsters, my little monster is a cold-blooded small scorpion, the big Strange is a giant Lion King, and boss is looking lovely invincible actually has invincible magical power of Pikachu.
On the sixth day, the code of the monster is added to the main code, and the code for looping the monster is compiled;
The seventh day, eight days, then design monsters attack, escape and other functions. In order to demonstrate the simplicity of my game, I used the method of fixing monsters, the effect of a dozen monsters died, thus saving time;
The Nineth day, the completion of the project PPT;
Day of the reply;
This time the project, in addition to the basic, I at the beginning and every success killed a monster after the addition of the mysterious hint of the letter, as hints and encouragement ... This inspiration comes from the mystery of escape from the Chamber of Secrets.
After 10 days of project training, feel the most is in addition to calm down, do not ask!
C Language Project Summary