Example #1
0
    public void AddSaveFile(GameObject nullFile)
    {
        int FileId = nullFile.GetComponent <NullFileItem>().FileID;

        Debug.Log("当前文件索引" + FileId);
        nullFile.SetActive(false);
        GameObject go = Instantiate(SaveFileItemPrefab, SaveFileItemParent.transform);

        go.transform.SetSiblingIndex(nullFile.transform.GetSiblingIndex());

        SaveFileItem saveFileItem = go.GetComponent <SaveFileItem>();

        saveFileItem.FileID            = FileId;
        saveFileItem.CurrentLayer.text = UIManager.instance.playerMenu.CurrentLayer.text;
        saveFileItem.GetNewData(FileId);
    }
Example #2
0
 public void OverrideSaveFile(SaveFileItem saveFile)
 {
     saveFile.GetNewData(saveFile.FileID);
 }