{"id":15883179,"url":"https://github.com/bfollington/differ-cs","last_synced_at":"2025-03-17T14:31:38.119Z","repository":{"id":40942806,"uuid":"55419291","full_name":"bfollington/differ-cs","owner":"bfollington","description":"A port of differ (open source SAT collision implementation) to C#","archived":false,"fork":false,"pushed_at":"2021-06-13T13:05:08.000Z","size":19,"stargazers_count":11,"open_issues_count":1,"forks_count":3,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-28T00:37:01.633Z","etag":null,"topics":["collision","csharp","sat","separating-axis-theorem","unity"],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bfollington.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-04-04T14:44:21.000Z","updated_at":"2023-08-01T10:59:17.000Z","dependencies_parsed_at":"2022-09-14T06:10:21.458Z","dependency_job_id":null,"html_url":"https://github.com/bfollington/differ-cs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bfollington%2Fdiffer-cs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bfollington%2Fdiffer-cs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bfollington%2Fdiffer-cs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bfollington%2Fdiffer-cs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bfollington","download_url":"https://codeload.github.com/bfollington/differ-cs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243864809,"owners_count":20360360,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["collision","csharp","sat","separating-axis-theorem","unity"],"created_at":"2024-10-06T04:08:42.629Z","updated_at":"2025-03-17T14:31:37.745Z","avatar_url":"https://github.com/bfollington.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"## What is differ-cs?\n\nA port of the original differ for Haxe (https://github.com/underscorediscovery/differ). The port is (where possible) a one-to-one mapping, with a few changes to the API (no more out parameters). This is a [Separating Axis Theorom](http://en.wikipedia.org/wiki/Hyperplane_separation_theorem) collision library for C# games, intended for use in Unity.\n\n----\n\n## Facts\n\n- Supports polygons, circles, and rays currently.\n- 2D only (for now).\n- Includes a simple drawing interface for debugging shapes (Not in my port, in the original)\n- **COLLISION ONLY.** No physics here. By design :)\n- Contributions welcome\n\n##Quick look\n\n**A simple collision example**\nThis is taken from the original, but this syntax is 100% compatible.\n\n    var circle = new Circle( 300, 200, 50 );\n    var box = Polygon.rectangle( 0, 0, 50, 150 );\n\n    box.rotation = 45;\n\n    var collideInfo = Collision.shapeWithShape( circle, box );\n\n    if(collideInfo != null) {\n        //use collideInfo.separationX\n        //    collideInfo.separationY\n        //    collideInfo.normalAxisX\n        //    collideInfo.normalAxisY\n        //    collideInfo.overlap\n    }\n\n### Roadmap\n\n- Unit tests, the original had none\n- Clean up code style\n- Implement ShapeDrawer for Unity\n- Create demos\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbfollington%2Fdiffer-cs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbfollington%2Fdiffer-cs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbfollington%2Fdiffer-cs/lists"}