playMaker

Author Topic: Set Procedural Float  (Read 4227 times)

PET

  • Full Member
  • ***
  • Posts: 137
    • View Profile
    • GamerPET
Set Procedural Float
« on: June 29, 2016, 08:30:08 AM »
Hello there,

I have a nice shader that has a couple of sliders.



The Playmaker Action looks like this:


that "Scanner" from the first screenshot is called "animation_offset". So far so good.

The problem is that I need to access the Y and not X.

Currently Playmaker only access the first component... the first label or however it's called.

Is it possible to add a new option so I can access other values of a property?

Or maybe I'm doing something wrong... so I'm open to suggestions :D

Thank You


P.S. Basically I have a property that I want to animate for a couple of seconds... and I want to do it real time. It's basically a line that moves left/right... Any ideas on how to accomplish this?

Thanks again <3
Technical Game Designer
www.GamerPET.com

Zeldag

  • Full Member
  • ***
  • Posts: 198
    • View Profile
Re: Set Procedural Float
« Reply #1 on: June 29, 2016, 10:53:17 AM »
Hi,

Have you tried to 'set property' ?

Depending on your setup try this:
Just open the FSM and click on the state that you need, then click 'lock' at the top of the editor. Next, click on the game object that has the shader. Then drag the shader from the object's inspector to the state's action list. Click 'Set Property', then chose a property you wish to manipulate. (These instructions are specific to when the shader and the FSM are on different objects. If they are on the same object, then you don't need to lock, just drag.)

Good luck, hope this works for you!

PET

  • Full Member
  • ***
  • Posts: 137
    • View Profile
    • GamerPET
Re: Set Procedural Float
« Reply #2 on: June 30, 2016, 04:41:32 AM »


This is what I get when I drag the material. It's substance material not a normal material.
Technical Game Designer
www.GamerPET.com

Zeldag

  • Full Member
  • ***
  • Posts: 198
    • View Profile
Re: Set Procedural Float
« Reply #3 on: June 30, 2016, 08:11:39 AM »
Have you explored the little menu that comes up? Im sure the right choice is in there lol :D , I have not seen a menu like that myself, but Im still terrified of updates (not just in playmaker, but most of technology) so it may be because my version is too old for menus like that.

If I was trying to do it, I would just test out the options (in that menu) that sound like they may be right :D . Good luck with it.


PET

  • Full Member
  • ***
  • Posts: 137
    • View Profile
    • GamerPET
Re: Set Procedural Float
« Reply #4 on: July 01, 2016, 05:33:08 AM »
Yea, I go to Substance and that's the place I can change a Float. However the action itself does not support multiple values for a property.
Technical Game Designer
www.GamerPET.com

Zeldag

  • Full Member
  • ***
  • Posts: 198
    • View Profile
Re: Set Procedural Float
« Reply #5 on: July 01, 2016, 10:08:43 AM »
Sorry what do you mean it does not support multiple values?

If you mean you need to set the value for X and Y, just use the action twice?

PET

  • Full Member
  • ***
  • Posts: 137
    • View Profile
    • GamerPET
Re: Set Procedural Float
« Reply #6 on: July 01, 2016, 06:39:40 PM »
I'm not sure how to explain this better.

My field in the in the material is called "animation_offset". This field has to values. X & Y.

Playmaker only allows me to input this fields.


I have a field where I specify the material (in my case is called "test").
I have a field where I can name the Float Property (in my case it's caleld "animation_offset")
I have a field where I can change the Float Value of the Float Property from above.

My problem is that... I have 2 Float Value's (X & Y) ... and this action is not allowing me to specify which value I want to change. The first one, or the second one... or the third one, etc.
Technical Game Designer
www.GamerPET.com

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3889
  • Official Playmaker Support
    • View Profile
    • LinkedIn
Re: Set Procedural Float
« Reply #7 on: July 01, 2016, 08:23:50 PM »
Sounds like your property is a Vector2 property. It seems like we're actually missing Set Procedural Vector actions... I've attached actions that should work (they'll be in the next update also).
« Last Edit: July 01, 2016, 10:04:25 PM by Alex Chouls »

PET

  • Full Member
  • ***
  • Posts: 137
    • View Profile
    • GamerPET
Re: Set Procedural Float
« Reply #8 on: July 04, 2016, 05:38:15 AM »
Thanks Alex. This works. After I add a Rebuilt Texture action... my Y get's updated... however...

Is there a way to animate that float? I can't find a way to Animate Vector2.

Basically I want my Y to change from -0.25 to 0.25 ... wait a bit... then go the other way... etc. It's like a "scanner" :P
Technical Game Designer
www.GamerPET.com

PET

  • Full Member
  • ***
  • Posts: 137
    • View Profile
    • GamerPET
Re: Set Procedural Float
« Reply #9 on: July 05, 2016, 06:38:18 PM »
So, is there a way to Animate the Float of a Vector 2?

Thank You
Technical Game Designer
www.GamerPET.com

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15443
  • Official Playmaker Support
    • View Profile
Re: Set Procedural Float
« Reply #10 on: August 01, 2016, 05:34:09 AM »
Hi,

 Yes, you actually animate an FsmFloat and then inject into your FsmVector2 variable that Fsmfloat and finally use SetProceduralVector2.


Bye,

 Jean