public Pathfinder(Heightmap Map, HabboRoomObject Session) { AvaliablePoints = new Point[] { new Point(0, -1), new Point(0, 1), new Point(1, 0), new Point(-1, 0), new Point(1, -1), new Point(-1, 1), new Point(1, 1), new Point(-1, -1) }; MapSizeX = Map.SizeX; MapSizeY = Map.SizeY; Squares = Map.TileStates; this.User = Session; }
public void LoadRoomModels(int userId) { using (ISession session = ApiRoot.DatabaseCallback.GetDatabase().GetSessionFactory().OpenSession()) { foreach (RoomSql data in RoomEngine.GetRoomByOwner(userId)) { model = session.Get<roommodel>(data.id); doorX = model.doorX; doorY = model.doorY; doorZ = model.doorZ; //doorDir = model.doorDir; heightmap = model.heightmap; privateItems = Convert.ToString(model.publicItems); clubOnly = Convert.ToInt32(model.clubOnly); this.roomId = data.id; map = new Heightmap(); map.SetMap(heightmap); //habboObject = new HabboRoomObject(userId, data.id, ); //RoomModels.Add(model.id, this); } } }