backstab reporter

Posted by Anssett on Wed 29 Oct 2003 10:35 AM — 1 posts, 8,874 views.

USA #0
So, on to my next big project ...
In the MUD i waste most of my time on, a common method of meleers to engage another character or creature in combat is to backstab them.
To accompany the backstab, many people have backstab notifications that report to their chat - it helps when one's fighting in groups and such to know who's been attacked and where.
The backstab works in such a way that one can be hit a maxiumum of 3 times and a minimum of 0 times with it, and each hit performs a different multiplier of the base damage to the target, ranging from 1.5x to 6.0x
At the moment, I'm at the planning stage on the design of this script. I'm not entirely sure how I want to approach it, nor am I sure what is the best method.
Here are some of the problems I've identified that I'm going to have to work with:

*Variable number of hits - the script has to be able to differ between 0/1/2/3 hits
*Variable amount of damage - For each specific hit, the damage multiplier can change
*Other damage modifiers - certain character classes and certain weapons can cause added damage modifiers to the attack
*Spell effects - certain spells deflect damage, reflect damage, and absorb damage
*Variable targets - the script should be able to differ between the user attacking or the user being attacked
*other, less critical things - calculating the damage done when the user is attacked; calculating the average damage done; reporting the target's health level

This is very likely an incomplete list, but it's what I've got in my head at the moment. At any rate, what I'm looking for right now is for people who have perhaps worked longer with VB to help me out with ideas for how to handle this sort of thing. I'm not looking specifically for code right now, just ideas.

I have some scripts that perform the same functions that are written for MudMaster 2000 that I'd be more than willing to email to anybody that wants to look at the problem in a little more detail.

Thanks
-ans