public void AddPlayerScores(PlayerProfile profile, PlayerScoreData scoreData) { if (!PlayerProfiles.Contains(profile)) { PlayerProfiles.Add(profile); } playerScoreMap[profile] = scoreData; }
public static CentralGumpProfile EnsureProfile(PlayerMobile pm) { if (pm == null) { return(null); } CentralGumpProfile p; if (!PlayerProfiles.TryGetValue(pm, out p)) { PlayerProfiles.Add(pm, p = new CentralGumpProfile(pm)); } else if (p == null) { PlayerProfiles[pm] = p = new CentralGumpProfile(pm); } return(p); }