BugHuntCamo: Make sure ticks advance before resetting timer#450
Open
LaCuneta wants to merge 1 commit into
Open
BugHuntCamo: Make sure ticks advance before resetting timer#450LaCuneta wants to merge 1 commit into
LaCuneta wants to merge 1 commit into
Conversation
With changes to timer resolution due to various memory attacks, Bug Hunt Camouflage doesn't run as it once did in NetLogo Web. Because the timer returns `0` so often, not much happens when `go` is running. In desktop it runs many more cycles of `go` so you get more of the minimum timer bits coming out, so it's less noticeable. The solution is just to track how far the ticks advanced and only reset if it went somewhere at all.
Contributor
Author
|
You can see the current version and have it not update (unless your computer has a reaaaaally slow processor): https://netlogoweb.org/launch#https://netlogoweb.org/assets/modelslib/Sample%20Models/Biology/Evolution/Bug%20Hunt%20Camouflage.nlogox And the updated version: https://raw.githubusercontent.com/NetLogo/models/e9abdfcef02907cf123b142e2c08b7c9d130ba99/Sample%20Models/Biology/Evolution/Bug%20Hunt%20Camouflage.nlogox The "clear environment" button helps for testing. Also observer the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
With changes to timer resolution due to various memory attacks, Bug Hunt Camouflage doesn't run as it once did in NetLogo Web. Because the timer returns
0so often, not much happens whengois running. In desktop it runs many more cycles ofgoso you get more of the minimum timer bits coming out, so it's less noticeable.The solution is just to track how far the ticks advanced and only reset if it went somewhere at all.