//string sGloveID = X; //Replace X above with either GetTag(oGloves) or some other //function to get the desired identifier from the glvoes and then //uncomment that line. } }else{ //Object was a weapon. Run whatever code here.}

A wise man does not dwell on his past. He learns from it, he grows from it, and then moves ahead into his future.

And some wise words from a wise man.

Orleron wrote:You have to excuse Themi. Tact, diplomacy, and softness are not his best traits, but he does not mean anything by his writing. He's a nice guy. You just get used to it after a while because he doesn't seem to learn.

Yes, but my code above does the same thing, because the only two possible items in slot Arms are Gloves and Bracers.
My code checks for bracers, and if not, the only other thing it could be is gloves. I was always taught to check for the negative before the positive, unless there were multiple possible positives.

A wise man does not dwell on his past. He learns from it, he grows from it, and then moves ahead into his future.

And some wise words from a wise man.

Orleron wrote:You have to excuse Themi. Tact, diplomacy, and softness are not his best traits, but he does not mean anything by his writing. He's a nice guy. You just get used to it after a while because he doesn't seem to learn.

You know all this type of coding could go to make a pretty good detective character.

Just a thought!

= = = = "In all my experience I have never been in any accident. I never saw a wreck and have never been wrecked nor was I in any predicament that threatened to end in disaster of any sort." ~ EJ Smith, Captain of the Titanic.

A wise man does not dwell on his past. He learns from it, he grows from it, and then moves ahead into his future.

And some wise words from a wise man.

Orleron wrote:You have to excuse Themi. Tact, diplomacy, and softness are not his best traits, but he does not mean anything by his writing. He's a nice guy. You just get used to it after a while because he doesn't seem to learn.

Create an NPC in the toolset. Give it the combat dummy model, make it's speed 0, and give it 40 levels of fighter, then pump up it's hit points. In the OnHit script, write a custom script that does a SendToAllPlayers() the value of Get Last Attacker and GetLastWeapon used.

Thi will answer all your questions.

To get the last spell cast at you is a different function, but I'm not sure how the two interact.

dougnoel wrote:Create an NPC in the toolset. Give it the combat dummy model, make it's speed 0, and give it 40 levels of fighter, then pump up it's hit points. In the OnHit script, write a custom script that does a SendToAllPlayers() the value of Get Last Attacker and GetLastWeapon used.