![]() |
#1 |
New Member
Join Date: Apr 2002
Posts: 14
![]() |
![]() I am working with RoM 2.4 and am trying to add a restriction to backstab. I want to be able to restrict backstab to weapons with the damage noun of pierce. If someone could direct me in how I would make the "if" check in backstab for a damage noun on a weapon it would be appreciated.
Thanks in advance, Jaegar |
![]() |
![]() |
![]() |
#2 |
Member
|
Do you want specifically the damage noun of pierce, or all weapons which do piercing damage? ROM is set up to allow for different words to describe the same damage type.
For only pierce by itself, take a look at attack_table in const.c and find what number in the list "pierce" is. Remember to start counting with 0. Then simply compare that value to obj->value[3]. If they match, then the weapon has the verb of "pierce'. If you want to allow for all piercing verbs, you need to do a check for each one of the types, just as outlined above. I dont recommend this, in retrospect, because ROM considers biting attacks as piercing, and scratch attacks. You may want to check for "stab" as well as "pierce" though. |
![]() |
![]() |
![]() |
#3 |
New Member
Join Date: Apr 2002
Posts: 14
![]() |
We ended up restricting it to weapon type of dagger. I know that there are other weapons that might possibly be a valid weapon for backstab, but dagger seems the logical weapon to be used.
Thanks for your reply. Jaegar |
![]() |
![]() |
![]() |
#4 |
New Member
Join Date: Apr 2002
Posts: 28
![]() |
![]() if you still wanted to continue you to make it so that only DAM_PIERCE is affected, and you wouldn't have to worry about bites since gsn_backstab is passed to one_hit and you check to make sure they are already wielding a weapon. just do this check if ( attack_table[wield->value[3]].damage == DAM_PIERCE) Blah.
|
![]() |
![]() |
![]() |
Thread Tools | |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Review Restrictions. | imported_Synozeer | MUD Announcements | 11 | 10-11-2006 12:27 AM |
Adding Affects | Haley | MUD Builders and Areas | 2 | 10-06-2003 10:04 AM |
Adding new areas | Kariyana | MUD Coding | 1 | 01-18-2003 12:12 AM |
Adding new zones | Danlor | MUD Coding | 3 | 08-27-2002 09:18 AM |
What OLC do you prefer adding code support for? | Ostoles | MUD Coding | 4 | 06-28-2002 10:40 PM |
|
|