{"id":13412947,"url":"https://github.com/gonutz/prototype","last_synced_at":"2026-02-05T00:13:31.347Z","repository":{"id":28148335,"uuid":"31648568","full_name":"gonutz/prototype","owner":"gonutz","description":"Simple 2D game prototyping framework targetting Windows, Mac, Linux, WASM.","archived":false,"fork":false,"pushed_at":"2025-08-05T12:45:43.000Z","size":4216,"stargazers_count":92,"open_issues_count":1,"forks_count":10,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-08-15T04:41:32.694Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://pkg.go.dev/github.com/gonutz/prototype/draw","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gonutz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2015-03-04T09:24:39.000Z","updated_at":"2025-08-05T12:45:45.000Z","dependencies_parsed_at":"2024-10-26T08:36:40.880Z","dependency_job_id":"fce7933c-9d3e-4944-9899-5b31857e8e45","html_url":"https://github.com/gonutz/prototype","commit_stats":null,"previous_names":[],"tags_count":24,"template":false,"template_full_name":null,"purl":"pkg:github/gonutz/prototype","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gonutz%2Fprototype","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gonutz%2Fprototype/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gonutz%2Fprototype/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gonutz%2Fprototype/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gonutz","download_url":"https://codeload.github.com/gonutz/prototype/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gonutz%2Fprototype/sbom","scorecard":{"id":435407,"data":{"date":"2025-08-11","repo":{"name":"github.com/gonutz/prototype","commit":"d3732ae42e6889269707f5a1c5a55d12f43c6419"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.3,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Maintained","score":10,"reason":"30 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-19T04:31:42.933Z","repository_id":28148335,"created_at":"2025-08-19T04:31:42.933Z","updated_at":"2025-08-19T04:31:42.933Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29102273,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-04T22:44:52.815Z","status":"ssl_error","status_checked_at":"2026-02-04T22:44:16.428Z","response_time":62,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":[],"created_at":"2024-07-30T20:01:31.470Z","updated_at":"2026-02-05T00:13:31.340Z","avatar_url":"https://github.com/gonutz.png","language":"C","readme":"# prototype\n\nSimply prototype 2D games using an easy, minimal interface that lets you draw\nsimple primitives and images on the screen, easily handle mouse and keyboard\nevents, and play sounds.\n\n![Games](https://github.com/gonutz/prototype/blob/master/samples/screenshots/games.png)\n\n## Installation\n\nInstall the [Go programming language](https://golang.org/dl/). After clicking\nthe download link you will be referred to the installation instructions for your\nspecific operating system.\n\nInstall [Git](https://git-scm.com/downloads) and make it available in the PATH\nso the Go tool can use it.\n\nFor Linux and macOS, you need a C compiler installed. On Windows this is not\nnecessary.\n\n### Supported Targets\n\nThe prototype framework supports multiple targets:\n\n#### Windows (default)\n\n- Uses Direct3D 9\n- No additional dependencies needed\n\n#### Linux/macOS (GLFW backend)\n\n- Uses OpenGL via GLFW\n- Install required packages (example for Ubuntu/Debian):\n  ```sh\n  sudo apt install libx11-dev libxrandr-dev libgl1-mesa-dev libxcursor-dev libxinerama-dev libxi-dev\n  ```\n\n#### WebAssembly (experimental)\n\nTo build and run a WASM version of your game, you can use the `drawsm` tool.\nInstall it with\n\n\tgo install github.com/gonutz/prototype/cmd/drawsm@latest\n\nIt allows you to run your game locally from within your project directory with\n\n\tdrawsm run\n\nor build it into the project directory with\n\n\tdrawsm build\n\n## Installation (Library \u0026 Samples)\n\n## Documentation\n\nFor a description of all library functions, see [the package doc\npage](https://pkg.go.dev/github.com/gonutz/prototype/draw). Most functionality\nis in the `Window` interface, and documented via code comments.\n\n## Example\n\n```go\npackage main\n\nimport (\n\t\"math\"\n\n\t\"github.com/gonutz/prototype/draw\"\n)\n\nfunc main() {\n\tdraw.RunWindow(\"Title\", 640, 480, update)\n}\n\nfunc update(window draw.Window) {\n\tw, h := window.Size()\n\tcenterX, centerY := w/2, h/2\n\n\tmouseX, mouseY := window.MousePosition()\n\tmouseInCircle := math.Hypot(float64(mouseX-centerX), float64(mouseY-centerY)) \u003c 20\n\tcolor := draw.DarkRed\n\tif mouseInCircle {\n\t\tcolor = draw.Red\n\t}\n\twindow.FillEllipse(centerX-20, centerY-20, 40, 40, color)\n\twindow.DrawEllipse(centerX-20, centerY-20, 40, 40, draw.White)\n\tif mouseInCircle {\n\t\twindow.DrawScaledText(\"Close!\", centerX-40, centerY+25, 1.6, draw.Green)\n\t}\n\n\tfor _, click := range window.Clicks() {\n\t\tdx, dy := click.X-centerX, click.Y-centerY\n\t\tif dx*dx+dy*dy \u003c= 20*20 {\n\t\t\twindow.Close()\n\t\t}\n\t}\n}\n```\n\nThis example displays a window with a round button in the middle to close it. It demonstrates basic drawing and event handling.\n","funding_links":[],"categories":["Game Development","游戏开发","Relational Databases"],"sub_categories":["Search and Analytic Databases","Advanced Console UIs","SQL 查询语句构建库","检索及分析资料库"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgonutz%2Fprototype","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgonutz%2Fprototype","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgonutz%2Fprototype/lists"}