瀏覽代碼

Force all players offline in sql when char-server starts

git-svn-id: https://svn.code.sf.net/p/rathena/svn/trunk@7977 54d463be-8e91-2dee-dedb-b68131a5f0ec
toms 19 年之前
父節點
當前提交
7d36341087
共有 2 個文件被更改,包括 6 次插入0 次删除
  1. 2 0
      Changelog-Trunk.txt
  2. 4 0
      src/char_sql/char.c

+ 2 - 0
Changelog-Trunk.txt

@@ -3,6 +3,8 @@ Date	Added
 AS OF SVN REV. 5091, WE ARE NOW USING TRUNK.  ALL UNTESTED BUGFIXES/FEATURES GO INTO TRUNK.
 IF YOU HAVE A WORKING AND TESTED BUGFIX PUT IT INTO STABLE AS WELL AS TRUNK.
 
+2006/07/30
+	* Force all users offline in sql when char-server starts [Toms]
 2006/07/29
 	* Removed ugly struct cast in login.c [Toms]
 	* New version of buildin_query_sql which accept more than one column and

+ 4 - 0
src/char_sql/char.c

@@ -1249,6 +1249,10 @@ int mmo_char_sql_init(void) {
 	//it will dc all off players
 	//and send the loginserver the new state....
 
+	// Force all users offline in sql when starting char-server
+	// (useful when servers crashs and don't clean the database)
+	set_all_offline_sql();
+
 	ShowInfo("Finished initilizing.......\n");
 
 	return 0;