Top Mud Sites Forum Return to
Go Back   Top Mud Sites Forum > Mud Development and Administration > MUD Coding
Click here to Register

Thread Tools
Old 07-26-2002, 11:53 PM   #1
New Member
Join Date: Apr 2002
Posts: 14
Jaegar is on a distinguished road

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 is offline   Reply With Quote
Old 07-27-2002, 12:04 PM   #2
Robbert's Avatar
Join Date: Apr 2002
Location: #### Paso, Tx
Posts: 89
Robbert is on a distinguished road
Send a message via ICQ to Robbert Send a message via AIM to Robbert
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.
Robbert is offline   Reply With Quote
Old 07-28-2002, 11:43 PM   #3
New Member
Join Date: Apr 2002
Posts: 14
Jaegar is on a distinguished road
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 is offline   Reply With Quote
Old 07-29-2002, 08:44 AM   #4
New Member
Join Date: Apr 2002
Posts: 28
Torren is on a distinguished road

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.
Torren is offline   Reply With Quote

Thread Tools

Adding restrictions to Backstab - Similar Threads
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

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off

All times are GMT -4. The time now is 10:13 AM.

Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Style based on a design by Essilor
Copyright Top Mud 2014