Ok, I got everything working great, but I have one other problem. If I were to make a new spell, and save skill table and reboot, then the sn changes. When a player mem's a spell, he mem's the sn. so when the sn changes on the sort skill table, the player has a different spell memed. I tried not sorting in db.c, but then the spell stays at the end of the slo and you can't find the spell. Here's what I did:
It's not showing up after it loads skill table. ANy thoughts on what to do?
here is db.c
sset create skill aeros
sset save skill table
slo aeros ( aros is slot 273)
<305hp 258m 568mv>
< > slo aeros
Sn: 273 Slot: 0 unknown: 'aeros '
Saves: none SaveEffect: none
Type: unknown Target: ignore Minpos: 0 Mana: 0 Beats: 0 Range: 0
Flags: 0 Guild: -1 Value: 0 Info: 0 Code: spell_smaug
Sectors Allowed: All
Dammsg:
Wearoff:
--------------------------[CLASS USE]--------------------------
Mag) lvl: 101 max: 95% Cle) lvl: 101 max: 95% Thi) lvl: 101 max: 95%
War) lvl: 101 max: 95% Pal) lvl: 101 max: 95% Dru) lvl: 101 max: 95%
Ran) lvl: 101 max: 95%
<305hp 258m 568mv>
< >
Comm: Sock.sinaddr: 4.225.5.196, port 3117.
<305hp 258m 568mv>
< > sset save skill table
Log: Camilla: sset save skill table
Saving skill table...
reboot mud now
slo aeros
<305hp 258m 568mv>
< > slo aeros
No such skill, spell, proficiency or tongue.
It's not showing up after it loads skill table. ANy thoughts on what to do?
here is db.c
log_string("Loading skill table");
load_skill_table();
// sort_skill_table();
remap_slot_numbers(); /* must be after the sort */
gsn_first_spell = 0;
gsn_first_skill = 0;
gsn_first_weapon = 0;
gsn_first_tongue = 0;
gsn_top_sn = top_sn;
for ( x = 0; x < top_sn; x++ )
if ( !gsn_first_spell && skill_table[x]->type == SKILL_SPELL )
gsn_first_spell = x;
else
if ( !gsn_first_skill && skill_table[x]->type == SKILL_SKILL )
gsn_first_skill = x;
else
if ( !gsn_first_weapon && skill_table[x]->type == SKILL_WEAPON )
gsn_first_weapon = x;
else
if ( !gsn_first_tongue && skill_table[x]->type == SKILL_TONGUE )
gsn_first_tongue = x;