Page 1 of 1

Printing In Console Performance

Posted: Sat Apr 19, 2014 9:14 pm
by TheScriptan
I want to ask a simple question, does printing in console very often costs some performance? For example I have set up a bullet class and every time bullet gets out of the boundary I print that bullet got destroyed and destroy it afterwards?

Re: Printing In Console Performance

Posted: Sat Apr 19, 2014 9:26 pm
by TomcisUMB
Yes becuse it needs to check if it left boundry

Re: Printing In Console Performance

Posted: Sat Apr 19, 2014 9:36 pm
by TheScriptan
I check boundaries, because I want to delete the bullet when it's off the boundaries, I asked if command print(), cost performance if I use it very often (not in update or spamming loop or something like that). As I said I use print() statement before turret gets destroyed

Re: Printing In Console Performance

Posted: Sat Apr 19, 2014 11:27 pm
by WetDesertRock
The occasional print won't do much, but if you print several times every frame you'll notice something.

Re: Printing In Console Performance

Posted: Sun Apr 20, 2014 12:10 pm
by Jeeper
Printing in the console should only be done for debugging etc, so when your game is done you remove the console. Why would a slight performance reduction be of any concern?