Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Recent
    • Tags
    • Users
    • Login

    Usign RealToString function

    Scheduled Pinned Locked Moved SDK Help
    3 Posts 0 Posters 296 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H Offline
      Helper
      last edited by

      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.

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        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);

        1 Reply Last reply Reply Quote 0
        • H Offline
          Helper
          last edited by

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 11/06/2009 at 07:12, xxxxxxxx wrote:

          Thank you very much

          1 Reply Last reply Reply Quote 0
          • First post
            Last post