mob/Magic/verb
Fireball()
LightingStrike()
mob/Illusion/verb
DoubleVision()
Reflection()
mob/verb/CountSpells()
var/amount=count()
usr<<"You have [amount] Spells"
mob/proc/count()//this is what I have problems with
var/ammount=0
for(var/mob/Magic/verb in src.verbs)
ammount+=1//for every Magic verb you have, +1 to the ammount
for(var/mob/Illusion/verb in src.verbs)
ammount+=1//same for every Illusion spell
return ammount
//This is the whole code, it doesn't give any errors or anithing, but it just doesn't work, it always returns 0
Problem description: I want to count certain types of verbs a user has
That would be another way to do the things. I tried to test for checking every verb in the mob verbs but it's only possible if you don't define the path type of the var like: