Hi All,
Pretty new to UE4 but not new to programming in general.
I’m following the video tutorial where he changes the Starter Content Chair seat colour to a random colour when he walks into a collision box, which is great. Works.
Well as an exercise I’ve expanded it a little so when he steps OUT of the box the colour should return to its original orange colour.
I’ve already done it by ‘hard coding’ the colour back to the original orange params, but I’d prefer to get it from the original colour definition in the SM_Chair -> M_Chair -> ColorSeats parameter. This is so I can reliably change it back on the source material on demand.
So I’m expecting I could grab the original colour from the ColorSeats material parameter and put it into a Linear Color Structure variable (or similar), doing this either in the Construction Script, or via Event BeginPlay. Then on the Event ActorEndOverlap, set ColorSeats back to this variable.
I’m attempting to use GetVectorParameterValue, in the ‘inverse’ manner with which we do the SetVectorParameterValue, but it’s asking for some weird seemingly unrelated inputs - does NOT appear to be the opposite instruction.
How would I go about storing the original colour back into a suitable variable to reset it?
Thanks in advance!
Stuart