Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: PET on September 03, 2015, 08:06:33 AM

Title: Update Unity UI with current player health
Post by: PET on September 03, 2015, 08:06:33 AM
Hello,

Sorry for all my new topics but I'm having problems with various stuff :D

I have a player & I have a turret. They both use the same health template.

(http://puu.sh/jYr2R/ae805ee471.png)

Then I'm doing something like this:

(http://puu.sh/jYr40/601235fef1.png)

Basically I am able to get and show the player starting health that is being stored in the Health variable.

What I want to do is in that Health template to sent the new float variable to the player STATS FSM so that fsm can display the new health value.

My problem is that the UI is not updating... I'm thinking that it's because this is a template?

I'm also trying to do the update for test purposes right on the health state machine however I can't drag my Text UI into the box where I specify the Game Object... so I can't tell him what UI Text to update...

(http://puu.sh/jYrv7/5b6e9fecee.png)

However this works on my "Stats" FSM that is doing the thing I mentioned in the first part of the post.

Thank you for your time!
Title: Re: Update Unity UI with current player health
Post by: PET on September 06, 2015, 05:48:55 PM
any suggestions please?

Thank You