-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use surveil in move tutorial #2064
Conversation
m <- instant (run "scenarios/Tutorials/move_surveil.sw"; | ||
main [action="P", entity="flower", room=3]); | ||
m |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@byorgey this is how instant
has to be used to not pay for tangible run
. The result is the rest of the computation which waits and places the wall.
For me, it's super laggy up until you move to the first flower, then very snappy after that. By "super laggy" I mean e.g. it takes several seconds to respond at all when I start typing I actually don't quite understand what's going on here. Sometimes, when I start the tutorial it pauses for several seconds before showing the goals dialog, and then is reasonably fast after that. But sometimes, it shows the goal dialog right away, and then once I exit that it sits there not responding for several seconds. The first feels annoying but acceptable; the second feels pretty bad because it looks like it is ready for you to start typing but it is not. |
@byorgey I removed a few busy waiting robots and put the check robot to sleep if you are far from the door. I don't think I can easily optimize this further; most of the time is spent parsing the same file 60 times: I could make a robot that runs the file and instantly builds new robots, which would teleport to their place.
|
Hmm, it definitely feels more responsive now (@DanRyba253 also posted some timing data in Discord suggesting the same thing). However, it seems slightly broken: when I execute |
And yes, as for |
@@ -13,7 +13,7 @@ objectives: | |||
condition: | | |||
r <- robotNamed "check"; | |||
w <- as r {count "Win"}; | |||
return (w >= 2) | |||
return (w >= 1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@byorgey, thanks for pointing it out; I made a typo while changing the conditions to use one robot.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good now, this seems a strict improvement over the previous version.
I still don't understand why sometimes I get a long pause before the initial goal modal is shown, and sometimes I get a long unresponsive pause after dismissing the goal modal. I have not been able to find any particular way to consistently get one behavior or the other. But whatever the reason I don't think it's the fault of this scenario.
This should make the move tutorial run faster by making most of the robots
surveil
the door to their section.