Question by
SahanD · Nov 06, 2018 at 05:45 AM ·
arraylistsavescrollviewsave-to-file
How to convert the dynamic list into a array and save it to next scene.
I'm in a project calls "AR shopping app". its a vuforia based ar shopping application. what i need to know is, how to convert the dynamic list into a array and save it to next scene.
1 - adding image with text into the listview using vuforia virtual button.
GameObject Content is for list view content and Game Object ItemTemplate is for the template (image).
using System.Collections; using UnityEngine; using Vuforia;
public class VufBottonTipitip :
MonoBehaviour ,
IVirtualButtonEventHandler{
private GameObject virtualbtn;
public GameObject content;
public GameObject itemTemplate;
// Use this for initialization
void Start()
{
virtualbtn = GameObject.Find("BuyNow");
virtualbtn.GetComponent<VirtualButtonBehaviour>().RegisterEventHandler(this);
}
public void OnButtonPressed(VirtualButtonBehaviour
vb)
{
var copy = Instantiate(itemTemplate);
copy.transform.parent = content.transform;
}
public void OnButtonReleased(VirtualButtonBehaviour
vb)
{
} }
Comment
Your answer
Follow this Question
Related Questions
How to perform this Word Game 0 Answers
Saving and Loading Issues Lists/SetActive/Etc 1 Answer
How to compress iterative code, perhaps using a list and/or loops? 1 Answer
Get all Children of an Object with a certain component 0 Answers
I want to add items from a list into an array using the editor and popup menus 0 Answers