예제 #1
0
 public void DeleteContentArea(PrivateAreaContent area)
 {
     if (contentAreas.ContainsKey(area.GetPrivateAreaName()))
     {
         contentAreas[area.GetPrivateAreaName()].Remove(area);
     }
 }
예제 #2
0
        public PrivateAreaContent CreateContentArea(Player starterPlayer, string areaClassPath, string contentScript, string areaName, string directorName, params object[] args)
        {
            lock (contentAreasLock)
            {
                Director director = CreateDirector(directorName, true, args);

                if (director == null)
                {
                    return(null);
                }

                if (!contentAreas.ContainsKey(areaName))
                {
                    contentAreas.Add(areaName, new List <PrivateAreaContent>());
                }
                PrivateAreaContent contentArea = new PrivateAreaContent(this, classPath, areaName, 1, director, starterPlayer);
                contentAreas[areaName].Add(contentArea);
                return(contentArea);
            }
        }