Star Snake Game is a Unity mobile snake game. The deployed gameplay uses the continuous touch/cursor-driven snake flow in Scene_Play.
- Unity
6000.3.9f1 - Build scenes are configured in this order:
Assets/Scenes/Scene_Load.unityAssets/Scenes/Scene_Menu.unityAssets/Scenes/Scene_Play.unity
Manager_Mainowns scene navigation and resetsTime.timeScalewhen loading scenes.Manager_Menuhandles menu buttons, PlayFab login, and high-score display.Manager_Playowns score, restart, pause, game over, food spawning, and high-score submission.Object_Snake,Object_SnakeBody,Object_Food,Object_Wall, andInputAreaform the active gameplay loop.
SnakeBehaviour and FeedingMechanism are currently not referenced by the tracked scenes or prefabs. Treat them as experimental legacy scripts unless they are wired into a future scene intentionally.
- High-score submission now checks the existing PlayFab
HighScorestatistic before uploading, so a lower score is not submitted as the new high score from the client path. - Restart clears active food and bonus food before rebuilding the snake, preventing old scene objects from leaking into the next run.
- Game over is guarded against duplicate calls and stops snake audio consistently.
- Food spawning samples within configured spawn limits and rejects positions near existing 2D colliders, reducing spawns on the snake, walls, or other food.
- Input state is reset when the input area disables, which prevents stale touch/mouse state across scene transitions.
- Scene navigation uses named constants for the configured scene indexes.
Unity-generated folders are ignored in .gitignore, including Library/, Logs/, Temp/, UserSettings/, build output, IDE caches, generated solution files, and Unity recovery scenes.
If generated files are already tracked, remove them from the index without deleting local files:
git rm -r --cached Library Logs UserSettings
git rm --cached .vscode/settings.jsonThen review the remaining status before committing.
After opening Unity, verify these Inspector settings:
Manager_Playstill hasTrans_Items,Pannel_GameOver,Point_Origin,m_Snake,SpawnLimits,Prefabe_Food,Prefabe_BonusFood, andText_Scoreassigned.spawnClearRadiusonManager_Playis suitable for the board size and collider sizes.- PlayFab title settings still point to title ID
11C0BD. - The PlayFab
HighScorestatistic should also be configured server-side to aggregate by maximum value where possible.