playMaker

Author Topic: Playmaker is changing the name of a global variable  (Read 36424 times)

terri

  • Sr. Member
  • ****
  • Posts: 386
    • terrivellmann.tumblr.com
Re: Playmaker is changing the name of a global variable
« Reply #60 on: July 31, 2018, 11:20:27 AM »
Personally I've started avoiding Global variables as much as I can. If I am using them I make sure to never swap one for another in an action, instead I'll drag a blank action and re-set all the values but with a new global variable.

I'd consider it broken, and it has been for a while! I'm on Unity 2017.4.1f1 Playmaker 1.8.9

Krillan87

  • Beta Group
  • Full Member
  • *
  • Posts: 185
Re: Playmaker is changing the name of a global variable
« Reply #61 on: September 18, 2020, 11:39:47 AM »
Just wanted to say that this bug is still live and kicking. I just had around 350 variables changes, it took me a solid 2h to get everything back and now I am scared as fuck to even open the Global variables window to see what happening. I have PM version 1.9

Any update on this? Do we know what is causing it? Our game is depending on playmaker and right now it feels very very shakey!

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7614
    • jinxtergames
Re: Playmaker is changing the name of a global variable
« Reply #62 on: September 18, 2020, 02:20:14 PM »
Hi.
Did you try restarting unity before changing.

Also you should also use some version control like github, its very important to always have backups.

and with github you can easily revert changes :)

Krillan87

  • Beta Group
  • Full Member
  • *
  • Posts: 185
Re: Playmaker is changing the name of a global variable
« Reply #63 on: September 18, 2020, 05:25:49 PM »
Hi.
Did you try restarting unity before changing.

Also you should also use some version control like github, its very important to always have backups.

and with github you can easily revert changes :)

Yeah I do backup at the end of the day but this happened around lunch break so it was still faster to redo everything then stat from yesterdays backup.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7614
    • jinxtergames
Re: Playmaker is changing the name of a global variable
« Reply #64 on: September 18, 2020, 06:27:05 PM »
Hi.
You should look into github as you could just revert the Globals file without loosing other changes :)

Currently you have Github Desktop which is easier to use than git

Fat Pug Studio

  • Beta Group
  • Hero Member
  • *
  • Posts: 1294
    • Fat Pug Studio
Re: Playmaker is changing the name of a global variable
« Reply #65 on: September 20, 2020, 09:34:16 AM »
Avoid using globals, they're a freaking mess. I threw out all globals from the project, i made a GlobalsManager FSM that holds all "global" variables locally and i use get fsm float/int/whatever from it.

Though this effectively bans you from changing variable names ever.
Available for Playmaker work

Krillan87

  • Beta Group
  • Full Member
  • *
  • Posts: 185
Re: Playmaker is changing the name of a global variable
« Reply #66 on: September 20, 2020, 10:25:47 AM »
Avoid using globals, they're a freaking mess. I threw out all globals from the project, i made a GlobalsManager FSM that holds all "global" variables locally and i use get fsm float/int/whatever from it.

Though this effectively bans you from changing variable names ever.

Yeah I have always been reluctant to use globals but in our project we only use 3 (The three main characters)game objects at global since they are used a lot. However, your strategy is maybe something to consider

Fat Pug Studio

  • Beta Group
  • Hero Member
  • *
  • Posts: 1294
    • Fat Pug Studio
Re: Playmaker is changing the name of a global variable
« Reply #67 on: September 29, 2020, 01:46:18 PM »
Yeah i use global variables for main camera, player, "globals" manager itself, array proxy object that stores arrays for data and that's it, they have few thousand calls so it made sense to keep them in globals. Until Alex makes things better (in PM2 hopefully), that's the way to go, along with some nice groups.
Available for Playmaker work

AtomicJoe

  • Playmaker Newbie
  • *
  • Posts: 10
Re: Playmaker is changing the name of a global variable
« Reply #68 on: August 06, 2022, 09:01:33 PM »
Is this bug still alive?
I had this bug in 2013 (!) and was the reason I completely ditched Playmaker.
Now I see reports of 2020 of the bug still kicking!
I was planning to use Playmaker again, but if a global bug like this one hasn't been fixed in 9 years, I really don't know what to think about Playmaker!

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3985
  • Official Playmaker Support
    • LinkedIn
Re: Playmaker is changing the name of a global variable
« Reply #69 on: August 13, 2022, 12:52:46 AM »
I think we fixed the last edge case where this happened in 1.9.1p4 released beginning of '21. Unity made a lot of changes to the ways prefabs work in the last 10 years, so it was a tricky bug to reproduce and fix across unity versions. This was definitely a cursed feature :-[

AtomicJoe

  • Playmaker Newbie
  • *
  • Posts: 10
Re: Playmaker is changing the name of a global variable
« Reply #70 on: August 13, 2022, 01:06:55 AM »
Thanks for the heads-up Alex!