+ 1
Different output when i use function or directly, cant understand why
If i use it like this, output is always 0: (test3 is a button, lambda fun is called on click, test3) def fun(spawn): print(f"Reaction:{pygame.time.get_ticks()-spawn}") test3.random_click(event,lambda:fun(test3.spawntime)) But if i print it directly, its working normally (numbers are growing but nullified on click(cuz of spawntime is changing ) Full code: https://code.sololearn.com/ch0yG1XQhI5d
2 Answers
+ 1
Maybe because print(f"Reaction:{pygame.time.get_ticks()-test3.spawntime}") has the wrong formating
0
Whats wrong about this?