Save Table - frequency and performance

mhedgesmhedges Raised on VCSMember Posts: 634

Hello -

I'm building a game which very frequently changes table values.

How frequently should I Save Table? Also, does that behavior cause a hit on performance?

Thanks, regards.

Comments

  • mhedgesmhedges Raised on VCS Member Posts: 634

    Follow-up question:

    If I were to make an app with tables in which values are stored and saved, if I were to update the game to another version, are the saved tables affected?

  • Braydon_SFXBraydon_SFX Member, Sous Chef, Bowlboy Sidekick Posts: 9,273

    @mhedges said:
    Hello -

    I'm building a game which very frequently changes table values.

    How frequently should I Save Table? Also, does that behavior cause a hit on performance?

    Thanks, regards.

    I usually save where it's logical to save. For example, is there a game over or level complete function? That may be a good place to save a table. Saving a table every few seconds is okay, but the question you should ask yourself is where does it make sense to save the table?

  • mhedgesmhedges Raised on VCS Member Posts: 634

    @Braydon_SFX ,

    I'm trying out a clicker-type game. In theory, these don't have an ending per se, so that's why I'm wondering. I write to the table when I perform a behavior, which is frequent, yet performance does not seem to have taken a hit. And of course, you know there is no close/quit button in iOS, just the home button.

    I could do some timer a la autosave, but in theory you could miss out on an important save if you hit the home button before the next autosave. So then the timer should be pretty short if I pursue that avenue.

Sign In or Register to comment.