SQL-Dateien enthalten Aktivierung für neu ausgesetzte Parteien

This commit is contained in:
Enno Rehling 2002-03-24 12:31:38 +00:00
parent d5daf1aa8e
commit 0577ad3399
2 changed files with 8 additions and 3 deletions

View File

@ -1200,12 +1200,12 @@ quit(void)
f->nunits, f->number, f->money);
fprintf(sqlstream,
"UPDATE subscriptions SET lastturn=%d, password='%s', info='%s' "
"WHERE game=%d AND faction='%s';",
"WHERE game=%d AND faction='%s';\n",
f->lastorders, f->override, info, GAME_ID, itoa36(f->no));
} else {
fprintf(sqlstream,
"UPDATE subscriptions SET lastturn=%d, password='%s' "
"WHERE game=%d AND faction='%s';",
"UPDATE subscriptions SET status='ACTIVE', lastturn=%d, password='%s' "
"WHERE game=%d AND faction='%s';\n",
f->lastorders, f->override, GAME_ID, itoa36(f->no));
}

View File

@ -2177,6 +2177,11 @@ readfaction(FILE * F)
}
f->lastorders = ri(F);
f->age = ri(F);
if (sqlstream && f->age==0) {
fprintf(sqlstream,
"UPDATE users SET status='ACTIVE' where email='%s';\n",
f->email);
}
if (global.data_version < NEWRACE_VERSION) {
race_t rc = (char) ri(F);
f->race = new_race[rc];