public bool CanOpen(table.Trailerdatabase trailerdata) { int level = MainPlayerHelper.GetPlayerLevel(); if (level < trailerdata.level) { return(false); } if (trailerdata.task != 0) { return(DataManager.Manager <TaskDataManager>().CheckTaskFinished(trailerdata.task)); } return(true); }
public void SendMsg() { table.Trailerdatabase trailerdata = null; for (int i = 0; i < m_lstdata.Count; i++) { trailerdata = m_lstdata[i]; if (IsOpened(trailerdata.dwId)) { continue; } if (CanOpen(trailerdata)) { m_lstOpenedFunc.Add(trailerdata.dwId); NetService.Instance.Send(new GameCmd.stAddContectPushRelationUserCmd_C() { id = trailerdata.dwId }); } } }
int SortDB(table.Trailerdatabase a, table.Trailerdatabase b) { return((int)(a.showLevel - b.showLevel)); }