SetAminoAcid (all) doesn't work
Case number: | 845813-997055 |
Topic: | Game: Tools |
Opened by: | ferrieux |
Status: | Open |
Type: | Bug |
Opened on: | Sunday, February 16, 2014 - 18:18 |
Last modified: | Sunday, February 16, 2014 - 20:45 |
The GUI recipe primitive "Set Amino Acid", with parameter "All segments", silently fails.
This was in a puzzle where only 3 segments are mutable, so the action could not be carried out. It's the downside of allowing actions that can fail in an interface with no error reporting - I prefer it to the alternative of not allowing those actions in the GUI recipe interface. Another alternative would be to add an output window to GUI recipes, which seems like a lot of work.
Another alternative would be to just continue to next segments when one fails :)
Note this is only an issue with the GUI primitive.
The equivalent Lua script works like a charm:
for k=1,structure.GetCount() do
structure.SetAminoAcid(k,'g')
end
Note this works even when only a few loci are mutable. This means that structure.SetAminoAcid() fails without raising an exception on locked segments...
This was with 20140213-15100a6562-linux_x64
Try for example with puzzle 846. All three segments of the ligand are mutable (and can be set manually), but trying to set them by a GUI recipe fails, without any output.