Jump to content

Hi guys

please be considerate and disable AD blocker when you are on the C4D Cafe, because it helps us run this forum. We minimalized showing of the AD's all across the forums, so please, be so kind and at least help us by having AD blocker turned off.

 

Cheers,
Cafe Staff 

Rendercore Lab

SolarPH

Regular Member
  • Content count

    90
  • Joined

  • Last visited

  • Days Won

    1

SolarPH last won the day on August 8 2016

SolarPH had the most liked content!

Community Reputation

6 Poor

About SolarPH

  • Birthday 06/28/1999

Contact Methods

  • Website URL
    sellfy.com/SolarPH.MC

Profile Information

  • First Name
    Marc John
  • Last Name
    Benamera
  • C4D Ver
    14 Studio
  • Location
    Philippines
  • Interests
    Creating advanced Minecraft Rigs, sold at Sellfy.com
  1. I may test that sometime. For now, I will test it with normal Fusion Texture color assignment than my usual overlay texture method. I do the texture overlay method to make the rig piece optimized. It makes the textures stay on low count (if the object needs to be multiplied by dragging an object while pressing Ctrl) because of the textures not modified, but as I see in my current project that have a mix range of 5 colors, it do not follow a smooth change in gradient, sometimes it just instantly changes black to red, or not having the correct division of colors. Sometimes it goes "Color1(100%) -> (3) Color1(50%) + Color2(50%) -> Color2(100%)" in a 5-block transition. I can share you the project file if you want to see it.
  2. The reverse order works in lambda sort key too. Now, I am having problems in color mixing, and one way to make the color mixing work the right way, is to make another layer of list with sorting. Sometimes it needs an ascending order, sometimes descending. What do you think the best way to order them for perfect color mixing? Average RGB value used for sorting didn't help. I have an idea of having the vector into order list, but comma would separate values. How can I input vector as the sorting value? Any ideas?
  3. I just came back. I think I will just reverse the order of the result reference by typing in 2 for 1st, 1 for 2nd, and 3 for third. Also, I think changing the integer in "tup:tup[]" after the key changes the referenced number for sorting. And oh, I used a pre-made 12-block collision detector which objects collide with the collision box.
  4. the code you sent works. if you also do know a script that works like a collision node but mixed with the script you sent?
  5. yes, this might work. I will test this right away
  6. Do anyone know how to make an order of values, I need a logic to work with python like this: 1st Lowest value to Output1 2nd Lowest Value to Output2 3rd Lowest Value to Output3 etc. I have tried to make it as this: if A < B and C: Output1 = A elif A > B < C: Output1 = B elif A and B > C: Output1 = C it will make the script long, and it was only for Output1. I need a script that reads what is the 1st, 2nd, 3rd, etc. and output the object where it came from. In the original project, I have 12 linked blocks, and I need to work on 12 effectors which is operated by the logic that I said earlier. To make another example of the logic, I need it top work as this: If "highest" is Av (which is "Av" the one from a float input port), the output in Output1 is "A" (which is an object linked from a user data of an object) or If "Highest" is (a value in tuple or the tuple ID), the output in Output1 is "A" I have this order: Av for A Bv for B Cv for C etc. I need a total of 12 Outputs for 1st to 12th lowest Value. Also, I have a value which is the MAX value compared, which is 100000.
  7. How to hide User Data

    ok. thanks for your help :)
  8. How to hide User Data

    I searched some before, but I can't make it work with my modification. there has to be something with c4d.DESC_HIDE The file you sent gives the perfect way that I was thinking, and the xpresso set-up is also what I need to be it. btw, what did "descId[1].id" meant on the 4th line?
  9. I want to know how hiding userdata works in terms of group and data. I have a rig that have it's userdata exposed, and I need to hide them. how can I hide them using a python node?
  10. So, this case, still Null A and Null B. Two goals is needed in this case. Goal 1 is to make the user data hidden while the 2nd object (Null B) is connected through the link user data of the first object (Null A). Goal 2 is to make some user data hidden even if 2nd object is connected into the first object (Null A).
  11. User Data Transfer with Python

    ok. doing that
  12. User Data Transfer with Python

    no errors has been found in console, but the node turns yellow. and also, 0 should be hidden, 1 for visible, and 2 for default. I use 1 and 2 mostly for my rigs, because using 0 in visibility toggle makes some parts of the rigs be still visible even the parent's visibility is hidden. it have a syntax error somehow, maybe python in R18 acts differently. and I tried a script using this without it malfunctioning: link is the port where the separated object was placed, and link2 is the port where the main object is linked, and the source of data that is needed to transfer/copy. The modification I made on your script made the trick to get the script working even I change names, or having same names of objects. One more thing, how can I hide userdata using python?
  13. User Data Transfer with Python

    I got a complete working script now... I have searched some help sources, and some sources told that the attributes can be dragged into the python console. I ended up with this: import c4d def main(): #for user data transfer if link: link[c4d.ID_USERDATA,1] = link2[c4d.ID_USERDATA,2] link[c4d.ID_USERDATA,2] = link2[c4d.ID_USERDATA,3] link[c4d.ID_USERDATA,3] = link2[c4d.ID_USERDATA,4] #for visibility of the linked object if connection == 0: link[c4d.ID_BASEOBJECT_VISIBILITY_EDITOR] = 2 link[c4d.ID_BASEOBJECT_VISIBILITY_RENDER] = 2 else: link[c4d.ID_BASEOBJECT_VISIBILITY_EDITOR] = 1 link[c4d.ID_BASEOBJECT_VISIBILITY_RENDER] = 1 when link don't have any object on the field, the python node turns yellow, and turns back to normal when an object has been inserted.
  14. User Data Transfer with Python

    And for the second example, i think of two ways to toggle visibility of the cube. Since the original project, which was a minecraft character rig with separate mesh bundle, the "Null B" needs to be hidden in both renderer and editor when set in pose mode, and visible in edit mode. One of the methods I think is to connect a user data through python and connect the compare node to compare the name of the linked object (which if none, the main object's name is returned, and the original object (Null A). The xpresso will look like this: the script for there can be this: if connection = 1: link2[c4d.ID.USERDATA,5] = 1 else: link2[c4d.ID.USERDATA,5] = 2 where id no.5 is an extra user data on "Null B" that is also connected on visibility of the null on the link using a separate xpresso assigned in "Null B". The second method is to directly modifying the visibility through Xpresso using a script. but i don't know how to do it. i guess it can be with BaseContainer? Btw, I have some modifications on your first file, and I come up with this as the prefect script that I was looking: the result was perfect, and every data changes is followed by the linked object. and the script was safe from breaking due to name change or multiple objects with same name. and also, how do you do that box thing where you have put your complete code in? it doesn't look like a quote box.
  15. User Data Transfer with Python

    the python node always turns yellow when output is connected in the one with cube visibility toggle. for the first file without cube toggle, it works, but your python node have some extra empty lines that makes the python node have a syntax error. My concern now is, I need it to have the actual null (a.k.a. Null A) as the one to be referenced. Idk if it is correct, but doc.SearchObject does search the exact object name, and not the actual object to be referenced. Having multiple objects with name "Null A", or even changing it's name will break the script's purpose. I have an idea of getting the main null's name (Null A) to be connected to input port of the python node, but i don't know how I will do it without having glitches when 2 or more nulls have the same name. I will try getting some trial and errors too. Btw, i was wondering, what did the "op" means in phyton, and is it used in phyton node, python tag, or both?

×