![]() ![]() Thank you all so much!Īlso if you could dumb it down a little for me, that would be lovely. The value to check if there is a bomb there is 1 and will also turn red. ![]() can anyone help me? I need to be able to go around each adjacent cell and check if there is a bomb there. all the tutorials I have seen don't use basic python, but different versions to the IDLE i use, so I am struggling. however before I can even get there, I need to rectify this. ![]() I am a beginner in python and would also like to start using OOP. _cell(row, exit(self, widget, data=None):Īdding the timer, smiley face, and flags in Minesweeper.I have been trying to figure out a way to check each adjacent cell for my minesweeper game and am coming up short. _start(id, expand=True, fill=True, padding=0)ĭef clicked_handler(self, button, row, col):Ĭell_index = _index(row, col) Print 'Button connect in col '.format(col, row)Ĭell.get_button().connect('clicked', self.clicked_handler, row, col) While mines < (self.rows * ls * self.ratio):įor i, cell in enumerate(_cells()): Self.attach(cell.get_button(), row, col, 1, 1) # with return _sensitive(False) don't show I clicked all board and all buttons are disable. I try do this in my discoverfunction return _sensitive(False) but after that I don't get any value of my buttons. I want to block button after click with set_sensitive() property. I have a problem with show value of label after click using set_sensitive(False).įirst case I use button.hide()after click and this works good, label value are shows up.īut I don't want to use hide(). I write simple minesweeper game in Python 2.7 with Gtk3. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |