public static void EnterRoom(Session Session, RoomInstance Instance) { if (!Session.RoomAuthed || Session.RoomJoined || Session.AbsoluteRoomId != Instance.RoomId) { return; } Session.SendData(RoomUrlComposer.Compose("http://www.meth0d.org/snowlight")); Session.SendData(RoomEntryModelComposer.Compose(Instance.Model.Id, Instance.Info.Id)); if (Instance.Info.Type == RoomType.Flat) { Dictionary <string, string> Decorations = Instance.Info.Decorations; foreach (KeyValuePair <string, string> Decoration in Decorations) { Session.SendData(RoomDecorationComposer.Compose(Decoration.Key, Decoration.Value)); } Session.SendData(RoomRatingInfoComposer.Compose((Session.RatedRoomsCache.HasRatedRoom(Instance.RoomId) || Instance.CheckUserRights(Session, true)) ? Instance.Info.Score : -1)); Session.SendData(RoomEventInfoComposer.Compose(Instance.Event)); } }
public void BroadcastEventData() { BroadcastMessage(RoomEventInfoComposer.Compose(mEvent)); }