mob/beedrill
proc
levelcheck()
if(src.level==11)
src.verbs += new/mob/beedrill/verb/furyattack
src << "You have learned Fury Attack."
Problem description:
It says that there is an undefined path, is there something I need to add or what?
ID:143712
Jul 19 2007, 5:38 pm
|
|
Code:
mob/beedrill Problem description: It says that there is an undefined path, is there something I need to add or what? |
Basically you've not declared the verb "furyattack" (that you're saying should belong to <code>mob/beedrill</code>).
But what's the point in giving <code>mob/beedrill</code> furyattack if it's already meant to have it? What you really want is to declare that verb elsewhere - perhaps on another mob or datum. That way, beedrill won't come ready made with the fury attack verb- and can be given the attack later. In your case I'd probably make a datum containing all pokemon attacks. attacks Then in your levelcheck() proc you can give your pokemon a new attack like so: src.verbs += new/attacks/verb/furyattack Note- you can add procs to an object's verb list too, and storing your pokemon attacks as procs instead of verbs (unlike what I did in my example) might be a tad cleaner, although in ultimately it's got more to do with personal taste than anything else. [edit] Oh- your indentation on the last line is screwed up, too. The "You have learned Fury Attack." line is tabbed once too many times. |
That should work, there is probably a better way but thats how I do it, Although yours may work and it really is an undefined path...
-KirbyAllStar