public static sceneTag updateTag(sceneTag tag, float fps) { sceneTag res = new sceneTag(tag); res.count++; res.totalFps = tag.totalFps + fps; return(res); }
void updateTagList(String inFps) { float fps; if (!float.TryParse(inFps, out fps)) { Debug.Log("FpsMonitor: receive error fps arg from java"); fps = 0; } if (tagList.ContainsKey(getSceneTagName())) { sceneTag tag = sceneTag.updateTag(tagList[getSceneTagName()], fps); tagList[getSceneTagName()] = tag; } else { tagList.Add(getSceneTagName(), new sceneTag(fps)); } saveSceneTagList(); }
// copy constructor private sceneTag(sceneTag tag) { totalFps = tag.totalFps; count = tag.count; }