i cant get the skill to show in the menu. any1 know wat's wrong with it?
here's my skill object which is "Fly"
------------------------------------------------------------
obj
Skills
Fly
verb
Fly()
set category = "Battle Commands"
if(usr.SPARRING == "true")
usr << "Not while sparring."
if(usr.SPARRING == "false")
if(usr.FLYING == "true")
usr << "You landed on the ground..."
usr.density = 1
usr.FLYING = "false"
usr.MEDITATING = "false"
usr.icon_state = ""
else
usr << "You begin to float above...."
usr.density = 0
usr.FLYING = "true"
usr.MEDITATING = "false"
usr.icon_state = "buku"
------------------------------------------------------------
here is the proc to be activated.
------------------------------------------------------------
mob
proc
LEARNFLY()
if(usr.MPL >= 400)
if(usr.LEARNFLY == "false")
usr.LEARNFLY = "true"
usr.CONTENTS += new /obj/Skills/Fly
usr << "You have learned how to fly.!"
else
usr.MPL += 0
else
usr.MPL += 0
------------------------------------------------------------
i've already added "usr.LEARNFLY()" to the verbs that makes it learn the skill. when i reach the 400 PL mark (which is the point when you learn this skill) it does says "You have learned how to fly!". but it doesnt shows up in the menu.
ID:147921
![]() Sep 28 2003, 12:04 am
|
|
ZDarkGoku wrote:
no help at all but i fixed it. it supposed to be usr.contents instead of usr.CONTENTS It's not supposed to be usr at all, because that line is in a proc. It's not safe to put usr in procs unless you absolutely know what you're doing with it, which you don't. Use src there instead. Lummox JR |
Lummox JR