-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
141 lines (126 loc) · 4.3 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Server Of Duplicake</title>
<script>
async function updatePlayerCount() {
try {
const response = await fetch('https://api.mcsrvstat.us/2/147.185.221.194:40498');
const data = await response.json();
const playerCountElement = document.getElementById('player-count');
const serverStatusElement = document.getElementById('server-status');
if (data.online) {
const currentPlayers = data.players?.online || 0;
const maxPlayers = data.players?.max || 0;
playerCountElement.textContent = `Players Online: ${currentPlayers}/${maxPlayers}`;
serverStatusElement.className = 'server-status online';
serverStatusElement.textContent = 'Server Status: Online';
} else {
playerCountElement.textContent = 'Players Online: 0/0';
serverStatusElement.className = 'server-status offline';
serverStatusElement.textContent = 'Server Status: Offline';
}
} catch (error) {
console.error('Error fetching server status:', error);
}
}
setInterval(updatePlayerCount, 30000);
document.addEventListener('DOMContentLoaded', updatePlayerCount);
</script>
<style>
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Arial', sans-serif;
}
body {
background-color: #2c2f33;
color: white;
line-height: 1.6;
text-align: center;
}
header {
background: linear-gradient(135deg, #23272a 0%, #43b581 100%);
padding: 1.5rem 2rem;
display: flex;
align-items: center;
gap: 1rem;
box-shadow: 0 2px 15px rgba(0, 0, 0, 0.3);
}
.branding {
display: flex;
align-items: center;
gap: 1rem;
}
.logo {
height: 50px;
width: auto;
border-radius: 8px;
}
.server-name {
font-size: 2rem;
font-weight: bold;
color: white;
}
.hero {
text-align: center;
padding: 4rem 2rem;
}
.download-btn {
display: inline-block;
padding: 1.2rem 2.5rem;
font-size: 1.6rem;
background: #7289da;
color: white;
text-decoration: none;
border-radius: 12px;
margin-top: 2rem;
font-weight: bold;
box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
transition: background 0.3s ease;
}
.download-btn:hover {
background: #5b6eae;
}
.status-container {
margin-top: 2rem;
font-size: 1.8rem;
font-weight: bold;
}
.server-status, .player-count {
font-size: 1.8rem;
margin-top: 1rem;
}
footer {
margin-top: 4rem;
padding: 2rem;
background: #23272a;
font-size: 1.2rem;
}
</style>
</head>
<body>
<header>
<div class="branding">
<img src="logo.png" alt="Server Logo" class="logo">
<div class="server-name">Server of Duplicake</div>
</div>
</header>
<section class="hero">
<h1>Play on my Minecraft Server!</h1>
<p>Have fun on my Minecraft Server using Dupliclient!</p>
<a href="https://github.com/SomeRandomCpu/minecraft-website-page/raw/refs/heads/main/setup.exe" class="download-btn">Download Client</a>
<div class="status-container">
<div id="server-status" class="server-status online">Server Status: Online</div>
<div id="player-count" class="player-count">Players Online: 0/0</div>
</div>
</section>
<footer>
<p>Server IP: 147.185.221.194:40498</p>
<p>© 2025 Duplicake. All rights reserved.</p>
</footer>
</body>
</html>