public static QuestionDatabase GetInstance() { if (dbInstance == null) { dbInstance = new QuestionDatabase("../../gameqs.db"); } return(dbInstance); }
//===================================================================== public void MakeEachDoor() { QuestionDatabase db = QuestionDatabase.GetInstance(); Question q = db.GetQuestion(134); this.GetFloor(0).GetRoom(new Point(0, 0)).SetEDoor(new ClosedDoor(q)); q = db.GetQuestion(115); this.GetFloor(0).GetRoom(new Point(0, 1)).SetEDoor(new ClosedDoor(q)); }
public ClosedDoor() { QuestionDatabase db = QuestionDatabase.GetInstance(); this.question = db.RandomQuestion(); }