I'm experiencing completely inconsistent behavior depending on whether or not I'm in Slate vs. Compact.
This has been happening since release 2017, and hasn't gotten better. What is going on under the hood that I need to account for here? There is nothing in the SDK documentation I can find that even implies there should be a difference.
Take this for example:
int NumParamBlocks() { return 3; }
IParamBlock2* GetParamBlock(int i) { switch (i) { case 0: return pblock; /*case 1: return pbCurve;*/ case 1: return pbMap; case 2: return pbXYZ; } return NULL; }
IParamBlock2* GetParamBlockByID(BlockID id) {
if (pblock->ID() == id) return pblock;
// if (pbCurve->ID() == id) return pbCurve;
if (pbMap->ID() == id) return pbMap;
if (pbXYZ->ID() == id) return pbXYZ;
return NULL;
}
Above, case 1 has been commented out and all the other cases shifted over by one. This is allowable, but incorrect if the individual Pblock ref IDs have not been adjusted accordingly.
BUT this will result in a correct representation in the COMPACT material editor whereas it will result in everything after Case 0 failing to properly update in SLATE. To be honest neither method should work well in either compact, or slate -- but yet it does.
Why the inconsistency? (It literally makes one want to tear one's hair out when troubleshooting)
Are you paying attention, Autodesk?
can you show your paramblock definition, pretty sure you don't have 3 paramblocks
can you show yourimplementation of GetReference() and SetReference()
what are the ref_nums for the xyz gen, and the map ?
there can be lots of reasons why this happen for you
Can't find what you're looking for? Ask the community or share your knowledge.