🎮 Snake Game
0
分數
0
最高分
3
長度
Classic Snake: steer with the arrow keys to eat and grow while avoiding collisions, with a high-score record. No network connection needed.
📚 深度解析:貪吃蛇
💡 常見使用場景
- 休閒放鬆:方向鍵控制蛇吃食增長。
- 反應挑戰:避免撞牆或撞自身。
- 記錄最高:本地儲存最高分。
方法(成長規則)
蛇頭吃到食物則體長 +1、分數 +10;撞牆或撞到自身身體則結束。經典 20×20 網格,方向鍵控制。
算例(演示)
吃 1 個食物 +1 長 +10 分;蛇長 10 時分數 100;撞牆立即結束。高手靠「繞圈吃、留轉彎空間」避免自撞,衝擊高分。
❓ 常見問題(FAQ)
- 怎麼拿高分?
- 保持蛇身緊湊繞圈、預留掉頭空間,別貪直線衝牆。
- 有邊界嗎?
- 有。撞牆或咬到自身即死;部分版本「穿牆」為特殊模式。
Formula & Standard References
| Item | Formula / Note | Source / Standard |
|---|---|---|
| Grid movement | the snake steps on a grid and turns are constrained by direction | Game programming practice |
| Self collision | the run ends when the new head meets any body segment | Game programming practice |
| Speed curve | shorter step intervals as the snake grows raise difficulty | Game programming practice |
⚠️ 使用說明與注意事項
- 本工具純前端執行,資料不會上傳到伺服器
- 建議在主流瀏覽器(Chrome/Safari/Firefox/Edge)中使用
- 計算結果僅供參考,請以實際應用場景為準