RanvierMUD / ranviermud

A node.js based MUD game engine
https://ranviermud.com
MIT License
796 stars 247 forks source link

Loot tables #111

Closed seanohue closed 7 years ago

samjaninf commented 7 years ago

This is just an idea, but what about a loot system using word modifiers? E.G. 'Savage' Axe Brutality would give like a 10% extra crit damage. While a 'Bloody' Axe Brutality would only give 5%.

Just food for thought.

shawncplus commented 7 years ago

So the loot system is going to work much like the other systems:

  1. An abstract library to provide a scaffold for more customized methods to plug into
  2. A basic implementation of an example method.

Take for example core-combat Combat isn't actually a "feature" of the core, it's an artifact of how the core works. So core-combat is just a plugin that ships with Ranvier that adds combat.

Loot will work very similar:

There will be base core functionality that defines a thing called a "loot table" which won't even be attached to Npcs directly. The rest of the implementation of how loot is dropped doesn't even take place in the core code. It will happen in bundles that I envision working something like so:

People that didn't want this functionality would just disable the core-loot bundle and create their own lootable behavior that could really do whatever the heck they want. I happen to agree that random generation of items is a cool idea. But for base functionality I think just having a static list of static items to pick from is enough

Xarcell commented 7 years ago

I agree with samjaninf

We should hasve a list of words that can be prepended to items that adds to the description, but also adds value. This would alsdo be used in random loot generation with random descriptions. Examples:

Simple Short Descriptions With Added Values bloody:0 brass-studded:5 leather-engraved:3 diamond-carved:20 beveled:4 ruby-inlaid:800

If this is added to system mechanics, I will create a more rebust list.

seanohue commented 7 years ago

Really, whatever system is in place just needs to be flexible/configurable enough to fit any kind of loot/item description you can imagine. For example, I'd like to have a wide variety of tables based on the NPC type, the environment they're found in, and other factors, and procedurally generate everything, but as long as the base Loot API is flexible, (i.e., take tables or a single table as input, choose/generate a bit of loot or more than one bit of loot, drop said loot) it will be easy to mod.

Sean O'Donohue

On Fri, Feb 10, 2017 at 9:18 AM, Xarcell notifications@github.com wrote:

I agree with samjaninf

We should hasve a list of words that can be prepended to items that adds to the description, but also adds value. This would alsdo be used in random loot generation with random descriptions. Examples:

Simple Short Descriptions With Added Values bloody:0 brass-studded:5 leather-engraved:3 diamond-carved:20 beveled:4 ruby-inlaid:800

If this is added to system mechanics, I will create a more rebust list.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/shawncplus/ranviermud/issues/111#issuecomment-278952231, or mute the thread https://github.com/notifications/unsubscribe-auth/AHxr-ZZTIgaf546Yt7xLXlo5wXuzbnSgks5rbHHBgaJpZM4L8VFE .

samjaninf commented 7 years ago

I agree with seanohue. My system was just a suggestion and using the bundles that shawn is putting in that could be fairly easily implemented.

Now I very much like the idea of a little procedural generation of loot and maybe mobs. The script would take a look at area, weather, type of mob and then also randomizes a few variables such as the basic type and the rarity/strength before looking at any special modifiers on the mob. Maybe that last one should come first in case the mob is marked nodrop and save some of that calculation time. Maybe somehow even check if any of these items exist out in the world and restrict it. Using those numbers it would pull from a table of weighted items.

'Frostmoon, carver of bones' would much more likely to be found in a glacial palace after killing a boss or like a rare type monster. Or maybe it would be found in a volcano as that is the only thing restricting its power, either way, I'm looking forward to it.

And the bundle system appears to be flexible enough to handle most if not all of that.

Random question. Do mobs have primitives?

shawncplus commented 7 years ago

@samjaninf not sure what you mean by primitives?

samjaninf commented 7 years ago

Say for instance you have an Orc. The orce has 5 str, 5 dex, 5 con, 5 int, 5 wis as an example. Then you create an orc guard from the basic orc and gave it 5 con and 5 dex. The guard would end up with 5 str, 10 dex, 10 con, and an attribute of say 'suspicious'. Then you create an orc captain from that orc guard and you assign the captain 5 str, 5 con and 5 int. The captain would then end up with 10 str, 10 dex, 15 con, 10 int, and the 'suspicious' attribute etc etc.

Basically it would inherit anything set on it's immediate primitive.

I'm pretty bad at explaining my thoughts so I thought providing an example would be a better idea.

shawncplus commented 7 years ago

While the engine doesn't have that feature it is a feature of YAML itself http://atechie.net/2009/07/merging-hashes-in-yaml-conf-files/

shawncplus commented 7 years ago

This is partially implemented. Remaining todo list:

shawncplus commented 7 years ago

We now have loot tables, item quality, and corpse decay. I'm calling this one closed with prejudice