What NOT to do in an Update
JoeB
Member Posts: 160
I'm currently updating my app and I noticed that adding a row or column to an existing table, that's being saved in the previous version will break the app.
Does anyone know of any other game-breaking things that you can do when updating? Thank you in advance!
Comments
If you using Mac version. I haven't seen this. Make sure the save is in a timer after .03 seconds.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
I think @JoeB means that if you release a game that has a table that will be saved, then in an update you modify the table (add rows or columns) the saved table will reset to default when the update to the game is downloaded from the store.
Mental Donkey Games
Website - Facebook - Twitter
Oh you're right. This is correct.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
@MentalDonkeyGames yes, and I was wondering if there are any other things to watch out for when updating apps.
Not really. The main issue is saved info.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
@Lost_Oasis_Games for my app I added a column to one of the tables that I saved on, worked on other parts of the app, then removed the column once I noticed the issue. Is this okay or do I have to go back to a previous version before I put in the column? I'm wondering if there is some kind of data that says 'table is updated' when the user downloads the update.
The table needs to match the game you have on the store. there is no prompt for this kind of update to an app.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
Alright, thank you. And just to be clear, it's okay to add new rows or columns to tables when updating, as long as the table isn't being saved on?
in my experience if you add a column to a table it will overwrite existing ones, i think you are safe with columns.
What I usually do is add a few temp column at the end of any table I save user data. I just make an extra 10 or so, so if i ever need to add a column, it's already there.
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
@jonmulcahy i noticed the issue when I put in a behavior in a new column that tracks what the touch X position is every .1 seconds, and it puts these X positions in that table column. When I tried updating the older adhoc with the new version, the behavior doesn't work at all, nothing was being inputted into the new column. When I tried a fresh install, the behavior worked perfectly.
@JoeB
that should work fine, the problem with tables is if you have a table with 4 columns with a player's save data, then do an update with 5 columns, everything in that table will be wiped fresh, but the game should still function.
Unless your game was relying on something already being there?
Send and Receive Data using your own Server Tutorial! | Vote for A Long Way Home on Steam Greenlight! | Ten Years Left
@jonmulcahy yes I wasn't expecting it not to work because of that, but even after I installed the update over the adhoc, I noticed a couple of crashes after launching app which only disappeared after opening it a couple times. Is installing the newer version over an older adhoc the best way to test if an update won't have conflicts with the older version?
Just adding rolls and columns to existing will also reset the table to default contents.
You can use copy table in order add rolls and column.
But then you must separate out the player's progress content from the original table, otherwise copying table will reset all the contents inside.
Or, if the table save player's progress contents, then you must update the new table (each rows and columns manually) then copy that table to the original table.
I'd call this a bug, even if it is known behaviour. Be sure to submit a bug report!
Contact me for custom work - Expert GS developer with 15 years of GS experience - Skype: armelline.support
@ka822 I added a column in my save file, worked on it for several hours, then noticed the bug and removed the column. Would the old version 'detect' that the table has changed, and that the contents must be reset?
@Armelline okay I will! thank you
I believe there was a thread in the forum previously covering this issue in detail. If I recall correctly, if you add a row or column, the old version will detect that there is new changes, but it will only reset the existing data, it will not add the row and column. And if you have actors that rely on the data from the new row and column, the data doesn't exists so your related actors may have bugged.