1
\$\begingroup\$

I've been looking for ways to save data in a visual novel, I have seen that the best way to do  is with shared object but the tutorials are usually saved scores and I want to save the history progression

how can I do it?

Which variable should be used?

What should contain the variable?

shared object works for android and ios?

Thanks  for reading

\$\endgroup\$
1
  • \$\begingroup\$ Game state in a visual novel is usually just which dialog frame is currently displayed, plus all the variables which represent relevant decisions the player made. \$\endgroup\$ Commented Apr 23, 2016 at 20:07

1 Answer 1

1
\$\begingroup\$

It doesn't really matter what you call your variable when you save it. Just figure out what you need and go from there.

For example, if you need to save page number, scroll position and audio level, you may just have direct variables like page_position, scroll_position etc.

You can also save objects, so your variable could be named "state" with state being an object like

{ page: 1,  scroll:45%, audio:80% }

Then it's up to you to read this variable (likely at the start of the app) and handle it appropriately (such as returning the user to that location)

\$\endgroup\$

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.