Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fead/add snake gun water game #4840

Merged
merged 6 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions Games/Snake_Gun_Water/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# 🎮 Snake Water and Gun Game

## About the Game
This is a game. You have to choose any option from, snake🐍 or water🌊 or gun🔫. Then it will compete with the system's choice. After that, the result will be shown as who wins and the winner will get 10 points. It will continue till the number of rounds you have selected. Finally, points will be calculated. Who gets the highest point will be considered the winner🎐.

## Rules
- Snake vs Water => Snake wins ( Since it can swim in the water )
- Water vs Gun => Water wins ( Since the gun will lose in water )
- Gun vs Snake => Gun wins ( Since the snake will die from fire )
- If both are equal then match draw. both will get 5 points.


1 change: 1 addition & 0 deletions Games/Snake_Gun_Water/composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
85 changes: 85 additions & 0 deletions Games/Snake_Gun_Water/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
<!DOCTYPE html>
<html lang="en">

<head>
<meta charset="UTF-8">
<meta id="viewport" content="width=device-width, initial-scale=1.0">
<title>Snake Water and Gun Game</title>
<link rel="stylesheet" href="static/css/swg.css">
<link href="https://fonts.googleapis.com/css2?family=Fredoka+One&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=Lobster&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=Baloo+2:wght@700&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=Roboto+Slab:wght@800&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=Acme&display=swap" rel="stylesheet">
</head>

<body onload="sign()">
<div id="entry"></div>
<div id="game">
<div id="scoreBoard">
<div class="board">
<div>System</div>
<div id="systemScore">00</div>
</div>
<div class="board">
<div>Round</div>
<div id="rounds">00/00</div>
</div>
<div class="board">
<div id="userName">You</div>
<div id="userScore">00</div>
</div>
</div>
<div id="area">
<div id="warArea">
<div id="fight"></div>
<div id="msg">

</div>
<div id="result">

</div>
</div>
<div id="army">
<div class="coin">
<div id="system"></div>
<p>system</p>
</div>
<div id="state">

</div>
<div class="coin">
<div id="user"></div>
<p>You </p>
</div>
</div>
</div>
<p id="question">What you want to make ?</p>
<div id="home">
<div id="1" class="weapon">
<img src="static/images/snake.jpg" alt="snake">
<p>Snake</p>
</div>
<div id="2" class="weapon">
<img src="static/images/water.jpg" alt="water">
<p>Water</p>
</div>
<div id="3" class="weapon">
<img src="static/images/gun.jpg" alt="gun">
<p>Gun</p>
</div>
</div>
</div>
<div id="end"></div>

<div id="info" class="flex">
<h1>About Game</h1>
<P>In this game you have to choose between snake,water and gun. Snake kills the water, water kills the gun and gun kills the snake. In this game winner will get 1 point. if both choose the same then both will get 1 points. in total of 10 rounds who
gets the highest points will be considered as winner.</br> <br> let's check how lucky you are, have fun. <br><br> Your feedback is vaued for us to improve and develop more better applications.</P>
</div>
</div>

<script src="static/js/swg.js"></script>
</body>

</html>
1 change: 1 addition & 0 deletions Games/Snake_Gun_Water/index.php
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<?php include_once("index.html"); ?>
266 changes: 266 additions & 0 deletions Games/Snake_Gun_Water/static/css/swg.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,266 @@
* {
padding: 0;
margin: 0;
box-sizing: border-box;
}

.flex {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}

#scoreBoard {
display: flex;
height: 10vh;
padding: 5px;
background-color: rgb(185, 182, 1);
text-align: center;
justify-content: center;
}

.board p {
margin: 0px;
padding: 0;
width: 100%;
height: max-content;
text-align: center;
}

.board {
width: 80%;
overflow: auto;
height: 8vh;
align-items: center;
justify-content: center;
background-color: white;
font-size: 3vh;
margin: 10px;
border-radius: 30px;
}


/* -----END of score board section ----- */

#area {
padding: 5px;
border: 10px solid maroon;
background-color: rgb(255, 254, 254);
}

#warArea {
align-items: center;
background-color: whitesmoke;
height: 45vh;
}

#msg {
justify-content: center;
}

#msg p {
border: 4px solid black;
background-color: white;
border-radius: 80px 80px 0 80px;
padding: 25px;
margin: 40px;
text-align: center;
font-size: 4vh;
}

#result {
box-sizing: content-box;
margin: 30px;
background-color: white;
font-size: 7vh;
/* height: 10vh; */
text-align: center;
justify-content: center;
}

#fight {
height: 15vh;
width: 20vh;
background-color: red;
margin: 10px auto;
border-radius: 24px;
}

#fight img {
height: 15vh;
width: 20vh;
}


/* selected options section */

#army {
height: 15vh;
margin: 10px auto;
width: 90%;
display: flex;
align-items: center;
justify-content: center;
}

#army p {
text-decoration: black;
text-align: center;
font-size: 2vh;
padding: 10px;
}

.coin {
background-color: white;
border-radius: 28px;
width: 16vh;
height: 10vh;
margin: auto;
}

<<<<<<< HEAD
#system,#user {
<<<<<<< HEAD

height: 10vh;
=======
#system {
height: 8vh;
>>>>>>> 3f916de92c641848b2fb326a1837ba10355f44c1
width: 15vh;
margin: auto;
border-radius: 23px;
border: 8px solid gold;
}

<<<<<<< HEAD


=======
height: 8vh;
width: 15vh;
margin: auto;
border-radius: 18px;
border: 4px solid gold;
}
>>>>>>> b2903102e180abdb73172f9d9ba5f0c3611386a6
=======
#user {
border-radius: 23px;
border: 8px solid gold;
height: 8vh;
margin: auto;
width: 15vh;
}
>>>>>>> 3f916de92c641848b2fb326a1837ba10355f44c1

#state {
margin: auto;
font-size: 1rem;
}

#home {
display: flex;
background-color: yellow;
border: 10px solid yellowgreen;
padding: 5px;
justify-content: center;
align-items: center;
}

#question {
border: 10px solid yellowgreen;
border-bottom: none;
background-color: white;
font-size: 3em;
height: max-content;
color: red;
padding: 4px;
overflow: auto;
/* margin: 0; */
text-align: center;
}


/* user planel */
#user img,#system img {
height: 7vh;
width: 14vh;
margin: auto;
border-radius: 18px;

}

.weapon {
border: 10px solid white;
border-radius: 25px;
background-color: white;
font-size: 2.5vh;
margin: 20px;
height: 12vh;
width: 20vh;
text-align: center;
}
.weapon img{
height: 7vh;
width: 14;
}

#info {
height: 80vh;
justify-content: flex-start;
padding: 12px;
margin: 5vh auto;
}

#info h1 {
font-size: 6em;
margin: 1vh;
font-family: 'Courier New', Courier, monospace;
}

#info p {
text-indent: 100px;
font-size: 3vh;
margin: 1vh 3vh;
text-align: justify;
font-family: cursive;
}

#devinfo {
border: 1px solid black;
border-radius: 23px;
height: max-content;
margin: 5vh 1vh 2vh 1vh;
}

#devinfo p {
text-align: center;
font-size: 2vh;
margin: 1vh;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

#devinfo img {
height: 4vh;
width: 4vh;
border-radius: 8px;
padding: 2px;
}

#devinfo a {
font-family: cursive;
}

#devinfo span {
padding: 1vh;
margin-bottom: 1vh;
}

@media(min-width:1024px) {
#abs {
left: 50%;
margin-left: -50vh;
}
}
Binary file added Games/Snake_Gun_Water/static/images/cong1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/copy.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/draw.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/email.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/facebook.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/gun.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/instagram.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/linkedin.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/snake.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/water.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added Games/Snake_Gun_Water/static/images/whatsapp.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading