I found a Zoning Regulations.cga rule from 2012 that I wanted to modify for a project I'm working on in CityEngine 2016.1. I made the adjustments and now the file produces an error any time I click on it in the Navigator pane. I'm not sure what is triggering the error, but I assume it's from something in the code that may have been deprecated in later releases of CityEngine. Is there a way to check for that? And if I'm wrong, does any one know why this error would be generated?
Since 2012 there certainly have been some breaking changes, so it is not surprising if the code has errors. However, typically, it should be fixable. If you open the code in the rule editor, you can see the errors and try to update the code and make it acceptable for 2016.1. The CGA reference manual will probably be helpful for this task. CGA Reference Index
In regards to the error, I'm not sure what is causing it. If the error is not coming from the code, you can try to delete the .cgb files in the bin folder and see if that helps.
There are no obvious errors nor warnings in the rule editor. For the most part, it works. Even after deleting the .cgb files from the bin and re-opening CityEngine, the error persists.
In my start rules I'm using constants that reference an imported rule set. By doing so the Default style appears blank. I can't see how that would cause this type of error, but it's the only other oddity in the file.
I found the issue: poor logic. This self-referencing attribute was causing the strange error. The error never hinted at this kind of issue so this post should serve as a warning.
attr Front_Baseheight =
case Front_Baseheight > 0: Front_Baseheight
case Front_Baseheight == 0: 2.4384 # 8'
else: 3.048 # 10'