Skip to content

Commit

Permalink
Added 3nn3n-messivsronaldo (#2909)
Browse files Browse the repository at this point in the history
Co-authored-by: Laureline Paris <[email protected]>
  • Loading branch information
3nn3n and LaurelineP authored Jan 28, 2025
1 parent 56b006c commit 95b7413
Show file tree
Hide file tree
Showing 3 changed files with 120 additions and 0 deletions.
21 changes: 21 additions & 0 deletions Art/3nn3n-messivsronaldo/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Football Animation</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<div class="pitch">
<div class="goal left"></div>
<div class="goal right"></div>
<div class="ball"></div>
<div class="player player1"></div>
<div class="player player2"></div>
<div class="player player3"></div>
<div class="player player4"></div>

</div>
</body>
</html>
4 changes: 4 additions & 0 deletions Art/3nn3n-messivsronaldo/meta.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"artName": "messivsronaldo",
"githubHandle": "3nn3n"
}
95 changes: 95 additions & 0 deletions Art/3nn3n-messivsronaldo/styles.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
body {
display: flex;
justify-content: center;
align-items: center;
margin: 0;
height: 100vh;
background-color: #aad751;
overflow: hidden;
}

.pitch {
width: 90%;
height: 60%;
background-color: #6ab04c;
border: 5px solid white;
position: relative;
}

.goal {
width: 10px;
height: 100px;
background-color: white;
position: absolute;
top: 50%;
transform: translateY(-50%);
}

.goal.left {
left: 0;
}

.goal.right {
right: 0;
}


.ball {
width: 20px;
height: 20px;
background-color: white;
border: 2px solid black;
border-radius: 50%;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
animation: ballMove 6s infinite ease-in-out;
}

.player {
width: 30px;
height: 30px;
background-color: #3498db;
border-radius: 50%;
position: absolute;
}

.player1 {
top: 40%;
left: 30%;
}

.player2 {
top: 60%;
left: 70%;
}

.player3 {
top: 40%;
left: 90%;
}

.player4 {
top: 40%;
left: 50%;
}

@keyframes ballMove {
0%, 100% {
top: 50%;
left: 50%;
}
25% {
top: 40%;
left: 30%;
}
50% {
top: 60%;
left: 70%;
}
75% {
top: 50%;
left: 90%;
}
}

0 comments on commit 95b7413

Please sign in to comment.