Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Write in game, save it on a .txt and after read it in game again.

Discussion in 'Scripting' started by Duttget233, May 10, 2016.

  1. Duttget233

    Duttget233

    Joined:
    May 10, 2016
    Posts:
    6
    I don't know how to make a script that allow u to write in game something, then save this in a .txt and after when u want it allow u to read what u wrote before and u could rewrite again. To make a example: Like a book wher u can write save it an later read it and if u want repeat the process many times u want. If u need more information ask me and I try to explain more. thx
     
  2. SubZeroGaming

    SubZeroGaming

    Joined:
    Mar 4, 2013
    Posts:
    1,008
  3. Munchy2007

    Munchy2007

    Joined:
    Jun 16, 2013
    Posts:
    1,731
  4. SubZeroGaming

    SubZeroGaming

    Joined:
    Mar 4, 2013
    Posts:
    1,008
    ^ don't do this way. Playerprefs are not a viable way to save.
     
  5. Munchy2007

    Munchy2007

    Joined:
    Jun 16, 2013
    Posts:
    1,731
    Rubbish!

    Explain why, given the information provided by the OP, that PlayerPrefs wouldn't be an acceptable and easy option in this instance.

    Why do so many people jump on the don't use PlayerPrefs bandwagon when it is suggested to use it?

    I've used PlayerPrefs in most of my games. The only time I wouldn't would be for a multiplayer game where players could access data to their own advantage and to the possible detriment of others. In a single player game it really doesn't matter!