Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • namy2/se3xa3
  • bokhari/se3xa3
  • kanwalg/se3xa3
  • sunx20/se3xa3
  • hameea1/se3xa3
  • aij/se3xa3
  • hanzy3/se3xa3
  • linl20/se3xa3
  • zhous20/se3xa3
9 results
Show changes
Commits on Source (40)
Showing
with 1356 additions and 96 deletions
No preview for this file type
\documentclass{article}
\usepackage{pdfpages}
\usepackage{booktabs}
\usepackage{tabularx}
\usepackage{hyperref}
\title{SE 3XA3: Development Plan\\Title of Project}
\author{Team \#, Team Name
\\ Student 1 name and macid
\\ Student 2 name and macid
\\ Student 3 name and macid
\title{SE 3XA3: Development Plan\\Snake 2.o}
\author{Team \# 30, VUA30
\\ Vaibhav Chadha , chadhav
\\ Usman Irfan , irfanm7
\\ Andy Hameed , hameea1
}
\date{}
\input{../Comments}
\begin{document}
......@@ -23,9 +26,12 @@
\toprule
\textbf{Date} & \textbf{Developer(s)} & \textbf{Change}\\
\midrule
Date1 & Name(s) & Description of changes\\
Date2 & Name(s) & Description of changes\\
... & ... & ...\\
Sept 25, 2018 & Vaibhav, Usman, Andy & Worked on part 1 to 4\\
Sept 27, 2018 & Vaibhav, Usman, Andy & Worked on part 4 to 8\\
Sept 27, 2018 & Vaibhav & Added the information from the meeting documents to the LaTeX file\\
Sept 28, 2018 & Andy & Proof of concept, Git workflow, Final editing and formatting\\
Sept 28, 2018 & Usman & Updated proof of concept\\
Oct 12, 2018 & Andy & Made changes according to feedback on development plan and added section on POC demo\\
\bottomrule
\end{tabularx}
\end{table}
......@@ -34,25 +40,97 @@ Date2 & Name(s) & Description of changes\\
\maketitle
Put your introductory blurb here.
\section{Team Meeting Plan}
Meetings will be held \textbf{twice a week} at the following times:
\begin{itemize}
\item Mondays 5:30 - 6:30 pm at KTH Computer Labs
\item Wednesdays 12:30 to 2:00pm at Health science library
\end{itemize}
\subsection{Roles and Agenda}
\textbf{Chair}: Andy Hameed
\begin{itemize}
\item Responsible for creating the agenda and selecting topics that pertain to all team members
\item Agenda items will be listed as questions\\
\end{itemize}
\textbf{Notettaker}: Usman Irfan
\begin{itemize}
\item Responsible for taking meeting minutes
\item Meeting decisions will be summarized in a statement at the end of the meeting
\end{itemize}
\textbf{Timekeeper}: Vaibhav Chadha
\begin{itemize}
\item Keeps track of time in case we are spending too much time on one topic
\end{itemize}
\section{Team Communication Plan}
Main source of communication is \textbf{Facebook Messenger}, it will be used for general inquiries, updates, reminders of team meetings, any links to useful resources and so on. Phone and texting will be used as a backup in case of urgent matters, for example not being able to get in contact with a team member through messenger.
Aside from these, the team will be using Workflowy to assign small tasks that are promptly due or ones that may not necessarily fit on the gantt chart because they are minor - this tool will be used to delegate a small to-do list for each team member .
\section{Team Member Roles}
Vaibhav Chadha:
\begin{itemize}
\item Latex Documentation
\item Analyst - makes sure the requirements of the clients are met through the software
\item gantt chart management\\
\end{itemize}
Usman Irfan:
\begin{itemize}
\item Scribe
\item Technology Research
\item operation manager -ensures project development is running smoothly and software is being developed according to milestones \\
\end{itemize}
Andy Hameed:
\begin{itemize}
\item Final editing
\item latex documentation
\item team leader\\
\end{itemize}
All:
\begin{itemize}
\item GIT project management
\end{itemize}
\section{Git Workflow Plan}
We will be using the Git Feature Branch Workflow to manage the software development. Using branches, each team member is capable of
working on different modules or sections of the software at the same time in localized branches, before pushing their changes to the master branch.
The following procedures will be followed:
\begin{itemize}
\item Vaibhav will be tagging any major milestones for final submission. This makes the submission process consistent. Otherwise, Andy or Usman will agree on one person to tag and submit for final submission.
\item Any major changes can be placed in a branch to avoid merging conflicts and overwriting existing work. They can be merged later on upon team agreement.
\end{itemize}
\section{Proof of Concept Demonstration Plan}
The original project is built using Javascript, HTML and CSS in contrast to our development plan using python and the Pygame library. Since we are using an OOP language, we will be able to create classes for different components of the snake game such as the snake unit block, snake body, and snake bate. The hardest part of the implementation will be the movement of the snake according to the user's keyboard inputs, and second to that would be the process of expanding the snake once a food item is captured. Besides that, the interface may be difficult to implement in python but could be simple with the use of a python framework such as PyQT5.\\
Once our game application has been developed the next part would be to test the project and for that we will be using Pytest, since our backend language is python this will help us test all possible functions and aspects. The functions that will be difficult to test would be to see if the snake eats the food, does the food appear at random locations after eaten by the snake and if the snake tries to leave the borders, will the game end. Portability will have to be taken into consideration since the application is being built for windows. However, it can be compiled and run on any system as long as the necessary files and libraries are download.
\subsection{POC Demo}
The team will be demonstrating the movement of a snake around the screen using unit blocks for the body of the snake. Lengthening the snake body, scoring and eating the bate will not be demonstrated in the demo. This POC should demonstrate that with the movement of the snake, which is the main component of the game, the team will be able to develop classes to represent other components of the game such as the score, food bate, and lengthening of the snake body.
\section{Technology}
Coding Language: Python, Kivy for GUI\\
IDE: IDLE scripting\\
Testing: PyUnit testing\\
Documentation: Doxygen\\
\section{Coding Style}
We will be using the \href{https://github.com/google/styleguide/blob/gh-pages/pyguide.md}{Google Python Style Guide}
for our coding style. It encompasses all the necessary naming conventions and standards required for the project development.
\section{Project Schedule}
Please see the following pages for the project schedule in the form of a gantt chart.
Provide a pointer to your Gantt Chart.
\includepdf[page=-]{../../ProjectSchedule/Team_Gantt}
\section{Project Review}
......
No preview for this file type
......@@ -3,17 +3,17 @@
\usepackage{tabularx}
\usepackage{booktabs}
\title{SE 3XA3: Problem Statement\\Title of Project}
\title{SE 3XA3: Problem Statement\\ \textbf{Snake Game}}
\author{Team \#, Team Name
\\ Student 1 name and macid
\\ Student 2 name and macid
\\ Student 3 name and macid
\author{Team \#30, VUA30
\\ Usman Irfan - irfanm7
\\ Andy Hameed - hameea1
\\ Vaibhav Chadha - chadhav
}
\date{}
\date{2018-09-21}
\input{../Comments}
\usepackage[left=2cm, right=5cm, top=2cm]{geometry}
\begin{document}
......@@ -23,9 +23,10 @@
\toprule
\textbf{Date} & \textbf{Developer(s)} & \textbf{Change}\\
\midrule
Date1 & Name(s) & Description of changes\\
Date2 & Name(s) & Description of changes\\
... & ... & ...\\
2018-09-20 & Vaibhav & Made the LaTeX file and wrote the section with what the Problem is\\
2018-09-20 & Usman & Added the Importance of Problem section while formatting the LaTeX\\
2018-09-21 & Andy Hameed & Formatted LaTeX file and added Context section, giving the final editing to the document\\
2018-10-09 & Andy Hameed & Edited doc to reflect web app to desktop app decision change\\
\bottomrule
\end{tabularx}
\end{table}
......@@ -34,16 +35,17 @@ Date2 & Name(s) & Description of changes\\
\maketitle
Put your problem statement here.
\subsection*{The Problem}
\wss{comment}
Almost everyone nowadays relies on a computer as a multipurpose tool for research, video streaming, gaming and many other tasks. With the emergence of fast computing, gaming has become a popular pastime activity and a source of entertainment for many. However, not everyone has a device powerful enough to support extensive game applications. A simple, memory effecient application of the Snake game allows it to be accessible for gamers without the need for extensive hardware or a high-performance computer. Our team, VUA30, will be creating a desktop application for the well-known Snake game with new enhancements and features. This competitive and addictive game can allow the user to play at their own pace and challenge their own high score.
\ds{comment}
\subsection*{Importance of the Problem}
\mj{comment}
Buying a computing device with high storage and faster performance can be out of budget. Complicated software covers up all the storage and the user is bound to use these applications as opposed to downloading other software. The importance of the redevelopment of The Snake is to save computing devices' personal storage and allow the user to play a game 24/7 with strong performance, even offline. Creating a desktop version of the snake game can fit into the category of downloadable calssical games such as the solitaire suite. The recreation of this game will allow the user to enjoy the classical game anytime and anywhere as long as they have installed the application. Improving aspects such as graphics and custom speed will also make the game more interesting. We would like to add more features to the game to make it more customizable and help people enjoy the classical game in an exciting and new way.
\cm{comment}
\mh{comment}
\subsection*{Context}
The stakeholders are mainly the gaming audience, the older generation of game enthusiasts, youth and teens. Some other stakeholders that Although the game can be played by anyone, it is targeted towards the audience mentioned above who are most invested in the game. The environment is native app development using Python. This provides provides less flexibility than web API's but there still exists many useful libraries which can be used such as Pygame for example.
\end{document}
\end{document}
\ No newline at end of file
......@@ -7,6 +7,11 @@
%% Saved with string encoding Unicode (UTF-8)
@article{devArticle,
Author = {Sumit Jain},
Title = {Game Development Life Cycle},
Year = {May 2017}
}
@book{RobertsonAndRobertson2012,
Author = {James Robertson and Suzanne Robertson},
......
No preview for this file type
This diff is collapsed.
No preview for this file type
......@@ -3,26 +3,26 @@
\usepackage{booktabs}
\usepackage{tabularx}
\usepackage{hyperref}
\usepackage{amsmath}
\hypersetup{
colorlinks,
citecolor=black,
filecolor=black,
linkcolor=red,
linkcolor=black,
urlcolor=blue
}
\usepackage[round]{natbib}
\title{SE 3XA3: Test Plan\\Title of Project}
\author{Team \#, Team Name
\\ Student 1 name and macid
\\ Student 2 name and macid
\\ Student 3 name and macid
\author{Team 30, VUA
\\ Andy Hameed and hameea1
\\ Usman Irfan and irfanm7
\\ Vaibhav Chadah and chadhav
}
\date{\today}
\input{../Comments}
\begin{document}
......@@ -38,7 +38,7 @@
\begin{tabularx}{\textwidth}{p{3cm}p{2cm}X}
\toprule {\bf Date} & {\bf Version} & {\bf Notes}\\
\midrule
Date 1 & 1.0 & Notes\\
10/25/2018 & 1.0 & Andy added section 4.0\\
Date 2 & 1.1 & Notes\\
\bottomrule
\end{tabularx}
......@@ -48,8 +48,6 @@ Date 2 & 1.1 & Notes\\
\pagenumbering{arabic}
This document ...
\section{General Information}
\subsection{Purpose}
......@@ -144,82 +142,213 @@ How test will be performed:
\subsection{Tests for Nonfunctional Requirements}
\subsubsection{Area of Testing1}
\paragraph{Title for Test}
\subsubsection{Look and Feel}
\begin{enumerate}
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The game should be installed on the device.
Input/Condition: The game is opened and ran on the device.
Output/Result: The User Interface should open with different buttons, alongside with a playground with a snake in it.
How the test will be performed: The program will manually run on the device and checked by the human eye to see if it meets the criteria.
\end{enumerate}
\item{test-id1\\}
\subsubsection{Usability}
Type:
Initial State:
Input/Condition:
Output/Result:
How test will be performed:
\item{test-id2\\}
\begin{enumerate}
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The program will be running for a human nearing 10 years of age or above
Input/Condition: The program will be set on its default settings
Output/Result: The person testing should be able to understand the game and play it. He/she should be able to customize themes and speed of the game.
How the test will be performed: A younger human of nearing age 10 will be asked to operate this game and recorded if he/she is able to operate it successfully or not.
\end{enumerate}
Type: Functional, Dynamic, Manual, Static etc.
Initial State:
Input:
Output:
How test will be performed:
\subsubsection{Performance}
\begin{enumerate}
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The program will be running with the main user interface open.
Input/Condition: The button is pressed.
Output/Result: The response time for button should be less than half a second.
How the test will be performed: It will be performed using human actions. The response would be times to be as precise as possible. Also, it will be taken into consideration that the user doesn't have to wait for a long observable time.
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The snake Game will be running on the device.
Input/Condition: Various speed inputs for the snake.
Output/Result: Different snake speeds according to what the user has decided
How the test will be performed: The game will be played with inputting different speeds. Then, the speed difference will be observed as the game progressed through and taken care that the game goes at the constant speed at each level.
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The snake Game will be running on the device.
Input/Condition: The snake will be moving around and keys will be pressed to change directions.
Output/Result: Snake should change directions promptly.
How the test will be performed: While the game is going on, the buttons will be pressed to change the direction of the snake.
\end{enumerate}
\subsubsection{Area of Testing2}
\subsubsection{Operational and Environmental}
...
\begin{enumerate}
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The program will be moved on a USB.
Input/Condition: The USB will be inserted into any other working computer/ Desktop.
Output/Result: The game should be able to run on it as long as the device is powered and in working state.
How test will be performed: Many different laptops, alongside with desktops, will be used to test. The game will be played on different devices with different specifications to make sure that the game is playable regardless of the specs of the device.
\end{enumerate}
\subsubsection{Maintainability and Support Requirements}
\begin{enumerate}
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The program will be moved to a Windows, Mac OS and Linux operating devices.
Input/Condition: The program will be executed.
Output/Result: The game should run.
How test will be performed: The game will be taken and transferred to the systems operating on different OS's. For this, the target is Windows device, Mac OS device and a Linux Device.
\end{enumerate}
\subsubsection{Security and Cultural}
\begin{enumerate}
\item{test-id1\\}
Type: (Structural, Functional, unit), Dynamic, Manual
Initial State: The program will be running.
Input/Condition: All the interfaces running.
Output/Result: No offensive or illegal content on the entire application.
How test will be performed: The application will be executed and each page and option will be approached to make sure there is no offensive or illegal content. Also, there is a Static module to this requirement where all the files (including code) will be looked to make sure about no offensive or illegal content.
\end{enumerate}
\subsection{Traceability Between Test Cases and Requirements}
\section{Tests for Proof of Concept}
\subsection{Area of Testing1}
\subsection{Snake Dynamics}
\paragraph{Title for Test}
\paragraph{Snake Movement and Speed}
\begin{enumerate}
\item{test-id1\\}
\item{T1D1\\}
Type: Functional, Dynamic, Manual, Static etc.
Type: Dynamic
Initial State:
Initial State: The snake body - graphically represented by a red square - is initially motionless. It exists somewhere within the frame of the window.
Input:
Input: Keyboard Event - user clicks on one of the directions on the keyboard arrow pad.
Output:
Output: Snake moves according to the direction chosen. This can logically represented by the expression keyboardEvent.direction == snakeMovementDirection. Note that the variables used are arbitrary and are dependant on Python syntax.
How test will be performed:
How test will be performed:
\begin{itemize}
\item A method will be created under the POC test class where the keyboard event is manually set to the code representing each of the directions on the arrow keypad - up, down, left and right. The direction inserted will be asserted equal to the direction of the moving snake, set by some variable.
\item After starting the game, the user will click on each one of the four directions and verify whether or not the snake is moving in the corresponding direction, using the graphical interface created with Pygame.
\end{itemize}
\item{T1D2\\}
Type: Dynamic, Functional testing
\item{test-id2\\}
Type: Functional, Dynamic, Manual, Static etc.
Initial State: The snake body - graphically represented by a red square - is initially motionless. It exists somewhere within the frame of the window.
Initial State:
Input: Keyboard Event - user clicks on one of the directions on the keyboard arrow pad.
Input:
Output: Snake moves accurately according to the speed set in the snake module. Statically, this can represented for the vertical movement of the snake by this expression:
\begin{align*}
(snakeFinalPosition - snakeInitPosition) == (speed \times timeElapsed)*vel
\end{align*}
where vel is the distance defined for 1 single step and speed is the delay between each step in milliseconds
How test will be performed: A method will be created under the POC test class where the keyboard event is manually set to the code representing each of the directions on the arrow keypad - up, down, left and right. The logical expression above is implemented into an assert statement verifying that the distance moved corresponds to the speed and velocity that were used as well as the time that has elapsed - this can be obtained from the time object in Pygame.
\end{enumerate}
\subsection{Integration and System Testing}
\begin{enumerate}
\item{T1D3\\}
Type: Integration, System testing
Output:
Initial State: The game menu is loaded onto the window with options for starting the game and quitting the game.
How test will be performed:
Input: The following sequence of inputs
\end{enumerate}
\begin{enumerate}
\item User clicks start game
\item Keyboard Event - user clicks on one of the directions on the keyboard arrow pad.
\item user exits the window by clicking the exit tab on the top right corner of the screen
\end{enumerate}
\subsection{Area of Testing2}
Output: Snake game runs as intended. The "start game" option leads the user to the game screen where the snake body sits motionless. The user moves the snake body using the keyboard arrow pad, moving in directions that correspond apprioriately to the arrows clicked and in the correct sequence. The game window is closed once the user clicks the exit button on the top right corner.
How test will be performed: Several peers will be asked to test the game from start to finish for this integration and system test.
...
\end{enumerate}
\section{Comparison to Existing Implementation}
......@@ -229,9 +358,6 @@ How test will be performed:
\subsection{Unit testing of output files}
\bibliographystyle{plainnat}
\bibliography{SRS}
\newpage
......
File added
\documentclass{article}
\usepackage{pdfpages}
\usepackage{booktabs}
\usepackage{tabularx}
\usepackage{hyperref}
\title{SE 3XA3: Development Plan\\Snake 2.o}
\author{Team \# 30, VUA30
\\ Vaibhav Chadha , chadhav
\\ Usman Irfan , irfanm7
\\ Andy Hameed , hameea1
}
\date{}
\begin{document}
\begin{table}[hp]
\caption{Revision History} \label{TblRevisionHistory}
\begin{tabularx}{\textwidth}{llX}
\toprule
\textbf{Date} & \textbf{Developer(s)} & \textbf{Change}\\
\midrule
Sept 25, 2018 & Vaibhav, Usman, Andy & Worked on part 1 to 4\\
Sept 27, 2018 & Vaibhav, Usman, Andy & Worked on part 4 to 8\\
Sept 27, 2018 & Vaibhav & Added the information from the meeting documents to the LaTeX file\\
Sept 28, 2018 & Andy & Proof of concept, Git workflow, Final editing and formatting\\
Sept 28, 2018 & Usman & Updated proof of concept\\
Oct 12, 2018 & Andy & Made changes according to feedback on development plan and added section on POC demo\\
\bottomrule
\end{tabularx}
\end{table}
\newpage
\maketitle
\section{Team Meeting Plan}
Meetings will be held \textbf{twice a week} at the following times:
\begin{itemize}
\item Mondays 5:30 - 6:30 pm at KTH Computer Labs
\item Wednesdays 12:30 to 2:00pm at Health science library
\end{itemize}
\subsection{Roles and Agenda}
\textbf{Chair}: Andy Hameed
\begin{itemize}
\item Responsible for creating the agenda and selecting topics that pertain to all team members
\item Agenda items will be listed as questions\\
\end{itemize}
\textbf{Notettaker}: Usman Irfan
\begin{itemize}
\item Responsible for taking meeting minutes
\item Meeting decisions will be summarized in a statement at the end of the meeting
\end{itemize}
\textbf{Timekeeper}: Vaibhav Chadha
\begin{itemize}
\item Keeps track of time in case we are spending too much time on one topic
\end{itemize}
\section{Team Communication Plan}
Main source of communication is \textbf{Facebook Messenger}, it will be used for general inquiries, updates, reminders of team meetings, any links to useful resources and so on. Phone and texting will be used as a backup in case of urgent matters, for example not being able to get in contact with a team member through messenger.
Aside from these, the team will be using Workflowy to assign small tasks that are promptly due or ones that may not necessarily fit on the gantt chart because they are minor - this tool will be used to delegate a small to-do list for each team member .
\section{Team Member Roles}
Vaibhav Chadha:
\begin{itemize}
\item Latex Documentation
\item Analyst - makes sure the requirements of the clients are met through the software
\item gantt chart management\\
\end{itemize}
Usman Irfan:
\begin{itemize}
\item Scribe
\item Technology Research
\item operation manager -ensures project development is running smoothly and software is being developed according to milestones \\
\end{itemize}
Andy Hameed:
\begin{itemize}
\item Final editing
\item latex documentation
\item team leader\\
\end{itemize}
All:
\begin{itemize}
\item GIT project management
\end{itemize}
\section{Git Workflow Plan}
We will be using the Git Feature Branch Workflow to manage the software development. Using branches, each team member is capable of
working on different modules or sections of the software at the same time in localized branches, before pushing their changes to the master branch.
The following procedures will be followed:
\begin{itemize}
\item Vaibhav will be tagging any major milestones for final submission. This makes the submission process consistent. Otherwise, Andy or Usman will agree on one person to tag and submit for final submission.
\item Any major changes can be placed in a branch to avoid merging conflicts and overwriting existing work. They can be merged later on upon team agreement.
\end{itemize}
\section{Proof of Concept Demonstration Plan}
The original project is built using Javascript, HTML and CSS in contrast to our development plan using python and the Pygame library. Since we are using an OOP language, we will be able to create classes for different components of the snake game such as the snake unit block, snake body, and snake bate. The hardest part of the implementation will be the movement of the snake according to the user's keyboard inputs, and second to that would be the process of expanding the snake once a food item is captured. Besides that, the interface may be difficult to implement in python but could be simple with the use of a python framework such as PyQT5.\\
Once our game application has been developed the next part would be to test the project and for that we will be using Pytest, since our backend language is python this will help us test all possible functions and aspects. The functions that will be difficult to test would be to see if the snake eats the food, does the food appear at random locations after eaten by the snake and if the snake tries to leave the borders, will the game end. Portability will have to be taken into consideration since the application is being built for windows. However, it can be compiled and run on any system as long as the necessary files and libraries are download.
\subsection{POC Demo}
The team will be demonstrating the movement of a snake around the screen using unit blocks for the body of the snake. Lengthening the snake body, scoring and eating the bate will not be demonstrated in the demo. This POC should demonstrate that with the movement of the snake, which is the main component of the game, the team will be able to develop classes to represent other components of the game such as the score, food bate, and lengthening of the snake body.
\section{Technology}
Coding Language: Python, Kivy for GUI\\
IDE: IDLE scripting\\
Testing: PyUnit testing\\
Documentation: Doxygen\\
\section{Coding Style}
We will be using the \href{https://github.com/google/styleguide/blob/gh-pages/pyguide.md}{Google Python Style Guide}
for our coding style. It encompasses all the necessary naming conventions and standards required for the project development.
\section{Project Schedule}
Please see the following pages for the project schedule in the form of a gantt chart.
\includepdf[page=-]{../../ProjectSchedule/Team_Gantt}
\section{Project Review}
\end{document}
\ No newline at end of file
File added
\documentclass{article}
\usepackage{tabularx}
\usepackage{booktabs}
\title{SE 3XA3: Problem Statement\\ \textbf{Snake Game}}
\author{Team \#30, VUA30
\\ Usman Irfan - irfanm7
\\ Andy Hameed - hameea1
\\ Vaibhav Chadha - chadhav
}
\date{2018-09-21}
\usepackage[left=2cm, right=5cm, top=2cm]{geometry}
\begin{document}
\begin{table}[hp]
\caption{Revision History} \label{TblRevisionHistory}
\begin{tabularx}{\textwidth}{llX}
\toprule
\textbf{Date} & \textbf{Developer(s)} & \textbf{Change}\\
\midrule
2018-09-20 & Vaibhav & Made the LaTeX file and wrote the section with what the Problem is\\
2018-09-20 & Usman & Added the Importance of Problem section while formatting the LaTeX\\
2018-09-21 & Andy Hameed & Formatted LaTeX file and added Context section, giving the final editing to the document\\
2018-10-09 & Andy Hameed & Edited doc to reflect web app to desktop app decision change\\
\bottomrule
\end{tabularx}
\end{table}
\newpage
\maketitle
\subsection*{The Problem}
Almost everyone nowadays relies on a computer as a multipurpose tool for research, video streaming, gaming and many other tasks. With the emergence of fast computing, gaming has become a popular pastime activity and a source of entertainment for many. However, not everyone has a device powerful enough to support extensive game applications. A simple, memory effecient application of the Snake game allows it to be accessible for gamers without the need for extensive hardware or a high-performance computer. Our team, VUA30, will be creating a desktop application for the well-known Snake game with new enhancements and features. This competitive and addictive game can allow the user to play at their own pace and challenge their own high score.
\subsection*{Importance of the Problem}
Buying a computing device with high storage and faster performance can be out of budget. Complicated software covers up all the storage and the user is bound to use these applications as opposed to downloading other software. The importance of the redevelopment of The Snake is to save computing devices' personal storage and allow the user to play a game 24/7 with strong performance, even offline. Creating a desktop version of the snake game can fit into the category of downloadable calssical games such as the solitaire suite. The recreation of this game will allow the user to enjoy the classical game anytime and anywhere as long as they have installed the application. Improving aspects such as graphics and custom speed will also make the game more interesting. We would like to add more features to the game to make it more customizable and help people enjoy the classical game in an exciting and new way.
\subsection*{Context}
The stakeholders are mainly the gaming audience, the older generation of game enthusiasts, youth and teens. Some other stakeholders that Although the game can be played by anyone, it is targeted towards the audience mentioned above who are most invested in the game. The environment is native app development using Python. This provides provides less flexibility than web API's but there still exists many useful libraries which can be used such as Pygame for example.
\end{document}
# Development Plan
# Problem Statement
The folders and files for this folder are as follows:
......
# Software Requirements Specification
The folders and files for this folder are as follows:
Describe ...
File added
This diff is collapsed.
#standard set up
import pygame
from random import randint
pygame.init()
#setting width and height of window
screen_x = 500
screen_y = 500
win = pygame.display.set_mode((screen_x,screen_y))
pygame.display.set_caption("My Game")
white = (255,255,255)
black = (0,0,0)
x = randint(40,400)
y = randint(40,400)
width = 20
height = 20
vel = 10
speed = 40
# 0 - (- direction) , 1 - (+ direction)
direction = 0
# 0 - x-axis , 1 - y-axis
axis = 0
run = True
while run:
pygame.time.delay(speed) #create a delay to prevent any unwanted behaviour
#events are anything that happens from the user
#we loop through the list of events that happen by the user's actions
for event in pygame.event.get():
if event.type == pygame.QUIT:
run = False
#Each event type has an integer assigned to it. KEYDOWN has the code 2
if event.type == pygame.KEYDOWN:
if (event.key == pygame.K_LEFT):
axis = 0;direction=-1
if (event.key == pygame.K_RIGHT):
axis = 0;direction=1
if (event.key == pygame.K_UP):
axis = 1;direction=-1
if (event.key == pygame.K_DOWN):
axis = 1;direction=1
#Snake moving depending on axis and direction
if (axis):
y += vel*direction
else:
x += vel*direction
if x < 0:
#x = 0
x = screen_x - height
if y < 0:
#y = 0
y = screen_y - width
if y > screen_y - width:
#y = 500 - width
y = 0
if x > screen_x - height:
#x = 500 - height
x = 0
win.fill(white)
#all colors are defined in RGB with Pygame
pygame.draw.rect(win,(255,0,0), (x,y,width, height))
#we have to update the display to see the drawing of our object. Since it does
#not automatically update
pygame.display.update()
#Quit the game
pygame.quit()
#importing necessary libraries
import pygame, sys
#a function made to execute other files from the system
def runfile(runfilename):
with open(runfilename,"r") as rnf:
exec(rnf.read())
pygame.init()
#while loop required to always refresh the page
while True:
game = pygame.display.set_mode((800, 610))
game.fill([213, 219, 219])
mousepos = pygame.mouse.get_pos() #checking mouse position
mouseclick = pygame.mouse.get_pressed()#checking mouse pressed
pygame.display.set_caption("Lets Play")
title_font = pygame.font.SysFont("monospace", 80)
#Adding the title
gamename = title_font.render('SNAKE GAME', True, (255, 0, 0))
game.blit(gamename,(150,80))
#Adding the play game button
if (270 <= mousepos[0] <= 270+250 and 505 <= mousepos[1] <= 555 ):
#checks if the mouse is hovering over the button
pygame.draw.rect(game,[100,100,100], [270,505,250,50], 0)
#checking if the button is clicked
if mouseclick[0] == 1:
runfile('Snake_2.o_Demo.py')
else:
pygame.draw.rect(game,[180,180,180], [270,505,250,50], 0)
playgame_font = pygame.font.SysFont("comicsansms", 40)
gamebutton = playgame_font.render('GAME TIME', True, (0, 0, 200))
game.blit(gamebutton,(275,500))
#Taking user name
UserName = playgame_font.render('NAME:', True, (0, 250, 0))
game.blit(UserName,(50,200))
#Asking user for theme
ThemeOption = playgame_font.render('THEMES:', True, (0, 200, 0))
game.blit(ThemeOption,(50,300))
#Asking user for speed
SpeedOption = playgame_font.render('SPEED:', True, (0, 150, 0))
game.blit(SpeedOption,(50,400))
#If user wants to quit
pygame.draw.rect(game,[180,180,180], [650,550,130,55], 0)
Quit = playgame_font.render('QUIT', True, (0, 0, 0))
game.blit(Quit,(650,550))
if ( 650 <= mousepos[0] <= 650+130 and 550 <= mousepos[1] <= 550 +55):
#checks if the mouse is hovering over the button
#checking if the button is clicked
if mouseclick[0] == 1:
#print ("quiting")
#pygame.display.quit()
pygame.quit()
sys.exit()
pygame.display.update()