[patch] Scripts on new day, month, year

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

Post Reply
User avatar
Traffic Manager
Traffic Manager
Posts: 185
Joined: 21 Dec 2004 05:35
Skype: andrey-zaharov
Location: St. Petersburg, Russia

[patch] Scripts on new day, month, year

Post by Vaulter »

This is very simple patch to invoke your scripts on new day, new month and new year. Scripts been invoked after all routines (industries updates, finances updates and so on).
scripts should have names:
  • scripts/on_newday.scr
  • scripts/on_newmonth.scr
  • scripts/on_newyear.scr
For example simple on_newday.scr

Code: Select all

will gives you in console:

Code: Select all

Date: 1-1-1950
Date: 2-1-1950
Date: 3-1-1950
Date: 4-1-1950
Date: 5-1-1950
for tags/1.0.3
(909 Bytes) Downloaded 434 times
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 1 guest