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
➜ SMAUG
➜ Running the server
➜ .are file crashing mud when loading it. Need help fixing the .are
.are file crashing mud when loading it. Need help fixing the .are
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Kelven
(10 posts) Bio
|
Date
| Fri 02 Apr 2004 10:27 PM (UTC) |
Message
| Ok, I made this area for a smaug mud that has 115 levels, and now I want to load it up on a smaug mud that has the standard 65 levels. But everytime I try and have it loaded, either on mud startup, or by using unfoldarea, it crashes the mud. Area Editor doesnt load it either... That being said, I already changed all of the level values down to under level 65 (as far as I know, anyways).
The error messages I get with Area Editor are:
"Object details must start with a '#'"
"Error occurred at (line 559) "1 1 1 10"
"Unexpected file format"
Here are the lines in that part of the .are file...
Line 551: #OBJECTS
Line 552: #10000
Line 553: longsword long sword~
Line 554: A longsword~
Line 555: A sharp longsword lays here.~
Line 556: ~
Line 557: 5 0 8193
Line 558: 0 2 8 3
Line 559: 1 1 1 10
Line 560: #10001
So there's line 559, I'm not sure what the values are or why it gives an error for it. If anyone can help me I'd appreciate it greatly. This area is my crowning achievement and I would really like it in my new mud, thanks :) | Top |
|
Posted by
| Nick Gammon
Australia (23,158 posts) Bio
Forum Administrator |
Date
| Reply #1 on Sat 03 Apr 2004 12:08 AM (UTC) |
Message
| I'm a bit curious to know how you made this area.
You can't load it into SMAUG, you can't load it into the Area Editor, and you say "I'm not sure what the values are".
How *did* you make it? If it falls over on the very first object, it sounds like there is a fundamental problem with it. |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
Posted by
| Kelven
(10 posts) Bio
|
Date
| Reply #2 on Sat 03 Apr 2004 04:36 AM (UTC) Amended on Sat 03 Apr 2004 04:37 AM (UTC) by Kelven
|
Message
| It was made with stock smaug 1.4's OLC. I then later changed the max level from 65 to 115, and changed this area to match, again using OLC. This area hasn't been edited with any outside editor, except me changing all the level values from 105 back to 55 using notepad (all the mobs were the same level in the area, so it wasnt that hard to do.)
That's all that was done to it as far as I know. I made this area back in 2000 on my hobby mud, and in late 2001 I decided to try making the mud 115 levels. I realized I liked it at 65 levels tho and changed it back a month or two later. Then I stopped building on this mud and it's been sitting on one of my backup cds ever since. Now my friend is making a hobby mud and I wanted to use this city area in it. His codebase is stock 1.4a.
I dont know how the changing of levels could affect the area like this, but again as far as I know, that's all that's ever been done to this area after it was built... | Top |
|
Posted by
| Kelven
(10 posts) Bio
|
Date
| Reply #3 on Sat 03 Apr 2004 04:32 PM (UTC) |
Message
| Well I found out what the problem was. Apparently there was an added value in my objects. In the code I posted above, line 559, it has 4 values, whereas all other area files I've checked only have 3. So I deleted the last one from all of the objects in the file and tried it again and it worked.
Anywho, I'd really like to know where that extra value came from. Like I said this area has only been on stock smaug 1.4 and 1.4a. There were some minor changes that I made, but nothing adding an extra value to objects... at least I dont think :/ | Top |
|
Posted by
| Samson
USA (683 posts) Bio
|
Date
| Reply #4 on Sun 04 Apr 2004 06:58 PM (UTC) |
Message
| In stock Smaug, you have this segment of fold_area which governs saving object values:
if ( val4 || val5 )
fprintf( fpout, "%d %d %d %d %d %d\n",val0,
val1,
val2,
val3,
val4,
val5 );
else
fprintf( fpout, "%d %d %d %d\n", val0,
val1,
val2,
val3 );
In db.c, you have the following segment which handles reading them:
ln = fread_line( fp );
x1=x2=x3=x4=x5=x6=0;
sscanf( ln, "%d %d %d %d %d %d",
&x1, &x2, &x3, &x4, &x5, &x6 );
pObjIndex->value[0] = x1;
pObjIndex->value[1] = x2;
pObjIndex->value[2] = x3;
pObjIndex->value[3] = x4;
pObjIndex->value[4] = x5;
pObjIndex->value[5] = x6;
pObjIndex->weight = fread_number( fp );
pObjIndex->weight = UMAX( 1, pObjIndex->weight );
pObjIndex->cost = fread_number( fp );
pObjIndex->rent = fread_number( fp ); /* unused */
I aded a few extra lines for reference. The value lines should be obvious. As you can see, it should be able to handle up to 6 entries on that line, and fold_area saves 4. So 4 entries is the proper amount. Double check db.c in load_objects and make sure you haven't changed anything there. | Top |
|
Posted by
| Kelven
(10 posts) Bio
|
Date
| Reply #5 on Mon 05 Apr 2004 12:51 AM (UTC) |
Message
| I dont have access to the code at the moment (running it off my friend's pc) but I'm looking at a bunch of stock smaug area files and on that particular line, they always only have 3 values. The line above it has 4, perhaps that's the item value line, but the one below it always only has 3. Check my example in my first post to see what I mean. There's two lines there that has 4 values each. Line 558 and 559, 559 is the one it was having trouble loading.
Anywho, it doesn't really matter what that extra number was, since we're not using that codebase anymore, that was my old smaug 1.4 one I was fooling around with years ago, we're using 1.4a now. I was just curious as to what I could have done to the objects code to have it do that... bleh, I'm getting old, my memory isn't that good anymore.
Anywho, I'm 99% sure that that was the problem, I saved this area in my 1.4 mud way-back-when, and I had something done to the code to add an extra number there... So stock 1.4a, and your area editor, wouldnt load it when I tried to get it loaded a few days ago. I took that extra number (which would be the 10 on line 559 in the example above) out of all the objects in the file and it loaded up fine in both 1.4a and the Area Editor. Unfortunately I dont have my old 1.4 code anymore to see what that extra number could mean. I vaguley remember trying to code in sheaths, maybe I tried to add an extra value for that or something. *shrug* | 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.
15,457 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top