Re: [Circle] spec_proc question

From: The Chuckster (wcarson@umr.edu)
Date: 11/11/96


> well, I have created a new spec_proc called black_dragon.. <also going to
> have more, but not until this one starts workin' :P> anyways.. the mud
> compiles fine, and when I fight the mob.. he just attacks like normal..
> the spec never goes off.. I assigned the spec in spec_assign.c, put the
> following spec code in spec_procs.c.. not sure of anything else I need to
> do.. oh I also set NPC flag SPEC
> SPECIAL(black_dragon)
> {
>   struct char_data *vict;
> 
>   if (cmd || GET_POS(ch) != POS_FIGHTING)
>     return FALSE;
> /*                     /------normally 45, but I tried 1, and it still
>                        v      never called the spec */
>   if (number(1, 50) >= 1) {
>     act("$n breathes acid!", 1, ch, 0, 0, TO_ROOM);
>     for (vict = world[ch->in_room].people; vict; vict = vict->next_in_room) {
>       GET_HIT(vict) -= dice(GET_LEVEL(ch) / 20, GET_LEVEL(ch) / 10);
>       if (GET_HIT(vict) >= -10)
        ^^^^^^^^^ REMOVE THIS CHECK TEMPORARILY AND SEE IF IT WORKS?
>         send_to_char("You are burned by the acid!", vict);
>       update_pos(vict);
>     }
>   }
>   return TRUE;
> }
Are you getting the act message at all? Also, have you tested this with a char
higher than level 20? Also, I believe you may need a char_data *ch, not sure,
did this compile without warnings? Also, I just noticed, if you are the only
one in the room, and have AC greater than or equal -10, you do not get a message
sent to you. The spec could be working you just are not getting a message. Also
try making the damage really high and watch your hp's to see if it is doing any
damage.

good luck,
Chuck

When having probs of this sort, always set the chance of success to 100%, this helps
greatly.

+-----------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
|   http://cspo.queensu.ca/~fletcher/Circle/list_faq.html   |
+-----------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/18/00 PST