In my current project, I want to have some fairly specific control of when certain verbs are accessible for the skill system, but I can't seem to get my head around how I'm going to do it.
The way I'd like to set things up is so that verbs can be accessible from objs (via setting the src), but only by certain people. So, for instance, someone has the 'cut down tree' skill, and the trees have the 'cut down' verb. People with the skill can access the verb, but no one else can.
Hopefully I'm explaining this in a decypherable manner. Thinking about this has been giving me a head ache.
ID:167203
Apr 15 2006, 3:01 pm
|
|
In response to Pyro_dragons
|
|
no put usr in proc No offense meant, but what process? The way I'd like to set things up is so that verbs can be accessible from objs (via setting the src), but only by certain people. So, for instance, someone has the 'cut down tree' skill, and the trees have the 'cut down' verb. People with the skill can access the verb, but no one else can. Well, the easiest way then would probably be to give them a skill object in their contents, and then use "set src in usr" in the verb. That way, only players with that object can use the verb. |
In response to DarkCampainger
|
|
But when the verb's src is another object entirely. I'm starting to think that there's no particularly simple way to do this, and I'll just need to get over the fact and actually do some programming. I'd love to be informed that I'm wrong, though.
|
In response to Gathin
|
|
Just make the verb take an argument, which is the tree.
obj/skill/Cut_down_trees Then anyone with an /obj/skill/Cut_down_trees object in their inventory will be able to use the cut_tree verb on nearby trees. There is one small issue with this method; namely, if there are multiple trees in oview(1) and the player clicks the cut_tree verb in their verb panel (as opposed to right-clicking or using a macro), a popup will appear asking them which tree to cut down. That can be annoying, but the only way to fix it is to make the verb belong to the tree, which means that everyone will be able to see it. If that's a problem for you, then you might want to consider other methods of control, such as clicking trees or bumping into them to cut them down. |
In response to Crispy
|
|
If that's a problem for you, then you might want to consider other methods of control, such as clicking trees or bumping into them to cut them down. Oi, good point. Command panels are silly things, anyway. Thanks. |
I suppose something like that, but I'm not so sure. Never really tried it. Yeah, I know, no put usr in proc, ungh, but it I'm just trying it, don't yell please.