Bernhard Kuemel wrote: > Hi! > > "The ring unequipped is fairly indeterminate - it depends on how the > server has ordered your inventory (which is not the same as the order > your window displays)." > > The solution would be to let the server keep track of the order when > rings were applied and always unapply the ring worn longest. This way > I could bind "wear ring of ice;wear ring of ice" to a key and be sure > I quickly get cold protection when I need it. Some could consider unwearing the ring worn the longest to not be ideal. Eg, this ring is one I want to always wear, it is the other ring I want to swap on and off. OTOH, that isn't really supported right now anyways. I was thinking that it could be nice to bind the rings to specific locations, eg, apply left finger ring of the like. But since there is no requirement that a creature only has 2 ring fingers, doing this could be difficult. One question is - at what resolution does first need to be tracked? To actually track when items were equipped in a sensible fashion, one can't use the internal values within the server (eg, pticks), as if the server is restarted, that value is bogus compared to items equipped from before the server restarts. So it needs to be tied to something like time(), but that only has resolution to one second, which means if you have a keybinding, it is very likely that both rings will get the same value. This, something like 'apply ring of fire; apply ring of thieves', following by something like 'unapply ring, apply ring of X' - that unapply ring might equip either the ring of fire or ring of thieves, because as far as the server knows (within its one second resolution), they were both equiped at the same time. But as I think about this further, the less I think it should be the server tracking this - it should really be the client. there is a lot of stuff in the server right, which in a sense is legacy information (left over from when the display was built into the server, and thus those convenience had to be there). For something like equip/unequip, really all the server should probably support (if redone) would be taking an item tag to equip/unequip. It shouldn't be searching for matching strings. I'm much happier adding lots of code to the client than to the server - stability of the client, while desirable, isn't quite as important as stability to the server. So adding something to the client like 'unapply all rings' would make perfect sense to add. Let the client figure out what rings are applied, and what ones it should apply - it really shouldn't be part of the server to do this - all the server should really done is verify the integrity of the request the client is sending - if your trying to equip three rings but are only allowed to, it shouldn't allow it. one could argue that it shouldn't even unequip items when player is trying to equip something new, but that bit of code isn't that big a deal. > > It would also be cool if I could make a keybinding that put the rings > worn in a (specific) sack and another that put's the rings from the > sack back on. E.g. 'open sack;empty finger1;empty finger2;wear ring of > ice;wear ring of ice'. And then? Hmm, 'wear ring from sack;wear ring > from sack' is probably too complicated to implement. And this would > also require to unlock the rings which I maybe don't want. We might > also need/want to label items or allow some kind of indexing like > 'open sack #3' or 'label sack "sack1"'. Well, once again, this should all be in the client logic. Eg, if something like 'wear ring from sack' is done, the client should know to apply the sack, move the ring to the players inventory, then apply it. But more probably, it would make sense to break these into smaller pieces in terms of command, eg, open sack, unapply ring X, move ring X into sack, close sack, open sack1, move ring Y from sack to player inventory, close sack 1, apply ring Y' > > But the first thing, the order in which rings are unapplied is quite > simple and really helpful. Please do it. Would it be sufficient to just have a command that unapplies all your rings? That is much easier to do - don't need to store any extra information in the ring object itself, and as said, something like that could probably be done in the client. _______________________________________________ crossfire-devel mailing list crossfire-devel at lists.real-time.com https://mailman.real-time.com/mailman/listinfo/crossfire-devel