Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Resolved Setting Values on Exposed Bound Box properties

Discussion in 'Visual Effect Graph' started by DTECTOR, Aug 23, 2022.

  1. DTECTOR

    DTECTOR

    Joined:
    Aug 23, 2020
    Posts:
    76
    So with setting values to exposed properties in visual graph effects. Using setfloat for something like the spawn-rate is straight-forward, however something like the bounding box property, which has numerous properties of it's own, not just a single float value, how do I set all of those? Is there a naming convention for the string to access it's properties like center & size?

    I also see you have to check them so do I need to set bool for each? I don't see anything in the docs showing how to access these properties within the properties. (the docs for the exposed property helper consists of a single paragraph)

    Any help is greatly appreciated.
     
  2. Qriva

    Qriva

    Joined:
    Jun 30, 2019
    Posts:
    804
    There was some easy way to check this, but somehow I can't remember now, but yes it's
    propertyName_field
    . For example if you want to set Transform property named "MyTransform", then it will be:
    Code (CSharp):
    1. MyTransform_position
    2. MyTransform_angles
    3. MyTransform_scale
     
    DTECTOR likes this.
  3. Qriva

    Qriva

    Joined:
    Jun 30, 2019
    Posts:
    804
  4. DTECTOR

    DTECTOR

    Joined:
    Aug 23, 2020
    Posts:
    76