Dev #3

Merged
alardner merged 2 commits from dev into main 2026-07-13 23:38:43 -07:00
3 changed files with 11 additions and 0 deletions
Showing only changes of commit fb2d5d2d0c - Show all commits
+1
View File
@@ -42,3 +42,4 @@ build
debug
.cache
tmp
screenshot*
+4
View File
@@ -17,3 +17,7 @@ polypartiCL is licensed with the 3-clause BSD license.
- Add linear beams
- Add environment objects / multiple rooms per screen
- Add timed events
![Screenshot 1](https://alexlardner.com/img/1.png)
![Screenshot 2](https://alexlardner.com/img/2.png)
![Screenshot 3](https://alexlardner.com/img/3.png)
+6
View File
@@ -67,6 +67,8 @@ int main(int argc, char* argv[]) {
raylib::Vector2 mouse_i, mouse_f, mouse_d;
raylib::Vector2 midpoint(screenWidth * 0.5, screenHeight * 0.5);
raylib::Image screenshot(screenWidth, screenHeight, WHITE);
float dirH[2] = {1.0f, 0.0f};
float dirV[2] = {0.0f, 1.0f};
@@ -89,6 +91,10 @@ int main(int argc, char* argv[]) {
if (IsKeyPressed(KEY_B)) useShader = !useShader;
if (IsKeyPressed(KEY_SPACE)) paused = !paused;
if (IsKeyPressed(KEY_T)) sim.reverseInterval();
if (IsKeyPressed(KEY_S)) {
screenshot.LoadFromScreen();
screenshot.ExportAsCode("screenshot" + std::to_string(window.GetTime()));
}
if (!paused) {
sim.updateFields(window.GetTime());