Once daily actions

Boogaloogaloo

New member
Am I missing something obvious in how the various scripts perform some actions only once a day (version checks and such)? Even after quitting and starting KoLmafia again, the actions are not run again.

The only way I can possibly see this working is that some properties (maybe all) are cleared on each new day. What is KoLmafia actually doing here?
 
Last edited:

zarqon

Well-known member
There are a few other cases:

Before the "properties starting with _" thing was implemented, there were still a good number of properties which were reset daily. These were not later preceded with "_", most likely for legacy reasons, so there are still mafia settings which are cleared daily that do not have the initial _.

Some scripts use the ASH function today_to_string() to store the current date in a property. Then, when the script is run again, it checks that property to determine whether or not to perform the action again.
 

Bale

Minion
Some scripts use the ASH function today_to_string() to store the current date in a property. Then, when the script is run again, it checks that property to determine whether or not to perform the action again.
Yeah, but that method sucks thanks to the existence of time zones. ;) That's why nobody uses it anymore once Jason implemented _properties.
 

zarqon

Well-known member
I've used it successfully in Korea, which is at least 12 hours off of the KoL day.
 

Bale

Minion
If so, then you always do it around the same time each day. I've run into problems when playing both before rollover and after rollover on the same day in my timezone. I hate that.
 
Top