public BugableObjectStateFunctionCell(BugableObjectFunctionInfo info, Object cellPrefab, Transform tableTransform) { GameObject go = Instantiate(cellPrefab, tableTransform) as GameObject; BugableObjectStateFunctionCell script = go.GetComponent <BugableObjectStateFunctionCell>(); script.Init(info); }
public void Init(BugableObjectFunctionInfo info) { functionInfo = info; newPulseColor = newOverlayRender.color; newTransparentColor = new Color(newPulseColor.r, newPulseColor.g, newPulseColor.b, 0); tapPulseColor = tapOverlayRender.color; tapTransparentColor = new Color(tapPulseColor.r, tapPulseColor.g, tapPulseColor.b, 0); newOverlayRender.gameObject.SetActive(false); tapOverlayRender.gameObject.SetActive(false); UpdateView(); }
public void ViewFunction(BugableObjectFunctionInfo info) { PersistentObjectFunction persistentObjectFunction = ds.GetPersistentObjectFunction(info.identifier); persistentObjectFunction.isViewed = true; ds.UpdateObjectFunction(persistentObjectFunction); info.isViewed = true; //Debug.Log("updateFunctionDelegates " + updateFunctionDelegates); UpdateFunctionDelegate(); }
void ReadDatabase(BugableObjectFunctionInfo info) { Debug.Log("read db " + info); PersistentObjectFunction persistentObjectFunction = ds.GetPersistentObjectFunction(info.identifier); if (persistentObjectFunction == null) { //Debug.Log("persistentObjectFunction == null " + info); persistentObjectFunction = new PersistentObjectFunction(); persistentObjectFunction.identifier = info.identifier; info.isViewed = false; ds.InsertObjectFunction(persistentObjectFunction); } else { //Debug.Log("persistentObjectFunction != null " + info); info.isViewed = persistentObjectFunction.isViewed; } }