[FIXED] A number of issues with the Healing skill
- Xuri
- Site Admin
- Posts: 3704
- Joined: Mon Jun 02, 2003 9:11 am
- Location: Norway
- Has thanked: 48 times
- Been thanked: 8 times
- Contact:
A number of issues with the Healing skill
1) There is no range check between the healer and the damaged/dead target after the healing-timer has elapsed, before the actual healing/resurrection takes place. This allows the damaged character and/or ghost to run far from the healer, and for instance allows for house break-ins since the ghost can get targeted for resurrection outside the house, then run inside the house before the healing timer ends and get resurrected there.
2) There is no LoS-checking possible in the JS-engine, so there are no LoS-checks when targeting a dead/damaged character for healing. Since the range of healing is two tiles, this means it's possible to heal dead people on the other side of locked doors, allowing them to break in.
I'm updating the healing-script to do checks if either the healer or target owns the multi the target is in, and will disallow resurrecting if neither owns the multi - but it still doesn't stop the "resurrect on other side of door"-trick in static houses, nor does it stop the target ghost from running through these doors after a valid resurrection process has started, but before the timer has run out (since the actual resurrection occurs in the source code, I can't do similar checks right before resurrecting the ghost). Any doors that GMs lock to keep players out will in essence be void.
2) There is no LoS-checking possible in the JS-engine, so there are no LoS-checks when targeting a dead/damaged character for healing. Since the range of healing is two tiles, this means it's possible to heal dead people on the other side of locked doors, allowing them to break in.
I'm updating the healing-script to do checks if either the healer or target owns the multi the target is in, and will disallow resurrecting if neither owns the multi - but it still doesn't stop the "resurrect on other side of door"-trick in static houses, nor does it stop the target ghost from running through these doors after a valid resurrection process has started, but before the timer has run out (since the actual resurrection occurs in the source code, I can't do similar checks right before resurrecting the ghost). Any doors that GMs lock to keep players out will in essence be void.
Last edited by Xuri on Sat Nov 26, 2005 11:15 pm, edited 2 times in total.
-= Ho Eyo He Hum =-
- Xuri
- Site Admin
- Posts: 3704
- Joined: Mon Jun 02, 2003 9:11 am
- Location: Norway
- Has thanked: 48 times
- Been thanked: 8 times
- Contact:
Ah, this just popped into my head right now:
The same problem is probably an issue with NPC healers, since they resurrect people without any "LoS"-checks as well, and without checking if the characters are in a house they own or not.
Not sure about the Resurrection spell, since that requires instant targeting and thus probably does LoS-check, but worth checking into that one as well.
The same problem is probably an issue with NPC healers, since they resurrect people without any "LoS"-checks as well, and without checking if the characters are in a house they own or not.
Not sure about the Resurrection spell, since that requires instant targeting and thus probably does LoS-check, but worth checking into that one as well.
-= Ho Eyo He Hum =-
I thought I'd bring up this past post on healing issues.
On our games lately we've noticed that healing always increases the hide skill. I'm not sure which script to look to fix this.
Thanks. I'm using:
5.0.1h client
Uox3 = all in one package with individual components installed as of 1/5/05 (not sure what version)
On our games lately we've noticed that healing always increases the hide skill. I'm not sure which script to look to fix this.
Thanks. I'm using:
5.0.1h client
Uox3 = all in one package with individual components installed as of 1/5/05 (not sure what version)
-
giwo
- Developer
- Posts: 1780
- Joined: Fri Jun 18, 2004 4:17 pm
- Location: California
- Has thanked: 0
- Been thanked: 0
I'm looking at the tempeffect handling for healing currently, and everything seems to be as it should.
There is a distance check and an LoS check immediately before healing/resurrecting/curing another player.
I will test this to make sure it is the case, but for the moment, it seems like it should be working.
There is a distance check and an LoS check immediately before healing/resurrecting/curing another player.
I will test this to make sure it is the case, but for the moment, it seems like it should be working.
Scott
- Xuri
- Site Admin
- Posts: 3704
- Joined: Mon Jun 02, 2003 9:11 am
- Location: Norway
- Has thanked: 48 times
- Been thanked: 8 times
- Contact:
Well, problems such as the LoS-check returning true even though there's a wall (static or dynamic, doesn't seem to matter) between you and the other object.
Easy way of checking, is applying the following to any item, then placing it at different locations before trying to use it.
It does seem to work correctly between floors though, in those cases it seems to return false 
Easy way of checking, is applying the following to any item, then placing it at different locations before trying to use it.
Code: Select all
function onUse( pUser, iUsed )
{
if( pUser.CanSee( iUsed ) )
pUser.TextMessage( "I can see the item!" );
else
pUser.TextMessage( "I can't see the item!" );
return false;
}-= Ho Eyo He Hum =-
-
giwo
- Developer
- Posts: 1780
- Joined: Fri Jun 18, 2004 4:17 pm
- Location: California
- Has thanked: 0
- Been thanked: 0
Notably if some walls are being missed by the LoS function, it is likely happening here.
if( ( ( itemids[toCheck] >= 6 ) && ( itemids[toCheck] <= 748 ) ) || ( ( itemids[toCheck] >= 761 ) && ( itemids[toCheck] <= 881 ) ) ||
( ( itemids[toCheck] >= 895 ) && ( itemids[toCheck] <= 1006 ) ) || ( ( itemids[toCheck] >= 1057 ) && ( itemids[toCheck] <= 1061 ) ) ||
( itemids[toCheck] == 1072 ) || ( itemids[toCheck] == 1073 ) || ( ( itemids[toCheck] >= 1080 ) && ( itemids[toCheck] <= 1166 ) ) ||
( ( itemids[toCheck] >= 2347 ) && ( itemids[toCheck] <= 2412 ) ) || ( ( itemids[toCheck] >= 16114 ) && ( itemids[toCheck] <= 16134 ) ) ||
( ( itemids[toCheck] >= 8538 ) && ( itemids[toCheck] <= 8553 ) ) || ( ( itemids[toCheck] >= 9535 ) && ( itemids[toCheck] <= 9555 ) ) ||
( itemids[toCheck] == 12583 ) ||
( ( itemids[toCheck] >= 1801 ) && ( itemids[toCheck] <= 2000 ) ) ) //stairs
Quite the chunk of nasty code, ehh?
Anyway, it could be worthwhile to check the ID's and see if they are in that range next time you notice one getting missed.
if( ( ( itemids[toCheck] >= 6 ) && ( itemids[toCheck] <= 748 ) ) || ( ( itemids[toCheck] >= 761 ) && ( itemids[toCheck] <= 881 ) ) ||
( ( itemids[toCheck] >= 895 ) && ( itemids[toCheck] <= 1006 ) ) || ( ( itemids[toCheck] >= 1057 ) && ( itemids[toCheck] <= 1061 ) ) ||
( itemids[toCheck] == 1072 ) || ( itemids[toCheck] == 1073 ) || ( ( itemids[toCheck] >= 1080 ) && ( itemids[toCheck] <= 1166 ) ) ||
( ( itemids[toCheck] >= 2347 ) && ( itemids[toCheck] <= 2412 ) ) || ( ( itemids[toCheck] >= 16114 ) && ( itemids[toCheck] <= 16134 ) ) ||
( ( itemids[toCheck] >= 8538 ) && ( itemids[toCheck] <= 8553 ) ) || ( ( itemids[toCheck] >= 9535 ) && ( itemids[toCheck] <= 9555 ) ) ||
( itemids[toCheck] == 12583 ) ||
( ( itemids[toCheck] >= 1801 ) && ( itemids[toCheck] <= 2000 ) ) ) //stairs
Quite the chunk of nasty code, ehh?
Anyway, it could be worthwhile to check the ID's and see if they are in that range next time you notice one getting missed.
Scott
- Xuri
- Site Admin
- Posts: 3704
- Joined: Mon Jun 02, 2003 9:11 am
- Location: Norway
- Has thanked: 48 times
- Been thanked: 8 times
- Contact:
Well, the wall in question has hex id 0x0133, and since the code checks for decimals, that'd be number 307, which falls under the very first check as above 6 and below 748.
And just to be certain, just tested with non-JS los-check, and as a normal player I could open a container on the other side of a static wall, so yeah, it's not the js-function that's the problem =)
And just to be certain, just tested with non-JS los-check, and as a normal player I could open a container on the other side of a static wall, so yeah, it's not the js-function that's the problem =)
-= Ho Eyo He Hum =-