> I am having some problems with my dual wield skill. Firstly, at the moment > the player can only dual wield an weapon if it has the dwield bit set on it. > Unfortunately this mean that they can wield a weapon which requires 2 hands, > and then dual wield a single handed weapon. > > Here is the code I came up with for the check, if anyone has any ideas. > > else if (!CAN_WEAR(GET_EQ(ch, WEAR_WIELD), ITEM_WEAR_DWIELD)) > { > send_to_char("You are already wielding a weapon which requires both > hands!\r\n", ch); > perform_remove(ch, WEAR_DWIELD); > } > > The problem with this code is that wield works fine but no matter which > weapon type you wield two-handed or single handed, it always throws up the > catch above. It is obviously a problem with the logic statement but i am not > sure quite what. Letsee... You've got confused logic in there, for sure. Lets look at the 'can wear' macro. It takes two arguments, a character, and an ITEM_WEAR position. Looking back up at your code, you've got two similar looking defines, "WEAR_DWIELD" and "ITEM_WEAR_DWIELD". If your perform_remove command works correctly (it takes identical arguments to CAN_WEAR). Which means that ITEM_WEAR_DWIELD is an object exta_flag. Oh, and that you're mixing it it. Try something like.. if(GET_EQ(ch,WEAR_WIELD) && !IS_OBJ_STAT(GET_EQ(ch,WEAR_WIELD),ITEM_WEAR_DWIELD)) { blahblahblah, no eq for you. } > > Also I have included a disarm skill, and if you use the disarm skill whilst > dwielding your opponant doesn't get an attack in any round. > Is this likely to be a problem with the disarm skill of the dual wield > skill, and any ideas what it may be. Well, how does your disarm skill work - is it like a 'bash' or 'kick', or is it automatic? If it's not automatic I'd be hard pressed to tell you where the issue is. If it's automatic, I'd just check the logic of all your code dealing with number of attacks, and what happens with weapon vs. barehand attacks. PjD +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 04/11/01 PDT