public static bool Reload() { try { Dictionary <int, RefineryInfo> dictionary = new Dictionary <int, RefineryInfo>(); dictionary = RefineryMgr.LoadFromBD(); if (dictionary.Count > 0) { Interlocked.Exchange <Dictionary <int, RefineryInfo> >(ref RefineryMgr.m_Item_Refinery, dictionary); } return(true); } catch (Exception exception) { RefineryMgr.log.Error("NPCInfoMgr", exception); } return(false); }
public static bool Reload() { bool result; try { Dictionary <int, RefineryInfo> Temp_Refinery = new Dictionary <int, RefineryInfo>(); Temp_Refinery = RefineryMgr.LoadFromBD(); if (Temp_Refinery.Count > 0) { Interlocked.Exchange <Dictionary <int, RefineryInfo> >(ref RefineryMgr.m_Item_Refinery, Temp_Refinery); } result = true; return(result); } catch (Exception e) { RefineryMgr.log.Error("NPCInfoMgr", e); } result = false; return(result); }
public static bool Init() { return(RefineryMgr.Reload()); }