void Start() { frameBuffer = GetComponent<FrameBuffer>(); renderTexture = frameBuffer.GetCurrentTexture(); rect = new Rect(0f, 0f, Game.width, Game.height); texture2D = new Texture2D((int)Game.width, (int)Game.height); colorArray = new Color[(int)Game.width * (int)Game.height]; if (collectibleList == null) { collectibleList = new List<Collectible>(); } position = Vector2.zero; }
void Start() { frameBuffer = GetComponent <FrameBuffer>(); renderTexture = frameBuffer.GetCurrentTexture(); rect = new Rect(0f, 0f, Game.width, Game.height); texture2D = new Texture2D((int)Game.width, (int)Game.height); colorArray = new Color[(int)Game.width * (int)Game.height]; if (collectibleList == null) { collectibleList = new List <Collectible>(); } position = Vector2.zero; }