Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ Dawn of Time
➜ Administration
➜ Code port from SMAUG (bleh)
|
Code port from SMAUG (bleh)
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
| Posted by
| Meerclar
USA (733 posts) Bio
|
| Date
| Tue 19 Nov 2002 07:39 AM (UTC) |
| Message
| I am currently working on porting a unique item snipet from SMAUG to DoT and am absolutely clueless how to deal with one specific part of the conversion which follows. The rest of the snipet is easily enough converted but the radical changes in the quit functionality between the 2 codebases have me stumped on this.... anyway, heres the offending code with original notations:
In do_quit:
Find:
int x, y;
int level;
Add before it ( or uncomment it if it's already there ) :
OBJ_DATA obj;
Find:
extract_char( ch, TRUE );
for ( x = 0; x < MAX_WEAR; x++ )
for ( y = 0; y < MAX_LAYERS; y++ )
save_equipment[x][y] = NULL;
Add before it:
for ( obj = ch->first_carrying; obj; obj = obj->next_content )
{
if( IS_OBJ_STAT(obj,ITEM_RARE) || IS_OBJ_STAT(obj,ITEM_UNIQUE) )
obj->pIndexData->count += obj->count;
}
Many thanks for any help offered. |
Meerclar - Lord of Cats
Coder, Builder, and Tormenter of Mortals
Stormbringer: Rebirth
storm-bringer.org:4500
www.storm-bringer.org | | Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
5,659 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top