Post reply

Warning: this topic has not been posted in for at least 120 days.
Unless you're sure you want to reply, please consider starting a new topic.
Name:
Email:
Subject:
Message icon:

Verification:
Type the letters shown in the picture
Listen to the letters / Request another image

Type the letters shown in the picture:
What color is grass?:
What is the seventh word in this sentence?:
What is five minus two (use the full word)?:

shortcuts: hit alt+s to submit/post or alt+p to preview


Topic Summary

Posted by: devSin
« on: July 20, 2006, 01:01:24 PM »

Quote from: SimDing0™
HitBy requires the hit roll to be successful, yes. It doesn't, I believe, require actual damage.
Concur.

Quote from: Avenger_teambg
hehe, in scripting, i more like trust Sim :)
You should.
Posted by: Avenger_teambg
« on: July 20, 2006, 12:18:23 PM »

hehe, in scripting, i more like trust Sim :)
Posted by: SimDing0™
« on: July 20, 2006, 11:29:05 AM »

HitBy requires the hit roll to be successful, yes. It doesn't, I believe, require actual damage.
Posted by: devSin
« on: July 20, 2006, 11:21:44 AM »

I'll go out on a limb and say that there is no difference. But I don't actually know.
Posted by: Avenger_teambg
« on: July 20, 2006, 11:18:53 AM »

Sorry to hijack this thread, but what is the difference between
AttackedBy and HitBy?

HitBy will return true if there is actual damage, or when the to hit roll was successful?
Posted by: SimDing0™
« on: July 20, 2006, 09:27:16 AM »

That's how it works, yes. There's no way to detect "the player ordered an attack on me". (This is reasonable in a sense: if you order an attack then change your mind, the creature might not turn hostile.)
Posted by: Symm
« on: July 20, 2006, 08:32:01 AM »

Hi, After some research into the AttackedBy([ANYONE],DEFAULT) I came to the conclusion it only returns 'true' immediately after a target either hits or misses. Whilst this is OK if I want a script to react to an immediate attack, it doesn't let me script actions for when a char. is targetted by an enemy, and is running into attack the char.

Is there any other way to script a char. being targetted?

Similarly !AttackedBy([ANYONE],DEFAULT) returns 'true' most of the time, even if I'm being attacked. It only returns 'false' immediately after an enemy hit or miss. By then the script has already passed it as true.

This causes problems when I want to for example:-

See an enemy
and I'm not attacked
then
do condition x

Has anyone else experienced problems with AttackedBy?