Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: krakov73 on February 19, 2016, 08:44:23 AM

Title: updgrading to 1.8(43) 'Missing Variable' spammage
Post by: krakov73 on February 19, 2016, 08:44:23 AM
Unity version: 5.3.1p1
Previous Playmaker Version:
OS: Win7

Having issues upgrading my (pretty large) project to the recommended version of playmaker but I thought I'd ask here before going full on bug report.


I have noticed that 1.8's attitude towards getting/setting fsm variables that are not present very is different to, unfortuately thats really bad news for me see pic: (

The previous behaviour was to do nothing - at worst i'd get the odd yellow 'hey no variable' warning so I've been taking advantage of this & treating it like udp and not rellying on variables being present to be set which was very useful until 1.8.

I've also got similar problems with accessing fsm variables from script using ActionHelpers.GetGameObjectFsm & FsmVariables.GetFsmFloat throwing warnings and errors it didn't before.

What makes me really suspicious is the weird ones - like createObject throwing a missing float error message - createObject does not use any floats! (

I can repro this behaviour disparity by getting or setting non existent variables in version with no issues & then getting show stoppers in 1.8 doing the same thing.

So thats the bad news - weird thing underneath the error message spam my game is still working just fine, I just have to unpause the game & things carry on as normal until it throws me another.

Seems to me like there is an over aggresive error checker screwing up the works any advise would be welcome on narrowing this down as right now 'everything' is kinda broken by 1.8 :(

Oh btw: disabling realtime error checking, like the goggles, does nothing :)
Title: Re: updgrading to 1.8(43) 'Missing Variable' spammage
Post by: Alex Chouls on February 19, 2016, 09:47:15 AM
Yeah, I believe 1.8 is more aggressive about this. I think it was a user request to help track down missing variables :P But I'll take a look and see if we can handle it differently, or make it an option.

In the meantime, you could edit the SetFsmInt etc. actions.
You could comment out the warnings.
And replace GetFsmInt with FindFsmInt.

I'm on the road so can't test this right now, but it should work...
Title: Re: updgrading to 1.8(43) 'Missing Variable' spammage
Post by: krakov73 on February 19, 2016, 10:08:02 AM
Thanks for the reply Alex seems I might not be boned yet :)

However its not just a few actions we are talking about, the scripting interface seems to want me to cache fsms differently now - for example

Code: [Select]
tempFSM = ActionHelpers.GetGameObjectFsm(child.gameObject,"healthControl");
if(tempFSM != null){
               //do something...

1.8 is now throwing me warnings & errors (if there is no 'healthControl' FSM present on that object).

Also I've noticed that on large fsms where I re-use variables it starts throwing missing variables errors from actions that are not in use.

Its looking like a pretty enormous amount of refactoring so I'm thinking I should roll back until you can take a look at this?
Title: Re: updgrading to 1.8(43) 'Missing Variable' spammage
Post by: jeanfabre on April 12, 2016, 02:04:11 AM

 The procedure is as follow, I just did it last week again with success.

- make sure you upgrade to 1.8 when still in Unity 4 if your project was also in Unity 4 and you want to move to Unity 5

- if you have missing variables errors, launch the updater ( PlayMaker/Tools/Update All Loaded Fsms and PlayMaker/Tools/Update All Fsm's in build). Let them tools run, there is no feedback in the console, so make sure you wait properly if your project is big.

- if this is then fine, backup and upgrade to Unity 5. You'll be fine.

- if you still have errors, get the RC3 version from the beta list this fixes a numbers of missing variables that are actually not true. If you are not part of the beta, send me a pm, you'll need a valid gmail address.