How can I make this script save and or load what I do in my game??

I need help, I am trying to just make a single player RPG very low quality and kinda similar to the older runescape. I can’t seem to figure something out although. Right now I wrote a script so if I type in the AccountID field, “admin”. And the Password field, “admin”. And click “LogIn” Then it will do what I tell it. It works, I tested it and when I click Log in it replys to the console “ID & Password Are Correct.” (I know how to Application.LoadLevel and all that) But I don’t know how to make it to where while playing the game it’s saving everything that changes when my XP goes up, if I pick up some new items in the game. So when I go back to the game, type in my info and click log in it loads the players saved/stored information ie; items, experience, etc. How would I go about doing this? Here is my current code for the part mentioned above, i left out a couple other parts like the other gui buttons, this is just an example.

PS. I don’t care if i have to make more scripts than just one (Im sure I can’t get what im wanting to do into just a single script.

var stringToEdit : String = "AccountID";

var passwordToEdit : String = "My Password";

function OnGUI
	// Make a text field that modifies stringToEdit.
	stringToEdit = GUI.TextField (Rect (260, 240, 136, 20), stringToEdit, 25);
    // Make a password field that modifies passwordToEdit.
	passwordToEdit = GUI.PasswordField (Rect (266, 262, 138, 20), passwordToEdit, "*"[0], 25);	
    if (GUI.Button (new Rect(288,340,98,22), "Log In")) //If "Log In" button is pressed.
		if(stringToEdit == "admin" && passwordToEdit == "admin") //If The text field is equal to "admin" and the password field is equal to "admin".
    		print("ID & Password Are Corect.");

my advice for you is to study this:

This will create a file inside your application files, that will never be erased, unless you erase it by code or manually.
Because of that you can use those files to save all your characters infos.
Take care.

Hello again,
it’ll be something like this:

using UnityEngine;
using System.Collections;

public class Inventory : MonoBehaviour {
	public string[] itens = new string[20];
	// Use this for initialization
	void Start () {
	// Update is called once per frame
	void Update () {
	void saveInventory(){
		//Lets consider that you have all your inventory listed inside a array (created at the start of the class)
		//The array size is the size of slots of your inventory
		//What you will have to do is to save all those itens inside the player prefs so you can access them every time that
		//It will be something like this
		for (int i = 0; i < itens.Length; i++) {
			//Here i create the name of the key
			string inventorySlot = "InventorySlot";
			//And here i change the name so it will access all the positions
			inventorySlot = inventorySlot + i.ToString();
			//And here i save to PlayerPrefs
  •  	//Just remember that your array start to count on 0.*
  •  	//So if you have 20 positions, those positions will be 0-19*
  •  	//So the first slot will be InventorySlot0*
  •  	//The second will be InventorySlot1, and so on untill InventorySlot19*
  •  }*
  • }*