Skip to content

Commit 4f92185

Browse files
committed
Added fps_target command.
1 parent 9b4b632 commit 4f92185

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

Runtime/DevConsoleMono.cs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -878,6 +878,19 @@ private void InitBuiltInCommands()
878878
}
879879
));
880880

881+
AddCommand(Command.Create<int>(
882+
"fps_target",
883+
"fps_max",
884+
"Query or set the target framerate.",
885+
Parameter.Create("targetFrameRate", "Frame rate the application will try to render at."),
886+
i =>
887+
{
888+
Application.targetFrameRate = i;
889+
LogSuccess($"Target frame rate set to {i}.");
890+
},
891+
() => LogVariable("TargetFrameRate", Application.targetFrameRate)
892+
));
893+
881894
#endregion
882895

883896
#region Screen commands

0 commit comments

Comments
 (0)