ID:150328
 
Is there some special instance in which a verb can be in the verbs list of a mob, neither hidden nor invisible, and yet not be accessible to the client connected to that mob? Checks to see if the verb is in usr.verbs indicate that it's there, but I can't use it. Adding them to usr.client.verbs works, so it stands to reason that usr in this instance is in fact that mob I'm connected to. To my knowledge I'm not doing anything I've never done before in previous projects (which are still working fine), which is why I find this so disturbing.
You could always do somthing like this:

instead of:

obj/verb/Get()
set src in oview(1)
src.Move(usr)

you could try:

obj/verb/Get()
set src in world
if(src in usr.oview(1))
src.Move(usr)

Is that what you are talking about?

[edit] I see that Get() probably isn't the most useful example here... I'm taking about the set src in world command [/edit]
In response to Lord of Water
No, I'm talking about adding verbs to a mob's verb list (their .verbs var). For example, suppose that to keep my verb panels clean, I make it so that there's a verb called "spells" which will bring up a seperate verb panel with the verbs "spell1", "spell2", and "spell3", and which they can use a second time to close their spell list. Here's roughly what I'm doing:

/spell_list
verb
spell1()
set category = "Spells"
Do_Stuff(1)

spell2()
set category = "Spells"
Do_Stuff(2)

spell3()
set category = "Spells"
Do_Stuff(3)

/mob
verb
spells
if (/spell_list/verb/spell1 in src.verbs)
src << "You open up your spellbook."
src.verbs -= typesof(/spell_list/verb)
else
src << "You close your spellbook."
src.verbs += typesof(/spell_list/verb)


This obviously isn't my actual code, but it demonstrates the procedure. Moreover, this example seems to work (with a little wiggling) just fine... however, in the project I'm actually working on, when I attempt to use this method it will correctly report the message for adding or removing the verbs (so the verb is in the mob's .verbs), but the verbs do not show up and aren't accessible unless I assign them to src/usr.client instead of src/usr.
In response to Leftley
Leftley wrote:

This obviously isn't my actual code, but it demonstrates the procedure. Moreover, this example seems to work (with a little wiggling) just fine... however, in the project I'm actually working on, when I attempt to use this method it will correctly report the message for adding or removing the verbs (so the verb is in the mob's .verbs), but the verbs do not show up and aren't accessible unless I assign them to src/usr.client instead of src/usr.

I think you'll need to isolate the problem a bit further for us. I tested your example, and as you said, it seems to work correctly. Based on your santiy checks, it sounds like you have stumbled upon a bug, but we'll need a working example to get anywhere with it. Thanks!
In response to Leftley
Leftley wrote:
This obviously isn't my actual code, but it demonstrates the procedure. Moreover, this example seems to work (with a little wiggling) just fine... however, in the project I'm actually working on, when I attempt to use this method it will correctly report the message for adding or removing the verbs (so the verb is in the mob's .verbs), but the verbs do not show up and aren't accessible unless I assign them to src/usr.client instead of src/usr.

I'm curious... are you able to call the verbs with call(usr,"theverb")(args)?

Because one of the things I'm interested in for Cerulea is having verbs in the usr's .verbs, but forbidding them from showing up in expansion (set hidden = 1 isn't good enough for a few reasons). And if you can still call() the verbs, why, I'd just figure out exactly what you did to make your verbs inaccessible and do it myself.

Or I could just ask Tom and Dan for a variable that turns off expansion.

Z