New engine features |
Top Previous Next |
Improved map compiler
The map compiler has got two new options: - the ability to set the minimum smooth angle; - a checkbox that allows us to switch the tesselation on or off.
file_date (STRING* name)
Returns the last modification time of a file (in seconds) counted since the 1st of January, 1970.
STRING* compare_str = "#50";
TEXT* compare_txt = { pos_x = 200; pos_y = 200; string(compare_str); flags = SHOW; }
int compare_dates(STRING* file1, STRING* file2) { if (!file1 || !file2) return 0; // at least one of the files is missing? Then get out of here! long date_file1 = file_date(file1); long date_file2 = file_date(file2); if (date_file1 == date_file2) // the date for file1 is equal to the date for file2? return 0; if (date_file1 > date_file2) // the date for file1 is older than the date for file2? return 1; if (date_file1 < date_file2) // the date for file1 is newer than the date for file2? return 2; }
function init_startup() { wait (-3); // wait 3 seconds int compare_result = compare_dates("fire.bmp", "sprite.bmp"); // put these files in your game folder switch (compare_result) { case 0: str_cpy(compare_str, "The files have identical dates"); break; case 1: str_cpy(compare_str, "The first file is newer!"); break; case 2: str_cpy(compare_str, "The second file is newer!"); break; default: str_cpy(compare_str, "Something weird has happened!"); } }
Improved GED
A new version of the in-game editor is available.
|