Top Mud Sites Forum

Top Mud Sites Forum (http://www.topmudsites.com/forums/index.php)
-   MUD Coding (http://www.topmudsites.com/forums/forumdisplay.php?f=9)
-   -   Any Help for Furniture Loads? (http://www.topmudsites.com/forums/showthread.php?t=353)

Iluvatar 10-29-2003 05:06 PM

In Circle 3.0, we zedit load furniture to exist in a room and the process is pretty standard as first remove object, independently load obj so there’s no repetitive loading and multiplication. The problem arises when someone is occupying the furniture since it changes status whenever connected to an active player and it won’t remove then reload on zreset.

Does anyone know of a fix for this or suggest a fix?

Amnon 10-30-2003 01:12 AM

Yeah - Don't remove it.
When you load the furniture, instead of clearing it all out of the room, just scroll through it to see if it's already there.

Iluvatar 10-30-2003 03:16 AM

Umm, no. The process is automatic in a circle zonal reset. In this case there are three benches removed, then three are loaded. The problem is they aren't benches anymore from the code perspective if someone is sitting on one, so it doesn't purge and creates a new bench.

karlan 11-03-2003 12:13 AM

Have a look at reset_zone(....) in db.c.

I would suggest adding a value to obj you will need to add a check to the [R]emove case. to check if the object being removed is furniture, check if occupied. you will also need to do some checking to only load an object if needed (ie one was also deleted)

Best I can come up with for now

erdos 11-03-2003 12:28 AM

I have no experience with circle, being a SMAUG brat, but if it's doing what I think you're saying it's doing-- removing things completely before resetting them-- then that has to be the biggest waste of CPU time i've ever heard of! If this is the case, I'd totally rewrite your reset code from scratch so that it does like Amnon said, just check if it's already there before resetting it...

As for your weird polymorphing furniture, what's the point of having it change when someone sits on it? sounds like a very bandaid-ish solution to the problem of having only 1 person per chair... sounds very much like a crude snippet. (Note the redundancy. most every snippet is crude.)


All times are GMT -4. The time now is 12:01 AM.

Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright Top Mud Sites.com 2022