This is not correct. If you have a PlanningScene and a MotionPlanning plugin in the same rviz process the line above will produce 2 materials with the same name. Please re-add the use of "this" in the construction of the name, in addition to the material count.