Exemple #1
0
        public StationWorker GetStationWorker(FashionGameStation station)
        {
            StationWorker result = null;

            if (station is HoldingStation)
            {
                throw new ArgumentException("HoldingStations don't have workers", "station");
            }
            else if (station is HairStation)
            {
                result = mHairStationWorkers.GetNpc();
            }
            else if (station is MakeupStation)
            {
                result = mMakeupStationWorkers.GetNpc();
            }
            else if (station is TailorStation)
            {
                result = mSewingStationWorkers.GetNpc();
            }
            else
            {
                throw new ArgumentException("Unexpected ModelStation (" + station.GetType().Name + ")");
            }

            return(result);
        }
Exemple #2
0
        private INpcPool GetPoolForStation(FashionGameStation station)
        {
            NpcPool <StationWorker> pool;

            if (station is HairStation)
            {
                pool = mHairStationWorkers;
            }
            else if (station is MakeupStation)
            {
                pool = mMakeupStationWorkers;
            }
            else if (station is TailorStation)
            {
                pool = mSewingStationWorkers;
            }
            else
            {
                throw new ArgumentException("Unexpected station type (" + station.GetType().Name + ")");
            }

            return(pool);
        }