Skip to content
This repository has been archived by the owner on Jul 30, 2024. It is now read-only.

Commit

Permalink
feat: mutate workspace on tick
Browse files Browse the repository at this point in the history
  • Loading branch information
doinkythederp committed Dec 22, 2023
1 parent 1477278 commit 4984957
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src-tauri/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src-tauri/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "pros-simulator-gui"
version = "0.3.1"
version = "0.4.0"
description = "A Tauri App"
authors = ["pros-rs"]
license = ""
Expand Down
2 changes: 1 addition & 1 deletion src-tauri/tauri.conf.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
},
"package": {
"productName": "PROS Simulator",
"version": "0.3.1"
"version": "0.4.0"
},
"tauri": {
"allowlist": {
Expand Down
5 changes: 4 additions & 1 deletion src/workspace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,10 @@ export class Workspace {
switch (name) {
case "RobotCodeStarting": {
this.terminal.log("Robot code running", Msg.Progress);
this.#timer = setInterval(() => this.tick(), 1000);
this.#timer = setInterval(
() => Workspace.mutate((ws) => ws.tick()),
1000,
);
break;
}
case "LcdInitialized": {
Expand Down

0 comments on commit 4984957

Please sign in to comment.