Rebuild: allow old and new behavior
| Case number: | 845813-992060 |
| Topic: | Game: Tools |
| Opened by: | Rav3n_pl |
| Status: | Noted |
| Assigned: | Seth Cooper |
| Priority: | 3 |
| Type: | Feature |
| Opened on: | Tuesday, March 6, 2012 - 17:48 |
| Last modified: | Friday, March 16, 2012 - 00:21 |
My observed pros and cons in new/old rebuild algos.
Restored "old" rebuild:
+ much better for manual rebuilds
+ finds more new positions
+ finds new position/s faster
- not working on 1 segment (causes crash sometimes)
- not working properly on scripts (rebuilders make close to nothing)
- producing 3-8 new positions on undo graph on rebuild(1)
Dropped "new" rebuild:
+ working good on scripts, even on 1 segment
- slower, failing to make new position more often
- producing 1-3 new position on rebuild(1)
Idea: allow to use both of algorithms.
Solutions:
- use old rebuild in GUI when make manual rebuilds
- use new rebuild in lua scrips
- use old rebuild in lua when calling even number and old when calling uneven number of rebuilds
- add lua function/gui button to change algorithm
Additional:
- limit number of new positions to number in call
- change rebuild from void to boolean and return that new position is found or not
Checked, and double checked. There is no GUI script rebuild function :) This is LUA domain :)
| Status: Open » Noted |
| Assigned: Anonymous » Seth Cooper |
Seems like the ideal solution would be to fix the 3 negatives from the old rebuild:
- not working on 1 segment (causes crash sometimes)
- not working properly on scripts (rebuilders make close to nothing)
- producing 3-8 new positions on undo graph on rebuild(1)
If we could get those easily fixed (without affecting what makes it better) then that should be the only Rebuild.
There is one other topic that must be fixed. That in between rebuild positions can go into recent_best. That does not work correctly in dev. See my post about that.
I've tried rebuilding disjointed sections of the CO2 and You! puzzle and this works in "main" (new rebuild) but not in "devprev" (old rebuild). I would vote for the new rebuild if this can't be implemented in the old rebuild.
code snippet:
selection.DeselectAll()
selection.SelectRange(243,254)
selection.SelectRange(403,418)
structure.RebuildSelected(1)
This code runs in both but only one of the ranges is rebuilt using the old rebuild code, both are rebuild in the new rebuild code.




which rebuild will the older non lua scripts use?