You are on page 1of 13

DOCUMENTATION

Project Name: Snake Game


Development Language: C#

Developed By:
 Fuad Hossain
 11310214
 IT
 Sanjida Rahman
 11310829
 IT

Submitted To:
Mohammad Minhazul Alam, Lecturer CSE/IT, UITS.
Table of Content:
No. …………………. Content
1 ………………… Introduction
2 ………………… Acknowledgements
3 ………………… Game Attribute
4 .....………… System Architecture
4.1………………… Game Components
4.2………………… Game Architecture
5 ………………… Game Construction
5.1 ……………… Building the Game
5.2 ……………… Game Play
6 …………………… Development Challenges
7 …………………… Conclusion
8 …………………… Reference

Figure Lists:
Fig:-3.1(snake game window)
Fig:-3.2(Game Attributes)
Fig:-4.1(Main class)
Fig:-4.2(Snake, Snake1)
Fig:-4.3(Food)
Fig:-4.4(Simple architecture of snake game)

Game Play:-
Figure 5.2.1
Figure 5.2.2
Figure 5.2.3
Development challenges:
Figure 6.1
Figure 6.1
Figure 6.3(Communication between Me & Friend)
1. Introduction:
Project documentation is concerned with describing the delivered
software product, in this case the Multiplayer Snake game project.
Project documentation includes user documentation which tells users
how to use the software product and system documentation which is
principally intended for further development and understanding.
2. Acknowledgement(s):

Thank you Mohammad Minhazul Alam Sir for pushing us and


inspiring to build and understand a multiplayer Snake game. Thanks
for the effort and giving us lectures and explaining the architecture.
Thanks for helping when we were stop in the middle during the
development phase. We could not have built such a challenging
project without your help.
3. Game Attributes:
The name of the game is “Multiplayer Snake Game”. It’s a
multiplayer game which can be played in the same machine. In this
game we use four arrow keys and “A”,”S”,”D” & “X” to control the
snake direction. And when press Enter game start and when press
Space bar game become pause.

Fig:-3.1(snake game window)


Fig:-3.2(Game Attributes)

4. System Architecture:
System architecture is the skeleton view behind the GUI part of a
game. System architecture defines the working methodology of the
game and shows the components, their relationships and how they
evolve to make the game work. The system architecture of this
particular game can be divided into two parts:
 Game components.
 Game architecture.

4.1 Game Component:


Game Components are behind the scene classes and methods which
make up the game and all the functionalities. The components are
mesh together and there are lot of inter relationships between them.
The main components are described below:
Main class: Main class is where all the components are connected
and it’s the heart and mind of the game. In this game it is named
“frmMain.cs”. The GUI of the game is represented in this class. The
movement is also listened from here & different methods are used for
different functionality.
Fig:-4.1(Main class)
Snake class: Snake class is a class which is used to draw, design,
control movement and define Snake behavior.
Snake1 class: Snake1class is a class which is used to draw, design,
control movement and define Snake1 behavior.
Here some method of Snake & Snake1:-
Public void Draw ()-for draw Snake
Public void Draw (Graphics graphics)-for snake color
Public void Move (int direction)-for move
Public void Grow ()-for snake grow
Fig:-4.2(Snake, Snake1)

Food class: Food class is a class which is used to draw, design food.
Here food is randomly generated. When the Snake & Snake1 eat food
they become grow.
Public Food (Random rand)
Public void Draw (Graphics graphics)
Public void Generate (Random rand)
x=rand.Next(0,30)*10;
y=rand.Next(0,20)*10;

Fig:-4.3(Food)
4.2 Game Architecture: The Game Architecture is the simplified
graphical view of the game. It shows how the components work and
the basic view of the game at action. The architectural view of the
game is very important. Simply it gives an overview of the game
functionality and it makes the game easy to understand.
Fig:-4.4(Simple architecture of snake game)

5. Game Construction:
Here we develop the game and test the game and ultimately play the
game. Construction phase can be divided into 2 phases:
 Building the Game
 Game play
5.1 Building the Game:
It’s the headrest part in all the line of process.
When we first start the game we first planning, find out the
requirements, draw the architecture.
To build the game need to know programming language (this time
C#).
The development phases are:
 Creating a single Snake.
 Creating a Food.
 Then creating two snakes.
 Snakes collision with food.
 Snakes collision with each other body.
 Snakes don’t move two directions at a same time.

5.2 Game Play:


The steps of game play are given below:-
i) Open the game application:

Figure 5.2.1

ii) Press debugs & shows the level.


Figure 5.2.2

iii) Press enter and the game is start.

Figure 5.2.3

6. Development challenges:
We had to face a lot of challenges during the development phase. We
cannot make this game playable through network. We only developed
multiplayer game in same machine that is handled by button.
That’s why our respectable teacher Mohammad Minhazul Alam gives
our opportunity to make a Chat box.
That’s given below:-
i) Open the chat application: same pc that’s why IP is same.

Figure 6.1
ii) Open the ‘ChatBox.exe’ file and gives the port number of
“Me” & “Friend”.

Figure 6.1
iii) Open again the ‘ChatBox.exe’ files and gives the different
port number of “Me” & “Friend”.

Figure 6.2

iv) After connecting the both chat box ‘Me’ and ‘Friend’ can
communicate with each other.
Figure 6.3(Communication between Me & Friend)

7. Conclusion:
This project gives us more thrilling, frustrating and also gives us more
pleasure. It helps us in many sectors like- planning, designing,
developing, managing, programming skill, socket programming and
so on.
8. References:
 Class Lecture.
 https://www.youtube.com/watch?v=rFFVyNn9_8A
 http://www.c-sharpcorner.com/UploadFile/udeshikah/snake-
game-application-in-C-Sharp/
 http://www.dreamincode.net/forums/topic/243537-control-issue-
with-snake-game-in-c%23/
 http://csharp.net-informations.com/communications/csharp-
chat-client.htm

You might also like