Skip to content

Instantly share code, notes, and snippets.

@toreau
Created March 15, 2014 18:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save toreau/f7110f0eb266c3c12f1b to your computer and use it in GitHub Desktop.
Save toreau/f7110f0eb266c3c12f1b to your computer and use it in GitHub Desktop.
//
// InventoryController
//
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
[System.Serializable]
public class InventoryController : MonoBehaviour {
public Inventory _inventory;
public int numberOfSlots;
public Inventory inventory {
get {
return _inventory;
}
}
// Awake
void Awake () {
Debug.Log ( "InventoryController::Awake" );
_inventory = new Inventory ( numberOfSlots );
Debug.Log ( "Successfully created a new inventory with " + inventory.slots.Count + " slots!" );
}
// Use this for initialization
void Start () {
Debug.Log ( "InventoryController::Start" );
}
// Update is called once per frame
void Update () {
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment