RSS
 

Archive for November, 2009

Big, small and bugs.

30 Nov

A few small changes and a few big ones. It is something that I’ve commented about before, that sometimes it is the small aesthetic changes that yield more of a positive response than the big ones, and this time is no exception.

Inventory and container content display has now been upgraded and is more informative. It’s a little tidier and inventory displays currently how much you are carrying and the max. And containers displays how much they weigh and their max.

On the bigger side of things, I decided to take the plunge, so to speak, and change the quality scale from 1 to 100, to 1 to 10. As can be expected with such things, there was some hiccups in the conversion and a few people that logged in whilst the changeover was happening, had their stuff downgraded to awful. This effected ONLY stuff either in inventory or worn. Not room items and if you let us know, we’ll do our best to fix this up – just be understanding if we can’t do it right away.

What does the scale change mean? All good loaves of rye bread will now stack. Before, a good loaf could have a quality number of 26.. or 30.. or even 41. Now they all have the value ’4′, and as a result, can be saved together (assuming no other variances in values). Should tidy things up a bit.. and another step towards reducing memory usage.

Bug check wise.. a few things have been ironed out with the death code. In theory.. if you die, you shouldn’t die over and over like was going on before.. and the room you died in etc should also be set correctly.. this wasn’t, but now is the case. Help death and help haunt have been updated.

PS. Also new craft skill added.

 
 

Room Item Restrictions

28 Nov

In order to try avoid the memory issues that plagued us last week, another bit of code has been added.

Basically, there are now limits on how many items will ‘fit’ in a room. This includes all items in side of containers (and in containers in containers, etc) in the room.

The limits are as follows:

Stalls: 25
Shops: 50
Homes: the drop limit of the owner
Donators drop limit: 50 + donation amount
Non Donators drop limit: 50

Hoping that makes sense. Some examples:

Mark is inside someone elses workshop, the owner of the workshop is a donator and has donated $20 and thus the limit on the room is 70.
Mark is not a donator and in a forest, there is no owner, so the limit is 50.
Jack is a donator and has donated $20 and is in a forest, so the limit is 70.

I admit to being more than a little reluctant to put in limits, but at this point, I don’t have much of a choice. At a later point, we may also introduce lockers – but the code for that is a lot more extensive, and I don’t have the time… just yet.

 
 

Quality

27 Nov

In an effort to try balance things, some adjustments have been made to the quality modifiers and production of quality items.

When crafters produce an item, the quality is not a certain thing anymore. There is a random element that can produce items of higher, or lesser quality than their skill (and tool level). This will hopefully make higher quality items a little rarer and a little more sort after. It will also help make the economy a little more balanced as the superb end of things was fetching way too high a price to be that commonly made.

The second thing that has been changed is the price modifier for quality items. Overall it has been reduced substantially, and this will mean that for buyers, getting a hold of higher quality weapons and tools will be a little easier. But for sellers, you may no longer be making 4x the normal value of the item at superb quality.

 
Comments Off

Posted in Code, Dark Isles

 

Food Perishing

26 Nov

Food now perishes. This should help with the managing of our objects in game. For the first round, it’ll take about 3-4 days for a food of average quality to perish. After that, it’ll be raised to over 7 days. Food that is higher in quality WILL last a lot longer. Food that is of poorer quality, will last a lot shorter. Food in inventory does not perish.

For shop owners, if you have food loading, I recommend that you make sure that you are only loading what is being sold. This might mean dropping down the amount of items you have loading.

 
 

Memory Hogging

25 Nov

A big thanks to all of you for being so patient over the last week through the bi-hourly crashes.

For those that hadn’t heard, the source (ultimately) was rooms overfilled with objects. We purchased additional memory but it still wasn’t enough, and it wasn’t till some of our staff went through and cut down some of these items that we actually saw a difference in Dark Isles up time.

Why do you ask?

As most of you are probably aware, each item is essentially a set of attributes. Descriptions, weight, value, quality, type, flags, etc. For every single item loaded in the game, all that information, for every single one, is loaded into memory. At the moment, looking at stats, we have 9897 (there are only 3018 different objects total) objects in memory. I imagine that a few days ago that would of been much higher. On the test server, we might have only a few hundred objects loaded, and the difference on memory usage is huge. The main server uses more than double as a result of objects alone!

So, how do we fix? Most muds don’t have persistent worlds. Your items get stored in your inventory and what you can’t fit there? Tough luck. Some, like the now extinct “Eternal Struggle” have/had lockers, which allowed you to safeguard a limited number of items. And this is something we had considered in the past for Dark Isles, but weren’t sure of implementing such a service due to the fact that the items would not really be ‘steal-able’.

Now, given the circumstances and the dire consequences of not managing the number of objects in game.. we need to rethink it and come up with a way of making it work. But in order for us to encourage or rather enforce the use of said lockers, we’re also going to put coded restrictions on the number of items in the room. I am debating about making this max number of items dependent upon (if there is one) the owner’s of the room’s donation levels. The idea being, that if someone has donated money, then they have helped cover the cost of the memory, so therefore, they should be able to have a few more items in the room than someone who doesn’t.

And a similar idea applied to the objects in storage. Hard disk space costs as well, so whilst everyone would get a fair amount of space to store, unlimited space might come with a certain donation level to ensure that we can cover the costs.

Another piece of code that will also help with the reduction of objects that I hope to work on this weekend is perishable food and herbs. It is IC.. and it makes sense. And it would stop things like apples staying in game for weeks, or even years at a time.

Most of the above is just our or my thoughts on things and not set in stone yet. And even once coded, will likely go through a number of adjustments before we settle on something that we feel works and solves this very big problem that we have.

I certainly cannot, and do not want to go through another week of hunting down memory hogs and leaks. I can’t afford the time to, and would rather of put the time into something else; like finishing the mount code.

 
 

Spoiler Alert

24 Nov

I saw New Moon last night… Kinda went:

EDWARD: OH NOEZ! I CANT BE WIF U.
BELLA: *ANGST*EMO*ANGST*EMO*ANGST*EMO* (90% of movie)
JACOB: OH NOEZ! I CANT BE WIF U.
BELLA: *ANGST*EMO*CLIFFDIV*
EDWARD: OH NOEZ! BELLA IZ DED *SUICIDE ATTEMPT*FAILZ*
BELLA: *SAVEZ*
EDWARD: MARRY ME!

 
1 Comment

Posted in Review

 

Crashes Explained, but not fixed yet

20 Nov

For the last 24 hours, I’ve been crash-hunting with gdb. It was soon found that our crashes are a result of running out of memory. For those that are familiar with C, that means we are allocating memory and not freeing it. Unlike many other languages, C doesn’t have its own garbage collection so we have to do this ourselves. If you don’t, then eventually the memory gets to more than you can use, and it goes down. How fast it gets there is dependent on things like, number of players on, when the last copyover was, amount of data (such as rooms, shops and assemblies) are stored in memory.

Running Valgrind showed off where a number of these leaks are, and I’ve managed to plug up the big gapping ones. Most of which, have been on the mud for a while, its just now that we’ve reached ‘critical mass’ and the crashes are becoming more frequent that it has become a real issue. Some of them, require a significant re-write of the code and out it interacts with the player/account files. The file input output handling that circle is as leaky as a sieve… again contributing to the problem.

So, please, be patient. This is going to take me a bit to track down and sort out. And in many cases, rewrite code, I’ve not touched or really looked at much. Dynamic memory management like this isn’t something I’ve had a lot of experience with but slowly getting my head around it. I even got a half dozen books from the Waikato University library to help.

 
 

We can haz donashunz?

17 Nov

That time of the month again and we have to pay for another round of hosting and unfortunately our coffers are pretty low at the moment. Our new host is much cheaper than our old and we get twice the value for money so that is some good news! If anyone wishes and is able to donate towards the costs of running Dark Isles, as always, it is greatly appreciated. And we’ll even colour your name for you as thanks.

 
 

New Area: Perran

16 Nov

Perran is now officially open and reachable via the travel command at the docks in Seahaven. Keep in mind that you can’t nip there and back in a day (or even two), so think seriously about your choice before making the trip. You can, of course, view available ships by using travel list, without actually purchasing passage on one of them.

A big thanks to Minion and Tigerlily for all their work on Perran!

 
1 Comment

Posted in Dark Isles

 

Persistant Mobiles

16 Nov

Most, when I’ve told about this code have gone ‘huh’? They don’t really get what it is, and how ‘big” it is.

So, I’ll try to explain here.

On most muds, if you drop an object on the ground and the game reboots/copyovers, the object is lost. On Dark Isles, we have in place a persistent world when it comes to objects. This means, if you drop something, it saves there. And if you come back a week, or even a month later, if no one else has picked it up, it’ll still be there. Regardless of copyovers/reboots.

But this has not been the case for mobs (NPCs). All NPCs have a starting location where they load up when the mud starts. Then those that can, wander around the world and interact (attack/etc) with the players. Now, if a copyover occurs, the mobs disappear from where-ever they are, and go back to their starting locations. They return to full health and are basically born again anew.

From a roleplay point of view, this could be annoying. Imagine you’re doing a Marduk (role-playing fornicating with some poor sheep) and *wham* a silent copyover, an next thing you know, your partner-in-love is gone! Or, imagine you’re attacking a massive dragon-demon, and you have finally got it to near death… and just before you do that final blow *wham* copyover, and he is born anew at full health and kills you. Not fun. A final example and the main reason why this new code was put in place. Imagine you have just paid half a pound to rent a horse for a day. You lead it out of the stable and a copyover hits… your horse is gone.

I am sure now you can see the worth of saving mobs like we do objects. It means that with a copyover or reboot, they reload just like players do, back in the same location they were in before the copyover. They remember if they are mounted/following someone and also save their hp. Later on, we might teach them some more saving tricks – such as saving a customised short desc, allowing for some renaming of pets.. which I’m sure you all will love.

PS. Did some more mount/stable code too. Taking a lot longer to put in the detail I wanted, so it won’t be released today, more like in a couple of days, but it is coming!