ID:138939
 
Code:
mob/skill/verb
Rei_Blast()
set category = null
if(safe) return
if(se < 10)
src << "<b>Your Energy is to low wait for it to recover!"
return
if(!firing)
view(8) << "<b>[src]: Blast"
firing = 1

se -= 10
var/obj/K = new/obj/Eatk(loc)

K.Gowner = src
K.dir = dir
walk(K, dir)

obj/SkillButtons
ReiGunButton
icon='icons.dmi'
icon_state="rei"
Click()
src.Rei_Blast()


Problem description:
I have gotten this far in my attempt to make skill cards vs a massive list if verbs cluttering up a players stat panel thanks to the community here on byond now this issue has come up something that really annoys me is the undefined proc how would I define it. It works fine as a strait verb but when i try to convert it to a skill card it gives me the error

Rei_Blast() is a mob/skill verb, meaning only mobs can use it. You're doing src.Rei_Blast(), the src is an obj not a mob. Make it usr.Rei_Blast()
In response to Ill Im
Ill Im wrote:
Rei_Blast() is a mob/skill verb, meaning only mobs can use it. You're doing src.Rei_Blast(), the src is an obj not a mob. Make it usr.Rei_Blast()

Ok I tried that still did not work
mob/skill/verb
Rei_Blast()
set category = null
if(safe) return
if(se < 10)
src << "<b>Your Energy is to low wait for it to recover!"
return
if(!firing)
view(8) << "<b>[src]: Blast"
firing = 1

se -= 10
var/obj/K = new/obj/Eatk(loc)

K.Gowner = src
K.dir = dir
walk(K, dir)

obj/SkillButtons
ReiGunButton
icon='icons.dmi'
icon_state="rei"
Click()
usr.Rei_Blast()
In response to Wrath69
Try just having rei_blast() be a verb instead of /skill/verb
In response to Lugia319
that seems to work ill test it in a moment
In response to Wrath69
great it worked thanx very much
In response to Wrath69
I don't know the technical reason precisely, but I find that it's hard to call verbs that the player doesn't technically have. So the fix is one of two.

Either A. Give the player all of the "skills" verbs upon login.

B. The solution that I just gave.

One thing I do need to test myself later, part A with 2 defined verbs with the same name...
In response to Lugia319
They really need to make a demo on this stuff lol I may have another issue about adding the skill card to my inventory after it bought from a tree but first I will see if the snippit I just added will work cause it compiled with no errors
In response to Wrath69
They would make a demo if it wasn't so blatantly obvious in general. They probably actually have a demo/library on it already under the name of Skill HUD or something.
In response to Lugia319
I dont think they do I trolled the resources section for the better part of a hour and could find nothing