Object type reference?

  • I was wonder if there was some kind of list and/or reference to object types I.e. int, vec3, etc.. that can tell me what type are available, to let’s say, pass to the shader when making an effect?

    The only way I’ve noticed I can find out what types are available is to try it over and over with different types (which takes forever I might add bc it has to be changed in three places just so it can compile.. or not) or download a sample project that may or may not be using a similar type.

    For instance, I’m using “color” and setting it’s default to [0,0,0,1] because i need the alpha. It compiled and works but wouldn’t have known if I wouldn’t have tried bc other examples only show [0,0,0]. The only issue is the class, or atleast what’s shown in the editor, it only has 3 values and has no option for users to choose an alpha value. Is it a color3, not a color4? Is there a color4 type?

    Another example is I want to sample one image and test it against another. I know there’s not a texture type bc I tried that and didn’t work/compile. Is there a Sprite type? Image type? And if there is, it’s kind of another guess to what the default is. Would it be “null” “empty” “none”.

    So it would be awesome if there was some kind of list or reference for what types are available, what there default values can be and what’s available in there editor. I feel like I’ve spent the last 4 days just trying to find some kind of reference instead of just going by trial and error of seeing if it’s gonna compile or not

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Did you check the effects SDK documentation?

  • Omg I can’t thank you enough. I’ve hunted for that since I started. I looked in the docs before but never came across that post. So You can only use float, percent or color as vec3. I always pass Booleans as a float anyways but is there any plans to add more in the future like vec4 or color4 to cut down on so many variables in the editor?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)