cutechicken commited on
Commit
aba7aeb
·
verified ·
1 Parent(s): 4b6e2d3

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +155 -121
index.html CHANGED
@@ -69,142 +69,178 @@
69
  position: relative;
70
  width: 100vw;
71
  height: 100vh;
72
- cursor: crosshair;
73
  }
74
 
75
- #info {
76
- position: absolute;
77
- top: 10px;
78
- left: 10px;
79
- color: #0f0;
80
- background: rgba(0,20,0,0.7);
81
- padding: 10px;
82
- font-size: 14px;
83
- z-index: 1001;
84
- border: 1px solid #0f0;
85
- border-radius: 5px;
86
- user-select: none;
87
  }
88
 
89
- /* HUD 크로스헤어 스타일 */
90
  #hudCrosshair {
91
  position: fixed;
92
  top: 50%;
93
  left: 50%;
94
  transform: translate(-50%, -50%);
95
- width: 300px;
96
- height: 300px;
97
- pointer-events: none;
98
- z-index: 1001;
99
  }
100
 
101
- .hud-circle {
 
102
  position: absolute;
103
  top: 50%;
104
  left: 50%;
105
  transform: translate(-50%, -50%);
106
- width: 200px;
107
- height: 200px;
108
- border: 2px solid rgba(0, 255, 0, 0.3);
109
  border-radius: 50%;
110
  }
111
 
112
- .hud-center {
 
113
  position: absolute;
114
  top: 50%;
115
  left: 50%;
116
  transform: translate(-50%, -50%);
117
- width: 10px;
118
- height: 10px;
119
  background: #00ff00;
120
  border-radius: 50%;
121
- box-shadow: 0 0 10px #00ff00;
122
  }
123
 
124
- .hud-horizon {
 
125
  position: absolute;
126
  top: 50%;
127
- left: 0;
128
- right: 0;
129
- height: 2px;
130
- background: rgba(0, 255, 0, 0.5);
131
  }
132
 
 
133
  .hud-pitch-ladder {
134
  position: absolute;
135
  top: 50%;
136
  left: 50%;
137
  transform: translate(-50%, -50%);
138
- width: 150px;
139
- height: 200px;
140
  }
141
 
142
  .pitch-line {
143
  position: absolute;
144
  width: 100%;
 
 
 
 
 
 
 
145
  height: 1px;
146
- background: rgba(0, 255, 0, 0.3);
147
- left: 0;
148
  }
149
 
150
- .pitch-line.major {
151
- background: rgba(0, 255, 0, 0.6);
152
- height: 2px;
 
 
153
  }
154
 
155
- #pitchIndicator {
 
156
  position: absolute;
157
- top: 50%;
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
158
  left: 50%;
159
- transform: translate(-50%, -50%);
160
- width: 80px;
161
- height: 2px;
162
- background: #00ff00;
163
- transition: transform 0.1s ease;
164
  }
165
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
166
  .target-marker {
167
  position: absolute;
168
- width: 40px;
169
- height: 40px;
170
- border: 2px solid rgba(255, 255, 0, 0.8);
171
- border-radius: 50%;
172
  transform: translate(-50%, -50%);
173
- pointer-events: none;
174
  }
175
 
176
- .target-marker.locked {
177
- border-color: rgba(255, 0, 0, 1);
178
- animation: pulse 0.5s infinite;
179
  }
180
 
181
- @keyframes pulse {
182
- 0%, 100% { transform: translate(-50%, -50%) scale(1); }
183
- 50% { transform: translate(-50%, -50%) scale(1.1); }
184
  }
185
 
186
- .target-distance {
187
  position: absolute;
188
- color: #00ff00;
189
- font-size: 12px;
190
- transform: translate(-50%, -50%);
191
- text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.8);
192
- pointer-events: none;
193
  }
194
 
195
- #targetMarkers {
196
- position: fixed;
197
- top: 0;
198
- left: 0;
199
- width: 100%;
200
- height: 100%;
201
- pointer-events: none;
202
- z-index: 1000;
203
  }
204
 
205
- /* 기존 크로스헤어 숨김 */
206
- #crosshair {
207
- display: none;
 
 
 
 
 
 
208
  }
209
 
210
  #healthBar {
@@ -227,20 +263,6 @@
227
  transition: width 0.3s;
228
  }
229
 
230
- #ammo {
231
- position: absolute;
232
- bottom: 20px;
233
- right: 20px;
234
- color: #0f0;
235
- background: rgba(0,20,0,0.7);
236
- padding: 10px;
237
- font-size: 20px;
238
- z-index: 1001;
239
- border: 1px solid #0f0;
240
- border-radius: 5px;
241
- }
242
-
243
-
244
  #gameTitle {
245
  position: absolute;
246
  top: 60px;
@@ -256,6 +278,7 @@
256
  text-transform: uppercase;
257
  letter-spacing: 2px;
258
  }
 
259
  #ammoDisplay {
260
  position: absolute;
261
  bottom: 20px;
@@ -379,22 +402,10 @@
379
  .start-button:hover {
380
  transform: scale(1.1);
381
  }
382
-
383
- #minimap {
384
- position: absolute;
385
- bottom: 20px;
386
- right: 20px;
387
- width: 200px;
388
- height: 200px;
389
- background: rgba(0,20,0,0.7);
390
- border: 2px solid #0f0;
391
- border-radius: 5px;
392
- z-index: 1001;
393
- }
394
  </style>
395
  </head>
396
  <body>
397
- <!-- 로딩 화면 (처음에 표시됨) -->
398
  <div id="loading">
399
  <div class="loading-spinner"></div>
400
  <div class="loading-text">Loading Fighter Resources...</div>
@@ -405,7 +416,7 @@
405
  </div>
406
  </div>
407
 
408
- <!-- 게임 시작 화면 (로딩 완료 후 표시됨) -->
409
  <div class="start-screen" id="startScreen">
410
  <h1 style="color: #0f0; font-size: 48px; margin-bottom: 20px;">JET FIGHT SIMULATER</h1>
411
  <button class="start-button" onclick="startGame()">Start Game</button>
@@ -415,6 +426,7 @@
415
  <p>A/D - Rudder Control</p>
416
  <p>Mouse - Aircraft Control</p>
417
  <p>Left Click - Fire</p>
 
418
  </div>
419
  </div>
420
 
@@ -427,29 +439,51 @@
427
  <div id="time">Time: 180s</div>
428
  </div>
429
 
430
- <!-- HUD 크로스헤어 -->
431
- <div id="hudCrosshair">
432
- <div class="hud-circle"></div>
433
- <div class="hud-center"></div>
434
- <div class="hud-horizon"></div>
435
- <div class="hud-pitch-ladder">
436
- <div class="pitch-line" style="top: 20%;"></div>
437
- <div class="pitch-line major" style="top: 35%;"></div>
438
- <div class="pitch-line" style="top: 50%;"></div>
439
- <div class="pitch-line major" style="top: 65%;"></div>
440
- <div class="pitch-line" style="top: 80%;"></div>
441
- <div id="pitchIndicator"></div>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
442
  </div>
 
 
 
 
 
 
 
 
 
 
 
443
  </div>
444
 
445
- <!-- 타겟 마커 레이어 -->
446
- <div id="targetMarkers"></div>
447
-
448
- <!-- 기존 크로스헤어 (숨김) -->
449
- <div id="crosshair"></div>
450
- <div id="detected" style="position: absolute; top: 55%; left: 50%; transform: translate(-50%, -50%); color: red; font-size: 16px; display: none;">DETECTED</div>
451
- <div id="enemyLabels"></div>
452
-
453
  <!-- 체력바 -->
454
  <div id="healthBar">
455
  <div id="health"></div>
 
69
  position: relative;
70
  width: 100vw;
71
  height: 100vh;
72
+ cursor: none;
73
  }
74
 
75
+ /* HUD 전체 컨테이너 */
76
+ #hudContainer {
77
+ position: fixed;
78
+ top: 0;
79
+ left: 0;
80
+ width: 100%;
81
+ height: 100%;
82
+ pointer-events: none;
83
+ z-index: 1000;
 
 
 
84
  }
85
 
86
+ /* 중앙 HUD */
87
  #hudCrosshair {
88
  position: fixed;
89
  top: 50%;
90
  left: 50%;
91
  transform: translate(-50%, -50%);
92
+ width: 400px;
93
+ height: 400px;
 
 
94
  }
95
 
96
+ /* 조준 원 */
97
+ .hud-aiming-circle {
98
  position: absolute;
99
  top: 50%;
100
  left: 50%;
101
  transform: translate(-50%, -50%);
102
+ width: 150px;
103
+ height: 150px;
104
+ border: 2px solid rgba(0, 255, 0, 0.5);
105
  border-radius: 50%;
106
  }
107
 
108
+ /* 중앙점 */
109
+ .hud-center-dot {
110
  position: absolute;
111
  top: 50%;
112
  left: 50%;
113
  transform: translate(-50%, -50%);
114
+ width: 4px;
115
+ height: 4px;
116
  background: #00ff00;
117
  border-radius: 50%;
 
118
  }
119
 
120
+ /* 수평선 */
121
+ .hud-horizon-line {
122
  position: absolute;
123
  top: 50%;
124
+ left: 20%;
125
+ right: 20%;
126
+ height: 1px;
127
+ background: rgba(0, 255, 0, 0.4);
128
  }
129
 
130
+ /* 피치 래더 */
131
  .hud-pitch-ladder {
132
  position: absolute;
133
  top: 50%;
134
  left: 50%;
135
  transform: translate(-50%, -50%);
136
+ width: 200px;
137
+ height: 300px;
138
  }
139
 
140
  .pitch-line {
141
  position: absolute;
142
  width: 100%;
143
+ display: flex;
144
+ align-items: center;
145
+ justify-content: center;
146
+ }
147
+
148
+ .pitch-line-bar {
149
+ width: 60px;
150
  height: 1px;
151
+ background: rgba(0, 255, 0, 0.4);
 
152
  }
153
 
154
+ .pitch-line-text {
155
+ position: absolute;
156
+ color: rgba(0, 255, 0, 0.6);
157
+ font-size: 10px;
158
+ left: -25px;
159
  }
160
 
161
+ /* 비행 정보 표시 */
162
+ .hud-info {
163
  position: absolute;
164
+ color: #00ff00;
165
+ font-size: 12px;
166
+ font-family: 'Courier New', monospace;
167
+ text-shadow: 0 0 3px rgba(0, 0, 0, 0.8);
168
+ }
169
+
170
+ #hudSpeed {
171
+ left: 20px;
172
+ top: 45%;
173
+ }
174
+
175
+ #hudAltitude {
176
+ right: 20px;
177
+ top: 45%;
178
+ }
179
+
180
+ #hudHeading {
181
+ top: 20px;
182
  left: 50%;
183
+ transform: translateX(-50%);
 
 
 
 
184
  }
185
 
186
+ #hudPitch {
187
+ left: 20px;
188
+ bottom: 30%;
189
+ }
190
+
191
+ #hudRoll {
192
+ right: 20px;
193
+ bottom: 30%;
194
+ }
195
+
196
+ #hudTurnRate {
197
+ left: 50%;
198
+ bottom: 20px;
199
+ transform: translateX(-50%);
200
+ }
201
+
202
+ /* 타겟 마커 */
203
  .target-marker {
204
  position: absolute;
205
+ width: 30px;
206
+ height: 30px;
207
+ border: 2px solid transparent;
 
208
  transform: translate(-50%, -50%);
 
209
  }
210
 
211
+ .target-marker.in-crosshair {
212
+ border: 2px solid #ffff00;
213
+ animation: target-pulse 0.5s infinite;
214
  }
215
 
216
+ .target-marker.locked {
217
+ border: 2px solid #ff0000;
218
+ box-shadow: 0 0 10px #ff0000;
219
  }
220
 
221
+ .target-marker .target-box {
222
  position: absolute;
223
+ top: -5px;
224
+ left: -5px;
225
+ right: -5px;
226
+ bottom: -5px;
227
+ border: 1px solid currentColor;
228
  }
229
 
230
+ @keyframes target-pulse {
231
+ 0%, 100% { opacity: 1; }
232
+ 50% { opacity: 0.5; }
 
 
 
 
 
233
  }
234
 
235
+ .target-info {
236
+ position: absolute;
237
+ top: 100%;
238
+ left: 50%;
239
+ transform: translateX(-50%);
240
+ color: #00ff00;
241
+ font-size: 10px;
242
+ white-space: nowrap;
243
+ margin-top: 5px;
244
  }
245
 
246
  #healthBar {
 
263
  transition: width 0.3s;
264
  }
265
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
266
  #gameTitle {
267
  position: absolute;
268
  top: 60px;
 
278
  text-transform: uppercase;
279
  letter-spacing: 2px;
280
  }
281
+
282
  #ammoDisplay {
283
  position: absolute;
284
  bottom: 20px;
 
402
  .start-button:hover {
403
  transform: scale(1.1);
404
  }
 
 
 
 
 
 
 
 
 
 
 
 
405
  </style>
406
  </head>
407
  <body>
408
+ <!-- 로딩 화면 -->
409
  <div id="loading">
410
  <div class="loading-spinner"></div>
411
  <div class="loading-text">Loading Fighter Resources...</div>
 
416
  </div>
417
  </div>
418
 
419
+ <!-- 게임 시작 화면 -->
420
  <div class="start-screen" id="startScreen">
421
  <h1 style="color: #0f0; font-size: 48px; margin-bottom: 20px;">JET FIGHT SIMULATER</h1>
422
  <button class="start-button" onclick="startGame()">Start Game</button>
 
426
  <p>A/D - Rudder Control</p>
427
  <p>Mouse - Aircraft Control</p>
428
  <p>Left Click - Fire</p>
429
+ <p>F - Escape Stall</p>
430
  </div>
431
  </div>
432
 
 
439
  <div id="time">Time: 180s</div>
440
  </div>
441
 
442
+ <!-- HUD 컨테이너 -->
443
+ <div id="hudContainer">
444
+ <!-- 중앙 HUD -->
445
+ <div id="hudCrosshair">
446
+ <div class="hud-aiming-circle"></div>
447
+ <div class="hud-center-dot"></div>
448
+ <div class="hud-horizon-line"></div>
449
+
450
+ <!-- 피치 래더 -->
451
+ <div class="hud-pitch-ladder" id="pitchLadder">
452
+ <div class="pitch-line" style="top: 20%;">
453
+ <div class="pitch-line-bar"></div>
454
+ <span class="pitch-line-text">20</span>
455
+ </div>
456
+ <div class="pitch-line" style="top: 35%;">
457
+ <div class="pitch-line-bar"></div>
458
+ <span class="pitch-line-text">10</span>
459
+ </div>
460
+ <div class="pitch-line" style="top: 50%;">
461
+ <div class="pitch-line-bar" style="width: 100px;"></div>
462
+ <span class="pitch-line-text">0</span>
463
+ </div>
464
+ <div class="pitch-line" style="top: 65%;">
465
+ <div class="pitch-line-bar"></div>
466
+ <span class="pitch-line-text">-10</span>
467
+ </div>
468
+ <div class="pitch-line" style="top: 80%;">
469
+ <div class="pitch-line-bar"></div>
470
+ <span class="pitch-line-text">-20</span>
471
+ </div>
472
+ </div>
473
  </div>
474
+
475
+ <!-- 비행 정보 -->
476
+ <div class="hud-info" id="hudSpeed">SPD: 0 KT</div>
477
+ <div class="hud-info" id="hudAltitude">ALT: 0 M</div>
478
+ <div class="hud-info" id="hudHeading">HDG: 000°</div>
479
+ <div class="hud-info" id="hudPitch">PITCH: 0°</div>
480
+ <div class="hud-info" id="hudRoll">ROLL: 0°</div>
481
+ <div class="hud-info" id="hudTurnRate">TURN: 0°/s</div>
482
+
483
+ <!-- 타겟 마커 레이어 -->
484
+ <div id="targetMarkers"></div>
485
  </div>
486
 
 
 
 
 
 
 
 
 
487
  <!-- 체력바 -->
488
  <div id="healthBar">
489
  <div id="health"></div>