Minor improvements and file reorganizing

This commit is contained in:
VoidTwo
2021-11-28 02:52:03 -06:00
parent c4c0c3d02f
commit ffe3312b86
14 changed files with 68 additions and 57 deletions

View File

@@ -67,6 +67,10 @@ func _input(event: InputEvent) -> void:
yield(get_tree(), "idle_frame")
img.flip_y()
if img.save_png('user://screenshot.png') != OK:
var time: Dictionary = OS.get_datetime_from_unix_time(OS.get_unix_time())
var time_msecs: int = OS.get_system_time_msecs()
if img.save_png('user://Screenshot_%d%d%d_%d.png' % [time.year, time.month, time.day, time_msecs]) != OK:
print('ERROR: Failed saving screenshot.')
return