public static int Display(int luaObjID, int[] icids, float scale, Vector3 targetPos, float offsetX, bool hasScale) { if (icids == null) { return(-1); } int index = 0; Example.PackItem item; for (int i = 0, count = icids.Length; i < count; i++) { if (pack_data.TryGetValue(icids[i], out item)) { items[index] = item; index++; } } Vector3 initPos = new Vector3(targetPos.x, targetPos.y + m_fYOffset, targetPos.z + m_fZOffset); display_size.x = scale; display_size.y = scale; GPUBillboardBuffer_S.Instance().DisplayNumber(luaObjID, camObjID, items, index, display_size, initPos, Color.white, hasScale, offsetX); return(0); }
public static void SetLayer(string layerName) { GPUBillboardBuffer_S gbs = GPUBillboardBuffer_S.Instance(); if (gbs) { gbs.SetLayer(layerName); } }
public static void SetConfig(float[] configs) { GPUBillboardBuffer_S gbs = GPUBillboardBuffer_S.Instance(); if (gbs) { gbs.SetConfigs(configs); } }
private static void EndLoadTex(UnityEngine.Object asset, object param) { if (asset == null) { return; } Texture tex = (Texture)asset; GPUBillboardBuffer_S.Instance().SetTexture(tex); }
private IEnumerator DoLoadScene(string scene) { if (!alive) { yield break; } yield return(new WaitForEndOfFrame()); //begin load scene clear GPUBillboardBuffer_S.Instance().OnLeaveStage(); AsyncOperation asy = UnityEngine.SceneManagement.SceneManager.LoadSceneAsync(scene); yield return(asy); Time.timeScale = 1; }