Areet... here's the deal.
I'm trying to have a quest-giving NPC cast resurrection on the non-party-leader PC that experienced a certain event earlier in the quest. Is there any way to get the mob to mpaffect the PC with a certain quest bit with resurrection, when the PC is (obviously) not there? Could this maybe be done with a quick transfer of said mob to the realm of the dead to target the PC?
Quest-resurrection
-
Amalia
- Sword Grand Master

- Posts: 331
- Joined: Wed Feb 01, 2006 6:51 pm
- Location: Ardeep Forest
- Contact:
Quest-resurrection
Dear Enemy: May the Lord hate you and all your kind, may you be turned orange in hue, and may your head fall off at an awkward moment.
Should look something like this:
Code: Select all
if quest(0,1,$n) == 0(*Replace with your quest bits of course)
mpgoto 6
entry_prog 100~ (need to check if these work)
if questr("Your Vnum",0,1,$n) == 0 (*Replace with your quest bits of course)
mpcast resurrection $n
mpregoto
else
mpregoto
endif
endif-
Dalvyn
- Sword Grand Master

- Posts: 4708
- Joined: Tue Jul 15, 2003 9:26 pm
- Location: House of Wonder, Waterdeep
I am not sure I see what you mean...
Resurrection can be cast from afar; that is, a mob can "cast resurrection amalia" anywhere, as long as Amalia is dead.
The tricky part is to get the name in the command I think.
A possible solution would be this: have a pc type the name of the dead character. For example:
(mob) say One of you died? What was his or her name?
(mob) mpecho OOC: to answer, make sure that the dead character is online
(mob) mpecho OOC: and type "givename <name of dead PC>"
Then have a program on the mob that would go like:
An intercept_prog "intercepts" a command of the form <keyword> <word1> <word2> ... <wordN>. Inside the intercept_prog, you can use
Reacting to the effect of the spell is a bit more tricky though. I would suggest perhaps trying to use an act_prog (though I'm not sure if they work on spell echoes). If I remember correctly, the echo when someone has been resurrected is "<name> has been resurrected." An act_prog triggers when the mob "sees" a specific echo. In this case, it would be something like
Hope that helps.
Resurrection can be cast from afar; that is, a mob can "cast resurrection amalia" anywhere, as long as Amalia is dead.
The tricky part is to get the name in the command I think.
A possible solution would be this: have a pc type the name of the dead character. For example:
(mob) say One of you died? What was his or her name?
(mob) mpecho OOC: to answer, make sure that the dead character is online
(mob) mpecho OOC: and type "givename <name of dead PC>"
Then have a program on the mob that would go like:
Code: Select all
>intercept_prog givenname~
if questbit ok (to make sure that they don't get infinite free ress)
cast resurrection $1
endif
~
- $0 to refer to <word1> <word2> ... <wordN>
- $1 to refer to <word1>
- $2 to refer to <word2>
- ...
Reacting to the effect of the spell is a bit more tricky though. I would suggest perhaps trying to use an act_prog (though I'm not sure if they work on spell echoes). If I remember correctly, the echo when someone has been resurrected is "<name> has been resurrected." An act_prog triggers when the mob "sees" a specific echo. In this case, it would be something like
Code: Select all
>act_prog has been resurrected~
(do something here, with $n being the character who has just been ress'ed)
