GameSalad

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Daily WTF moment: Bug in loading and saving attributes (IMPORTANT!!!!)

hmchan4hmchan4 Posts: 21Member
edited December 2011 in Tech Support
I am frustrated by these bug and they tortured me for nearly a week.

It starts with the phenomena that I cannot load the attributes that I saved just now in the previous scene.
I started to check whether I am doing anything wrong with the settings and every spelling in the project. Nothing wrong found.(1st WTF moment)

Then I start thinking: There maybe some "misunderstanding" with the game engine, in other words "hidden rules", AKA "BUG"
I start importing those load and save rules into another new project one by one, then I figure out WTF is going on here (2nd WTF moment)

items:
1) You cannot name the persistent memory with name containing '_' e.g weapon_status
2) You cannot name the persistent memory with name ending with numbers e.g weapon1
3) You cannot rename the function for load and save attributes (3rd WTF moment, it took me nearly half-day to figure it out)

Up to here, I want to express my feeling.
Well, this is the PUNISHMENT FOR HAVING SO-CALLED "NAMING CONVENTION" AND "ORGANIZED CODING" FROM GAMESALAD.
I think many programmers may feel that they got their **** KICKED!!!!

During the process, I cannot find any useful piece of information telling me the rules with the naming of attributes.
NO WIKI AT ALL !!!! I WANT THE WIKI BACK ONLINE AND A FULL DESCRIPTION WITH THE RULES OF USING THE FUNCTION AND BASIC SIMPLE USAGE EXAMPLE OF THE FUNCTION.

The cook book example is very GD but they are integrated one and are videos. We do need integrated example but we also need some non-integrated one. You cannot isolate the rules with using the function and you cannot see how to set it because the word in the video is too small. Please, please, give a wording version of the tutorial, sample project, restoration of the online wiki and a more detailed manual on the function description. NO ONE WOULD KNOW WHAT SHOULD NOT BE DONE IF YOU DON'T TELL ANYONE HOW TO DO IT CORRECTLY!!!!

The most amazing part is that it can still run but LOAD NOTHING!!! WTF!!!! Are you guys god dame kidding here?!!! Give more info on the debug window, please!

Comments

  • hmchan4hmchan4 Posts: 21Member
    Well , I found 1 more:
    You cannot add number into name of persistent attribute name e.g weapon1status

    WOOO!!! EPIC FAILURE!!!!
  • hmchan4hmchan4 Posts: 21Member
    At the mean while, I do find that I CANNOT SAVE MORE THAN 1 PERSISTENT VARIABLE!!!!!!

    This have been reproduced in a new empty project.....
  • DigiChainDigiChain Posts: 1,216Member, PRO
    Hi, I'm not sure I've really followed whats been said here but I certainly use numbers in my attributes to be saved/loaded - and I use the same names for the save/load keys too.

    eg: key 'Door3' is used to load the attribute 'Door3'. All works fine.

    Maybe I'm not understanding your issue properly though?
  • tenrdrmertenrdrmer Posts: 9,934Member, Sous Chef, Senior Sous-Chef
    First Have you sent in bug reports with your project files? It sounds to me like you are simply not using Save/Load Properly.

    I have never had any issues with save/load working when its been setup right. I'd suggest heading over to the cookbook. I believe their is a video tutorial on how to use save/load im sure you have just missed a step. Something like using the keys for save and load would be my guess.

    It's not my fault I never learned to take responsibility for anything. ;)

  • Braydon_SFXBraydon_SFX Posts: 8,960Member, Sous Chef, PRO, Bowlboy Sidekick GameSalad Employee
    Hi,

    Something I have come across is that if you are using an actor not on the screen to load the attributes, it can only work with 2 load attributes for some reason.
    I don't know if this is what your wondering about, but I usually have 2 or 3 actors with my load attributes, I don't know why, it just doesn't work the other way.

    Hope this helps,
    Bray
  • tenrdrmertenrdrmer Posts: 9,934Member, Sous Chef, Senior Sous-Chef
    Penguin Glide has one actor on the menu that loads around 50-60 attributes all in one shot. It is inside the camera view so I don't know if that has any effect. but why not just put it in the camera and uncheck visible if that is an issue.

    It's not my fault I never learned to take responsibility for anything. ;)

  • DigiChainDigiChain Posts: 1,216Member, PRO
    I have a single actor (inside the camera view) that loads/saves over 200 attributes - works no problems at all.
  • Braydon_SFXBraydon_SFX Posts: 8,960Member, Sous Chef, PRO, Bowlboy Sidekick GameSalad Employee
    edited December 2011
    Must be me, then. :) Although, mine are boolean attributes.
  • mynameisacemynameisace Hull, UKPosts: 2,484Member
    edited December 2011
    I always have an actor off the screen that loads a tonne of attributes... Must be you and your pesky red bowl ring :)

    One problem that it could be (other than user error) is that you are entering the save/load keys in the expression editor. Clear the expression and type it in the text box, not the expression editor.

    The save/load attribute function in Gamesalad is super stable, therefore I don't feel many programmers do actually 'feel like they got their **** kicked'.

    Ace
  • Braydon_SFXBraydon_SFX Posts: 8,960Member, Sous Chef, PRO, Bowlboy Sidekick GameSalad Employee
    @ace,
    Indeed ;)
  • hmchan4hmchan4 Posts: 21Member
    edited December 2011
    Hey guys, thanks for the suggestion!!!

    I have already submitted a regenerated project fault case for the development team to study. I don't think they are going to reply me in these few days. LOL
    Yes, I have read through the cookbook for load and save property.
    Yes, all works except after using attributes with '_' or numbers in the name

    Anyway, a wiki and a manual with full functional and parameter format is a must!!!
  • tenrdrmertenrdrmer Posts: 9,934Member, Sous Chef, Senior Sous-Chef
    How about you upload your test project so we can see what you have going nearly e dry attribute name I have has numbers in them. Upload it to media fire and post the download link in sure we can get you sorted out.

    It's not my fault I never learned to take responsibility for anything. ;)

  • hmchan4hmchan4 Posts: 21Member
    In detail, this is what I am doing
    1) in "scene 1", we save the attribute A with key B and C
    2) in next scene "scene 2", we load the attribute D with key B and attribute E with key C

    Would that work?
  • hmchan4hmchan4 Posts: 21Member
    Thank you, thank you very much for the help.

    Tenrdrmer, here is the game project
    http://www.mediafire.com/?v732ha4ia4sd7l9
  • hmchan4hmchan4 Posts: 21Member
    For attribute A , the reason to save in key B and C is that I consider A as some kind of "constant"
  • tenrdrmertenrdrmer Posts: 9,934Member, Sous Chef, Senior Sous-Chef
    Well I guess Im completely missing your issue here. The project you uploaded works just fine. I even changed the loading attributes around using the same key and still it worked. Yes I changed the attribute being displayed to match the one being loaded.

    It's not my fault I never learned to take responsibility for anything. ;)

  • hmchan4hmchan4 Posts: 21Member
    ooooo, i see. let me look through

  • hmchan4hmchan4 Posts: 21Member
    edited December 2011
    @mynameisace, YOU ARE THE BOSS!!!!!
    I tried you method and you are right!!!!!! I have exactly the same input pattern as you have said!!!!!!

    YAHOOOOOO!!!!!!!!
  • hmchan4hmchan4 Posts: 21Member
    edited December 2011
    BTW, what is the usage of expression in key field?
    Anyone know what is not permitted to used as attributes and key name?
  • mynameisacemynameisace Hull, UKPosts: 2,484Member
    It is the most pointless thing in the world, it should be removed in my opinion, it just causes problems!

    Glad I could have helped.

    Ace
  • tenrdrmertenrdrmer Posts: 9,934Member, Sous Chef, Senior Sous-Chef
    you can use what ever you want. The expression editor is there so you could call a variety of keys based on calculations. So instead of 20 rules to check which of 20 possible keys should load you can have one behavior that calls for a calculated key based on attributes.

    It's not my fault I never learned to take responsibility for anything. ;)

  • hmchan4hmchan4 Posts: 21Member
    Could you demo or show some thing like string concatenation?
    This is what I think of when you talk about the expression editor, @tenrdrmer
  • mynameisacemynameisace Hull, UKPosts: 2,484Member
    edited December 2011
    @tenrdrmer - Does it work on the save keys? I was under the impression it didn't, but in all fairness haven't tried it :)

    Ace
  • tenrdrmertenrdrmer Posts: 9,934Member, Sous Chef, Senior Sous-Chef
    No the save you cannot use an expression but on the load you can.

    I have never actually tried it but it should work. The logic is

    you can save key1, key2, key3, key4, key5

    Then for your load key would look something like

    ("key"..game.keynumber)

    And then based on what every you have game.keynumber set to at the time it will load the key you want. I'm not sure how practical it actually is. but thats the logic of it at least. :)

    Cheers

    It's not my fault I never learned to take responsibility for anything. ;)

  • hmchan4hmchan4 Posts: 21Member
    Thank for the help from both of you.

    I think I have tried that before (the '..' style) and it is not working
    Anyway, I will give a try.
    Cheers!!!!!
  • imGuaimGua Posts: 1,089Member
  • jfoc2009jfoc2009 Posts: 12Member
    Please, can some one put o details for dummies guy what have been done to solve the problem ?
    I'm facing same problem and double-checked all behaviors, attributes names, keys name, etc...
    Last thing done was removing Key name and typing again out of expression editor as suggested by ace.
  • hmchan4hmchan4 Posts: 21Member
    Hi , jfoc2009
    As said by mynameisace, this is the problem when you use expression editor to type in the save attribute key and load key

    If you have similar pattern, you need to
    1) clear all the content in the key field
    2) type again
    3) done!!

    This is my case
    Also, don't try any fancy naming in the key field (like using string concatenation)

    I suggest that you open a small new project and try to simulate the variable name and key name used
    Try to spot the problem one by one.
  • HymloeHymloe Posts: 1,651Member
    GREAT! Thanks. Finally got Save and Load Attributes working by taking note of the comments here.
    I'd entered my key name into the Expression Editor.
    Thanks for the advice!
    - Murray
This discussion has been closed.