Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
835ed54
import with latest version of unity
rob518183 Dec 30, 2025
538e733
Update .gitignore
rob518183 Dec 30, 2025
e507ea4
new input system, squashing warnings
rob518183 Dec 31, 2025
ff3969e
car still falls through the map, odd
rob518183 Jan 1, 2026
8406e83
gitignore
rob518183 Jan 1, 2026
c73e8b5
Delete Logs directory
rob518183 Jan 2, 2026
3716338
fixed car spawn, added music player
rob518183 Jan 2, 2026
7bd75c3
Revise README instructions and ZFS compatibility
rob518183 Jan 2, 2026
5feb3ca
Delete UserSettings directory
rob518183 Jan 3, 2026
1f44ec5
added basic projectile, trying to replicate original game
rob518183 Jan 6, 2026
6d5d745
Update mission file, enhance VR management, and upgrade package depen…
rob518183 May 19, 2026
da22ebf
Update README with todo section and loading instructions
rob518183 May 19, 2026
c24b2c6
Revise README with clearer instructions and todo formatting
rob518183 May 27, 2026
a063722
Update acknowledgement with archived blog link
rob518183 May 27, 2026
bfaf054
Refactor audio management system: introduce AudioCategory and AudioCa…
rob518183 May 27, 2026
317d6c0
Remove todo section from README
rob518183 Jun 1, 2026
56cd855
Enhance camera behavior and sky rendering: adjust SmoothFollow parame…
rob518183 Jun 6, 2026
7a6ad33
Merge branch 'master' of https://github.com/rob518183/Open76
rob518183 Jun 6, 2026
ddbec9b
Add CONTRIBUTING.md to guide new contributors on project involvement
rob518183 Jun 6, 2026
0d654f3
Implement gear toggling and enhance skid visuals: add gear control lo…
rob518183 Jun 18, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions .github/copilot-instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Open76 AI Coding Guidelines

## Project Overview
Open76 is a Unity engine reimplementation of Activision's Interstate '76 (1997), parsing original game assets and formats to recreate gameplay in modern Unity. Focuses on level rendering, car physics, and mission scripting via stack-based FSM.

## Architecture
- **Core Systems**: Singleton managers (CacheManager, VirtualFilesystem, LevelLoader) handle asset loading and world setup.
- **Asset Pipeline**: Custom parsers in `Assets/Scripts/System/Fileparsers/` reverse-engineer I76 formats (.geo meshes, .sdf scenes, .vcf cars, .msn missions).
- **Mission Logic**: FSMRunner executes stack machines with bytecode opcodes (PUSH, ACTION, JMP) for game logic.
- **File Access**: VirtualFilesystem prioritizes loose files (MISSIONS/, ADDON/) over compressed ZFS archive.

## Key Patterns
- Use singletons for global state (e.g., `CacheManager.Instance.ImportMesh()`).
- Cache parsed assets in dictionaries (meshes, materials, SDFs) to avoid redundant parsing.
- Handle palette-based textures: load .act palettes, apply to .vqm/.map textures.
- Instantiate prefabs from Resources/ (e.g., `Resources.Load<GameObject>("Prefabs/CarPrefab")`).
- FSM actions in FSMActionDelegator: implement entity-specific behaviors (cars, buildings).

## Conventions
- File parsers: Static `ReadX()` methods (e.g., `GeoParser.ReadGeoMesh(filename)`).
- Naming: PascalCase for classes/methods, camelCase for locals.
- Error handling: Debug.LogWarning for missing assets, exceptions for format errors.
- Coordinates: I76 uses custom units; convert via `/100.0f` for rotations, `*640` for terrain patches.

## Workflows
- **Level Loading**: Parse .msn via MsnMissionParser, create terrain patches, place objects from .sdf/.vcf.
- **Asset Import**: CacheManager.ImportGeo() for meshes, ImportSdf() for scenes, ImportVcf() for cars.
- **Debugging**: Use FSMRunner gizmos for path visualization; check VirtualFilesystem.FileExists() for asset presence.
- **Building**: Standard Unity build process; no custom scripts.

## Examples
- Load mesh: `GeoMeshCacheEntry entry = CacheManager.Instance.ImportMesh("car.geo", vtf, textureGroup);`
- Place object: `GameObject obj = CacheManager.Instance.ImportSdf("building.sdf", parent, pos, rot, canWreck, out sdf, out wrecked);`
- FSM action: Implement in FSMActionDelegator.DoAction() switch case for new actions.

Reference: [CacheManager.cs](C:/Users/Rob/Documents/Unity/Open76/Assets/Scripts/System/CacheManager.cs), [VirtualFilesystem.cs](C:/Users/Rob/Documents/Unity/Open76Assets/Scripts/System/VirtualFilesystem.cs), [LevelLoader.cs](C:/Users/Rob/Documents/Unity/Open76/Assets/Scripts/System/LevelLoader.cs)
107 changes: 98 additions & 9 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,14 +1,103 @@
Library/
# This .gitignore file should be placed at the root of your Unity project directory
#
# Get latest from https://github.com/github/gitignore/blob/main/Unity.gitignore
#
.utmp/
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/Logs
/[Uu]ser[Ss]ettings/
*.log

# By default unity supports Blender asset imports, *.blend1 blender files do not need to be commited to version control.
*.blend1
*.blend1.meta

# MemoryCaptures can get excessive in size.
# They also could contain extremely sensitive data
/[Mm]emoryCaptures/

# Recordings can get excessive in size
/[Rr]ecordings/

# Uncomment this line if you wish to ignore the asset store tools plugin
# /[Aa]ssets/AssetStoreTools*

# Autogenerated Jetbrains Rider plugin
/[Aa]ssets/Plugins/Editor/JetBrains*
# Jetbrains Rider personal-layer settings
*.DotSettings.user

# Visual Studio cache directory
.vs/
Temp/
obj/

# Gradle cache directory
.gradle/

# Autogenerated VS/MD/Consulo solution and project files
ExportedObj/
.consulo/
*.csproj
*.unityproj
*.sln
*.suo
*.tmp
*.user
*.userprefs
.vscode/

bin/
obj/
*.exe
*.pidb
*.booproj
*.svd
*.pdb
*.user
*.mdb
*.opendb
*.VC.db

# Unity3D generated meta files
*.pidb.meta
*.pdb.meta
*.mdb.meta

# Unity3D generated file on crash reports
sysinfo.txt

# Mono auto generated files
mono_crash.*

# Builds
*.apk
*.aab
*.unitypackage
*.unitypackage.meta
*.app

# Crashlytics generated file
crashlytics-build.properties

# TestRunner generated files
InitTestScene*.unity*

# Addressables default ignores, before user customizations
/ServerData
/[Aa]ssets/StreamingAssets/aa*
/[Aa]ssets/AddressableAssetsData/link.xml*
/[Aa]ssets/Addressables_Temp*
# By default, Addressables content builds will generate addressables_content_state.bin
# files in platform-specific subfolders, for example:
# /Assets/AddressableAssetsData/OSX/addressables_content_state.bin
/[Aa]ssets/AddressableAssetsData/*/*.bin*

# Visual Scripting auto-generated files
/[Aa]ssets/Unity.VisualScripting.Generated/VisualScripting.Flow/UnitOptions.db
/[Aa]ssets/Unity.VisualScripting.Generated/VisualScripting.Flow/UnitOptions.db.meta
/[Aa]ssets/Unity.VisualScripting.Generated/VisualScripting.Core/Property Providers
/[Aa]ssets/Unity.VisualScripting.Generated/VisualScripting.Core/Property Providers.meta

# Auto-generated scenes by play mode tests
/[Aa]ssets/[Ii]nit[Tt]est[Ss]cene*.unity*
/Logs
Logs/shadercompiler-UnityShaderCompiler.exe-0.log
UserSettings/Layouts/default-6000.dwlt
*.log
5 changes: 5 additions & 0 deletions .vscode/extensions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"recommendations": [
"visualstudiotoolsforunity.vstuc"
]
}
10 changes: 10 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "Attach to Unity",
"type": "vstuc",
"request": "attach"
}
]
}
71 changes: 71 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
{
"files.exclude": {
"**/.DS_Store": true,
"**/.git": true,
"**/.vs": true,
"**/.gitmodules": true,
"**/.vsconfig": true,
"**/*.booproj": true,
"**/*.pidb": true,
"**/*.suo": true,
"**/*.user": true,
"**/*.userprefs": true,
"**/*.unityproj": true,
"**/*.dll": true,
"**/*.exe": true,
"**/*.pdf": true,
"**/*.mid": true,
"**/*.midi": true,
"**/*.wav": true,
"**/*.gif": true,
"**/*.ico": true,
"**/*.jpg": true,
"**/*.jpeg": true,
"**/*.png": true,
"**/*.psd": true,
"**/*.tga": true,
"**/*.tif": true,
"**/*.tiff": true,
"**/*.3ds": true,
"**/*.3DS": true,
"**/*.fbx": true,
"**/*.FBX": true,
"**/*.lxo": true,
"**/*.LXO": true,
"**/*.ma": true,
"**/*.MA": true,
"**/*.obj": true,
"**/*.OBJ": true,
"**/*.asset": true,
"**/*.cubemap": true,
"**/*.flare": true,
"**/*.mat": true,
"**/*.meta": true,
"**/*.prefab": true,
"**/*.unity": true,
"build/": true,
"Build/": true,
"Library/": true,
"library/": true,
"obj/": true,
"Obj/": true,
"Logs/": true,
"logs/": true,
"ProjectSettings/": true,
"UserSettings/": true,
"temp/": true,
"Temp/": true
},
"files.associations": {
"*.asset": "yaml",
"*.meta": "yaml",
"*.prefab": "yaml",
"*.unity": "yaml",
},
"explorer.fileNesting.enabled": true,
"explorer.fileNesting.patterns": {
"*.sln": "*.csproj",
"*.slnx": "*.csproj"
},
"dotnet.defaultSolution": "Open76.slnx"
}
Loading