ID:155146
 
My question as the title suggests is How do I add my skill verbs after I buy the skill like if a player buys Rei Gun how do i give them the verbs for the skill I will include the skill tree code to buy the skill as well as the verb code if someone is willing to help simply post below

The Code to Buy the skill
Player
Gun {icon_state="rei"}
Dragon{icon_state="dragon";reqskill=Gun}
Gun2 {icon_state="rei2";reqskill=Gun;reqskilllvl=2}


The Verb Code
mob
skill
verb/Rei_Gun()
set category = "Specil Techs"
if(safe) return
if(se < 10)
src << "<b>Not enough enegry!"
return
if(!firing)
view(8) << "<b>[src]: Spirit Gun"
firing = 1

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

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


mob/skill/verb/Laser()            // Our awesome skill
view() << "IMA FIRIN' MA LAZAH!!! BLAGHHHHH!!!"


mob/verb/Buy_Skills(
var/skill = input("What skill would you like to buy?","Buy Skill")in list("Laser","All","Nothing")
if(skill == "Laser") // If they choose Laser
usr.verbs += /mob/skill/verb/Laser // Add the verb to their verbs
else if(skill == "All") // If they choose all
usr.verbs += typesof(/mob/skill/verb) // Add all the verbs with the path /mob/skill/verb, to their verbs


This is just an example, so you can learn how to add verbs to a mob on certain occasions.

- Hashir