Python Forum
Need help fixing Time and Score issues
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Need help fixing Time and Score issues
#2
1. Code need better organize. Very hard to follow.

2. score has to be 1000 or better to show time or score. Because of this line.
if  (int(score / BONUS_SCORE) > bonus:
suggestion: take them out of if block.

3. errors that haven't show up yet.
score_text and time_text must be above function.

To make more readable
1. put all const together
2. make a function for main game.
this is where changable variables go.
3. use better variables names. Like c should be canvas. something readable.
just a suggestion like score_text to me should be score_id.
4.
from tkinter import *
It just bad to flood namespace. No matter what tutorials says.
use something like this instead
import tkinter as tk
5. Just because this bothers me. in create_ybloc() remove the y from everywhere. Just a waste of cpu cycles.
99 percent of computer problems exists between chair and keyboard.
Reply


Messages In This Thread
RE: Need help fixing Time and Score issues - by Windspar - Nov-16-2017, 10:13 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Time limit and Score not working Coding help Kingrocket10 1 3,034 Nov-09-2017, 03:20 PM
Last Post: heiner55

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020