Now changelog is shown only if it was changed since last login.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@766 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
rastaf.zero@gmail.com
2011-01-04 02:03:05 +00:00
parent 5081c24989
commit c0010f08c3
4 changed files with 14 additions and 3 deletions
@@ -38,6 +38,7 @@ datum/preferences/proc/savefile_save(mob/user)
F["be_alien"] << src.be_alien // Urist
F["midis"] << src.midis // Urist
F["ooccolor"] << src.ooccolor // Urist
F["lastchangelog"] << src.lastchangelog // rastaf0
return 1
@@ -94,6 +95,7 @@ datum/preferences/proc/savefile_load(mob/user, var/silent = 1)
F["be_alien"] >> src.be_alien // Urist
F["midis"] >> src.midis // Urist
F["ooccolor"] >> src.ooccolor // Urist
F["lastchangelog"] >> src.lastchangelog // rastaf0
return 1
#undef SAVEFILE_VERSION_MAX
+1 -2
View File
@@ -35,8 +35,7 @@
src.next_move = 1
src.sight |= SEE_SELF
src.logged_in = 1
if (!src.client.changes)
src.changes()
if(istype (src, /mob/living))
if(ticker)
if(ticker.mode.name == "revolution")
+10 -1
View File
@@ -37,7 +37,16 @@ mob/new_player
if(!preferences.savefile_load(src, 0))
preferences.ShowChoices(src)
if (src.client.changes)
src.changes()
else
var/lastchangelog = length('changelog.html')
world << "DEBUG: lastchangelog = [lastchangelog]"
world << "DEBUG: preferences.lastchangelog = [preferences.lastchangelog]"
if (!src.client.changes && preferences.lastchangelog!=lastchangelog)
src.changes()
preferences.lastchangelog = lastchangelog
preferences.savefile_save(src)
//PDA Resource Initialisation =======================================================>
@@ -7,6 +7,7 @@ datum/preferences
var/be_syndicate
var/midis = 1
var/be_alien = 1
var/lastchangelog = 0 // size of last seen changelog file -- rastaf0 -- rastaf0
var/ooccolor = "#b82e00"
var/be_random_name = 0
var/underwear = 1