[ScryMUD] SVN Commit Info r947 - trunk/mud/grrmud/server

scrymud at wanfear.com scrymud at wanfear.com
Sun Jun 10 22:32:33 PDT 2007


Author: eroper
Date: 2007-06-10 22:32:33 -0700 (Sun, 10 Jun 2007)
New Revision: 947

Modified:
   trunk/mud/grrmud/server/necromancer.cc
   trunk/mud/grrmud/server/pfile_maint.cc
Log:
Fixed a spell message typo.

A while back the "tammuz" spell got set to skill #0 on the production port.
Turns out that a lot of ScryMUD code isn't happy with this (though some of it
doesn't care). As a result it, among other things, broke a lot of skill/spell
help. The pfile maintenance will now check and see if players know skill #0,
removing it if they do. It will then retrain any remorts with the new,
appropriate skill #.



Modified: trunk/mud/grrmud/server/necromancer.cc
===================================================================
--- trunk/mud/grrmud/server/necromancer.cc	2007-06-11 05:14:59 UTC (rev 946)
+++ trunk/mud/grrmud/server/necromancer.cc	2007-06-11 05:32:33 UTC (rev 947)
@@ -848,7 +848,7 @@
     agg.show("The world grows dim as black specks dance in your vision.\n");
 
     String buf(100);
-    agg.pemote("eyes come to life as black specks begin an intricate within them.");
+    agg.pemote("eyes come to life as black specks begin an intricate dance within them.");
 
 }//cast_spirit_ritual()
 

Modified: trunk/mud/grrmud/server/pfile_maint.cc
===================================================================
--- trunk/mud/grrmud/server/pfile_maint.cc	2007-06-11 05:14:59 UTC (rev 946)
+++ trunk/mud/grrmud/server/pfile_maint.cc	2007-06-11 05:32:33 UTC (rev 947)
@@ -28,6 +28,7 @@
 
 #include "critter.h"
 #include "command2.h"
+#include "misc2.h"
 
 //loads all pfiles and saves them again. Useful for upgrading pfile versions
 //and making sure sanitization gets applied to everyone.
@@ -95,6 +96,18 @@
          }
       }
 
+      // at some point tammuz became skill-number 0 in SKILLS_SPELLS. This was
+      // bad because not everything could handle that, so we're going to
+      // unlearn skill #0 (if we know it) and gain tammuz, if we're a remort.
+
+      int test_ss;
+      if (static_cast< Tree<int,int> >(c->SKILLS_KNOWN).Find(0, test_ss)) {
+         c->SKILLS_KNOWN.Delete(0);
+      }
+      if ( c->isRemort() ) {
+         c->SKILLS_KNOWN.Insert(TAMMUZ_SKILL_NUM, 1);
+      }
+
       save(*c);
       delete c;
    }




More information about the ScryMUD mailing list