Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you have been placed in read-only mode.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 11/06/2009 at 01:59, xxxxxxxx wrote:
User Information: Cinema 4D Version: R11 Platform: Mac ; Language(s) : C.O.F.F.E.E ;
--------- Hi all
I'm very new to COFFEE although I've been using C4d for quite a while. Now I'm writing some scripts to aid me with some mundane tasks. I've got this piece of code that should add a number to a name and I'm stuck and seriously ashamed that I can't get it to work. This is the code, the console says Variable or function expected where the RealToString function is...
for(i=SelectedCounter-1;i>=0;i--) { doc->AddUndo(UNDO_OBJECT, SplinesArray _); Extrudes _#ID_BASELIST_NAME = SplinesArray _#ID_BASELIST_NAME + RealToString(i); // names the extrudeNurbs SplinesArray _- >Remove();// removes object SplinesArray _- >InsertUnder(Extrudes _);//places it under ExtrudeNurbs Extrudes _#EXTRUDEOBJECT_MOVE:VECTOR_Y = -1* SplinesArray _#ID_BASEOBJECT_POSITION:VECTOR_Y; //extrudes downwards Extrudes _#EXTRUDEOBJECT_MOVE:VECTOR_Z = 0; // zeros the Z extrusion };
Let me know if you can figure out what I'm doing wrong.
On 11/06/2009 at 06:58, xxxxxxxx wrote:
In COFFEE, you use tostring() to convert a variable of any type to a string.
> SplinesArray#ID_BASELIST_NAME + tostring(i);
SplinesArray#ID_BASELIST_NAME + tostring(i);
On 11/06/2009 at 07:12, xxxxxxxx wrote:
Thank you very much