{"id":25256857,"url":"https://github.com/merthsoft/gravityca","last_synced_at":"2025-04-06T00:28:32.458Z","repository":{"id":238581873,"uuid":"796882512","full_name":"merthsoft/GravityCa","owner":"merthsoft","description":"Cellular automata inspired by mass and gravity modeled as interacting fields.","archived":false,"fork":false,"pushed_at":"2024-05-10T16:17:42.000Z","size":48,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-12T06:39:32.883Z","etag":null,"topics":["cellular-automata","generative-art","simulation"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"unlicense","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/merthsoft.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}},"created_at":"2024-05-06T19:52:10.000Z","updated_at":"2025-01-19T08:32:04.000Z","dependencies_parsed_at":"2025-02-12T06:36:40.673Z","dependency_job_id":"46143b6d-ce0b-4199-abfa-71d18e35953b","html_url":"https://github.com/merthsoft/GravityCa","commit_stats":null,"previous_names":["merthsoft/gravityca"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/merthsoft%2FGravityCa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/merthsoft%2FGravityCa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/merthsoft%2FGravityCa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/merthsoft%2FGravityCa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/merthsoft","download_url":"https://codeload.github.com/merthsoft/GravityCa/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247419635,"owners_count":20936009,"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":["cellular-automata","generative-art","simulation"],"created_at":"2025-02-12T06:28:09.538Z","updated_at":"2025-04-06T00:28:32.439Z","avatar_url":"https://github.com/merthsoft.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GravityCa\n\n## Controls:\n### Simulation Controls:\nSpace - toggles simulation running or paused\nTODO:\nLeft click to add a mass with the current divisor\nRight click to remove mass\nMose wheel adjusts the divisor\n\n0-9 - Change colors of gravity\nAlt+0-9 - Change colors of mass\n\nF1 - 2d render mode\nF2-F6 3D render modes\n\nM - Toggle mass renderer\nG - Toggle gravity renderer\nB - Toggle \"Gen mass\" mode for generating mass each step\n\nZ - Zero-out mass field\nX - Zero-out gravity field\nC - Clear both fields\nR - Randomly fill .01% of the remaining open mass field with the current divisor\nH - Fill the mass field with the current divisor\n\n### 3D Controls\nUse a gamepad for the easiest time. For keyboard:\nWASD for movement, R and F for up and down. Keypad for rotations etc.\n\n## Simulation Details\nMass and gravity are modeled as two 2D fields. The user inputs mass particles with a given mass, determined by the Divisor input (MaxMass / Divisor). As the simulation runs, it updates the gravity and mass fields based on each other. The mass field is conserved, meaning no particles will ever \"disappear\". The gravity field is calculated from the mass field and itself. If in \"gen mass\" mode (there's an asterisk next to \"Running\") it will randomly generate mass each step.\n\nFor each gravity cell, it looks at the mass field, and sets the gravity to MassValue diminshed by some amount. It then takes the average of the gravity from all adjacent cells, and adds that to the current gravity from the mass field.\n\nFor each mass cell, it looks at the adjacent gravity field cells as well as its own gravitation field cell. It orders them by strength, and randomly picks the strongest gravitation to \"fall\" towards. This could mean \"falling\" toward its own cell, thus not moving. If a cell (other than itself) occupies the cell it tries to fall toward, it falls toward another random cell with the same gravitation strength. If all cells with the highest gravitational strength are occupied, it goes to the next strongest gravitational strength. It does this until there are no other cells, in which case it stays put.\n\nThe amount of mass that can occupy a since cell is proportional to the gravity at that cell.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmerthsoft%2Fgravityca","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmerthsoft%2Fgravityca","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmerthsoft%2Fgravityca/lists"}