Exemple #1
0
 internal void CreateNewQuestionary(PollType type)
 {
     if (type == PollType.ROOM_QUESTIONARY)
     {
         this.roomPoll = new RoomQuestionary();
     }
     else if (type == PollType.VOTE_QUESTIONARY)
     {
         this.roomPoll = new VoteQuestionary();
     }
 }
Exemple #2
0
        private void Initialize(RoomData RoomData)
        {
            this.Id = RoomData.Id;

            this.mDisposed         = false;
            this.RoomMuted         = false;
            this.muteSignalEnabled = false;

            this.Bans               = new Dictionary <UInt32, double>();
            this.Mutes              = new Dictionary <UInt32, MuteUser>();
            this.FilterWords        = new List <string>();
            this.chatMessageManager = new ChatMessageManager();
            this.lastTimerReset     = DateTime.Now;
            this.IsRoomLoaded       = false;

            this.mCycleEnded     = false;
            this.HeightMapLoaded = false;

            this.mRoomData = RoomData;

            this.roomMessages     = new Queue();
            this.chatMessageQueue = new Queue();

            this.roomMessages           = new Queue();
            this.roomAlerts             = new Queue();
            this.roomBadge              = new Queue();
            this.roomDiamonds           = new Queue();
            this.roomCredits            = new Queue();
            this.roomPiruletas          = new Queue();
            this.roomKick               = new Queue();
            this.roomServerMessages     = new Queue();
            this.roomChatServerMessages = new Queue();

            this.groupAddQueue    = new Queue();
            this.groupRemoveQueue = new Queue();
            this.groupsOnRoom     = new Dictionary <uint, int>();

            this.roomUserFloorItems = new Dictionary <uint, uint>();
            this.roomUserWallItems  = new Dictionary <uint, uint>();

            this.gamemap          = new Gamemap(this);
            this.roomUserManager  = new RoomUserManager(this);
            this.roomItemHandling = new RoomItemHandling(this);
            this.wiredHandler     = new WiredHandler(this);
            this.games            = new GameManager(this);

            this.roomPoll = new RoomQuestionary();
            if (!this.roomPoll.LoadQuestionary(this.Id))
            {
                this.roomPoll = null;
            }

            this.LoadFilterWords();
            this.LoadRights();
            this.GetRoomItemHandler().LoadFurniture();
            this.GetGameMap().GenerateMaps();
            this.GetRoomUserManager().OnUserUpdateStatus(); // Update Bots State.
            this.LoadMusic();

            if (this.RoomData.State != 3)
            {
                OtanixEnvironment.GetGame().GetRoomManager().QueueActiveRoomAdd(mRoomData);
            }
        }