adonthell-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Adonthell-devel] equipping items


From: Kai Sterker
Subject: Re: [Adonthell-devel] equipping items
Date: Sat, 17 May 2003 00:29:40 +0200

On Fri, 16 May 2003 13:22:44 -0700 Mike Avery wrote:

> Yeah.  If two hand slots are already filled, and I want to equip a
> two-handed axe, it would be handy if I as a player could just equip
> the axe, and the items in the right/left hand slots are just "taken
> care of" by having the items placed into inventory (space requirements
> notwithstanding).
> 
> Or, if I am using a bow in one hand, and I equip the two-hander,
> should the one equipped bow be returned as in  a normal slot? 
> Questions.  I think as you say, we would be wise to look at these
> possibilities now rather than later.

True.


Idea #1:

Would it make sense to delay that check until actually calculating item 
effects? What I mean is the following:

Right hand (or weapon slot) can contain either type of weapon. Left hand
(or shield slot) can contain a shield or a second weapon. However, the
shield (or second weapon) is only taken into account when the first
weapon is not double handed.

That is not truly realistic, but it would work around the removing two
items when equipping bi-hander issue quite nicely. Not sure whether this
will be the best solution, though.


Idea #2:

When equipping a two-handed weapon, the left hand slot could get deleted
or otherwise marked. When removing the weapon it would be restored. We
could possibly arrange that a GUI would still display the slot (although
greyed out to show it is not available.) Actually, adding/removing items
could still be allowed. The combat calculations however wouldn't get to
see the slot, so they wouldn't take it into account without any work of
their own.


> Is a quiver going to be considered a slot as well?  One reason I ask
> is concerning item.count
> 
> Do we need to handle moving stacks of items to character slots?  This
> is where the quiver question comes into play.  Should "body part"
> slots be assumed a count of 1, with arrows simply being consumed from
> the inventory, or should the character have a quiver slot?

I think we need the quiver slot in order to allow players to chose a
certain ammo. Like if they have wooden and steel arrows, they might want
to save latter for a tougher opponent. In which case they could put the
wooden ones into the quiver.

In that case, it would make sense to move all arrows from the source
slot into the quiver. Or at least as many as the player choses to move.
It'd be similar with throwing daggers, which would probably go into the
right hand (and possibly left too). Their effect method would have to
delete them each time the player makes an attack.


An alternative would be to link the equipment and inventory slots. But
apart from the extra work, it would also render the player unable to
save some of his ammo/throwing weapons for later use.


 
> I hope I haven't been too confusing Kai.  Just trying to wrap my head
> around things.  With talking about the equip methods in the item
> class, and having the equip methods in the character class as well,
> and throw in the manager to boot!  Hehe.

No worries. I imagine that the equip methods of the character can go
away, as they will be moved to the manager. Those in item will stay
behind, but only as triggers for plot-related events. As such, most
items won't even implement them.

 
> I figured we would be leaving the low level add/remove/slot_empty
> methods in either the item or character class.  You mentioned doing
> so, so I figured they would be there for use..  I then went and used
> my assumption to think about how we might devise the logic to create
> methods to call those methods from within the manager. 

Luckily this won't be neccessary :). (Except for the item::equip /
unequip). But accessing the item is easy if you have its slot, which the
manager does. Might not even need a pointer to a character (depends on
what should be passed to the item methods)



> It all looks good to me Kai, I undersand the workings and the way you
> are looking to implement things.  The design is good so anything you
> come up with will be fine by me!
> 
> I'll start some of the character/item status check methods.

Those accept/fit ones, or others?


> A list of categories would be nice.  What do you suggest?

Okay, here's a first (incomplete list). Of course we'll have to make
sure that the categories provide all the information we need.

Weapon          // for all weapons
Armour          // for all armour

One-Handed      // different weapon types
Two-Handed
Ranged

Shield          // different armour types
Helmet
Boots
Gauntlets
Body-Armour

Arrow           // different ammo types
Bullet
Bolt

Ring            // jewellry
Amulet

Tool            // everything that's not weapon but still equippable in right
                // hand

I'm sure this list is not suitable for everything we need to check, but
I guess we can use it for a start. In case you find better names for
some categories, feel free to use those.

Kai




reply via email to

[Prev in Thread] Current Thread [Next in Thread]