Пример #1
0
        public static RoomEdges GetDefaultEdges(IGame game)
        {
            RoomEdges e = new RoomEdges();

            e.Top    = defaultOffset;
            e.Left   = defaultOffset;
            e.Bottom = game.Settings.WindowSize.Height - defaultOffset;
            e.Right  = game.Settings.WindowSize.Width - defaultOffset;

            return(e);
        }
Пример #2
0
        //private const string _baseFolder = "../../Assets/Rooms/DarsStreet/";

        public FakeAGSRoom(IGame game, string id, AssetDef def, RoomEdges edges = null)
        {
            _id    = id;
            _game  = game;
            _edges = edges;
            _def   = def;


            if (_edges == null)
            {
                _edges = RoomEdges.GetDefaultEdges(_game);
            }

            _room = _game.Factory.Room.GetRoom(_id, _edges.Left, _edges.Right, _edges.Bottom, _edges.Top);

            subscribeEvents();
        }