okay, when you make a new verb, you can right click on a mob and a drop down menu will appear, containing that verb.
however, it apepars on npcs and players. how do I make a verb ONLY accessible through NPCs. not the if(M.key) thing, i mean not show up altogether. if possible.
if its not possible, thats a good feature to include in the next version! =P
1
2
ID:137858
Jul 1 2001, 7:37 pm
|
|
In response to LexyBitch
|
|
thank you very much, i appreciate it greatly, but.. now theres another problem with it. when you click on the verb, it pops up with a dialog giving you a choice of who to talk to. including players. don't want it to do that, any way to fix it?
one more question, that pertains manly to statpanels. how do I hide, or show a stat panel? for instance: mob/player/verb/say(msg as text) set category="Communication" it woudl create a new panel called 'Communication' but i don't want it to show. how do i make it not show? |
In response to XgavinX
|
|
On 7/1/01 11:26 pm XgavinX wrote:
thank you very much, i appreciate it greatly, but.. now theres another problem with it. when you click on the verb, it pops up with a dialog giving you a choice of who to talk to. including players. don't want it to do that, any way to fix it? It shouldn't do that. Does your verb still have (mob/whatever as mob) as an argument? The way I told you, there should be no arguments. The other possibility is that you've defined the verb for all mobs, not just npc ones. one more question, that pertains manly to statpanels. how do I hide, or show a stat panel? for instance: Kind of a silly question... the only reason to set a category on a verb is if you want it to appear in its own little panel. If you want it to stay in the main panel, don't set the category... if you want it to be completely invisible, set hidden = 1 |
In response to LexyBitch
|
|
its not that silly of a question. I have a panel for immortal commands, however I want only immortal to see it. therefore i would want to set its visibility IF the player is an immortal.
thank you for your help. |
In response to XgavinX
|
|
On 7/3/01 12:44 am XgavinX wrote:
its not that silly of a question. I have a panel for immortal commands, however I want only immortal to see it. therefore i would want to set its visibility IF the player is an immortal. Then simply declare the immortal verbs in the immortal mob and be careful about your set src commands. The src of all these verbs will be the immortal, so you don't want to give other people access to them. The usr will also be the immortal. The default for mob verbs is set src = usr so you should be safe as long as you don't set src in the immortal verbs. If the verb is performed on other people, places or things make an argument for them. mob/player/immortal verb boot(mob/M in world) set category = "Immortal" world << "[usr] boots [M]." del(M) |
In response to Shadowdarke
|
|
i don't want to set immortal commands in a mob, immortal. i want to keep all player actions in player, and all NPC actions in NPC. i just want to 'hide' the immortal panel from the other people, whom's level is not high enough to view it.
i know to use an argument, but my question was how to make that argument only accesible on NPCs, without a dialog popping up allowing you to choose anyone on the screen. I figured this out already. i simply did set src=view(1) thank you for your help though with my questions. i really appreciate it. |
In response to XgavinX
|
|
set src=view(1) Um. If player mobs are popping up in the window when you have src in view(), then if you stand next to a player mob and use this verb, you'll still talk to them. And, if I'm remembering correctly, if you stand next to two mobs, you'll have no control over which one you're using the verb on. As for the immortal panel, define the verbs somewhere besides PC and NPC... just as disembodied procs floating in the code. Add them to the player's .verbs when they reach a certain level. You'll have to check the players' levels as they log on, too, because changes to .verbs aren't saved. |
In response to LexyBitch
|
|
On 7/3/01 7:33 am LexyBitch wrote:
set src=view(1) i haven't tested it with more than 1 mob by each other. if i DO get a popup dialog with more than 1 mob, then thats okay i guess. incase they want to distinguish between the two of wich to talk to. thanks for the help on panels. i'm gonna ahve to mess around with it a bit mroe to fully understand it. |
In response to XgavinX
|
|
i haven't tested it with more than 1 mob by each other. if i DO get a popup dialog with more than 1 mob, then thats okay i guess. incase they want to distinguish between the two of wich to talk to. Um. What the f*** are you talking about? This isn't a response to anything I said. |
In response to XgavinX
|
|
On 7/3/01 6:55 am XgavinX wrote:
i don't want to set immortal commands in a mob, immortal. i want to keep all player actions in player, and all NPC actions in NPC. i just want to 'hide' the immortal panel from the other people, whom's level is not high enough to view it. In that case, define these immortal verbs as procs. (Leave them axactly as the verb, but move them to the proc declarations.) When the player acheives immortal status, add all the immortal procs to the players verbs list. http://www.byond.com/docs/ref/info.html#/atom/var/verbs tells you all the details. You have to remember to add the verbs each time the player is loaded too. Verb lists aren't automatically saved. |
In response to LexyBitch
|
|
Um. What the f*** are you talking about? This isn't a response to anything I said. actually it is: And, if I'm remembering correctly, if you stand next to two >mobs, you'll have no control over which one you're using |
In response to XgavinX
|
|
On 7/3/01 7:46 am XgavinX wrote:
Um. What the f*** are you talking about? This isn't a response to anything I said. No, actually, it is not. How is "If a dialog pops up that's fine", a dialog signifying a control mechanism, a valid response to "you'll have no control", signifying, a lack of a control mechanism? It's as if I said, "And the sky will turn as black as sack-cloth", and you respond with, "Good. I wouldn't mind a little sun." Not only that, but you completely ignored the more important point: that this probably will not prevent PCs from being valid "talk targets", if they were showing up in your dialog box before. |
In response to Shadowdarke
|
|
On 7/3/01 7:45 am Shadowdarke wrote:
On 7/3/01 6:55 am XgavinX wrote: oh no, i'm confused. -ponder- i'm gonna go do some testing, and mess with it a bit. then maybe i'll understand why i'm confused. its really strange being ocnfused about why i'm confused. are you confused? i'm really confused. |
In response to LexyBitch
|
|
OOPS, just MAYBE i might have OVERLOOKED and MISREAD something in YOUR response. I have not tested on 2 mobs. therfore i don't know for SURE if it chooses one at random. when i FIRST read your post, i thoguht you that that you woudl STILL have control over wich one if more than 1 mob was close enough. please FORGIVE me. for I haven't slept in over a day. so my mind is a bit groggy.
the verb does a check to see if its a player. then it returns. and a player doesn't have say_msg, so theres ntohing to output. and i don't know how to NOT be able to target a player. cuz i'm stupid and this language is confusing the shit outa of. so even if you DID talk to a player, it would do nuthing, and the player would realize "Gosh, the designer and programmer is a dumb ass and talk does nothing on other players. No need to use it on other players then." and everything will be okay. so theres no worries at all. everything works out fine. dumb ass me will continue asking dumb as onvious answers. becuase this language is way easier than C/C++, therfore it confuses me. I have C/C++ down like the back of my hand. so this is a BIG change. please forgive me everyone. i'm sorry I am a dumb ass. |
In response to XgavinX
|
|
On 7/3/01 7:50 am XgavinX wrote:
On 7/3/01 7:45 am Shadowdarke wrote: Maybe an example will help... mob/player/proc smite() set src in view() set category = "Immortal" view() << "[usr] smites [src] with immortal might!" now this goes somewhere in your levelup proc: if(level > IMMORTALLEVEL) // you should #DEFINE IMMORTALLEVEL someplace ;) verbs += /mob/player/proc/smite // allows immortals access to the smite() proc as a verb Procs don't appear in any panels until they are put in a verb list, then they are treated exactly as any other verb. |
In response to XgavinX
|
|
On 7/3/01 7:57 am XgavinX wrote:
OOPS, just MAYBE i might have OVERLOOKED and MISREAD something in YOUR response. I have not tested on 2 mobs. therfore i don't know for SURE if it chooses one at random. when i FIRST read your post, i thoguht you that that you woudl STILL have control over wich one if more than 1 mob was close enough. please FORGIVE me. for I haven't slept in over a day. so my mind is a bit groggy. I'm sorry you're a dumb ass, too. I suspect that the real reason you are confused, though, is that you aren't reading things carefully. If your verb is actually defined under mob/npc and has no arguments, that is nothing in parantheses and simply uses usr as the player and src as the npc there is no way to target a player. mob/npc/verb/talk(NOTHING GOES HERE) set src in or = oview(talking range) usr << "src says, \"[src.message]\"" |
In response to Shadowdarke
|
|
aaaahhhhhhhh... yes.... finally. a perfectly good example of exactley how I want to do it. Thank you, thank you, thank you. i appreciate it very much. i completely 100% understand.
i did not now it would work like that. but now i know! =P but then i'd have to do that with EVERY proc and verb... say i wanted to give a player a skill or spell depending on something him/her did. like gaining a level, or using practice points to some degree. i woudl have to check the amount or level and decide what to do on EVERY proc and verb. well, that will come later. i'll probably ifgure it out. i don't want to jump ahead of myself(not even in the skill/training part of my game yet, so nothing to worry about until then). thanks. i really appreciate it. |
In response to LexyBitch
|
|
i'm
sorry i was so confused. this verb shit is pretty new to me. i see what you are saying now, and with a little testing i did earlier it completely makes since. i ' m s o r r y t o b o t h e r y o u w i t h m y s t u p i d i t y . p l e a s e f o r g i v e m e o h <font color=red>bitchful</font> o n e . |
In response to XgavinX
|
|
On 7/3/01 8:10 am XgavinX wrote:
thanks. i really appreciate it. No problem. The hardest part about coding is defining the problem. The solution is easy ;) |
1
2
mob/npc/verb/talk()
set src in oview()
Of course, mob/npc assumes that this is what you call your npc mobs. Substitute whatever you're actually using as a root for all your npcs.
See, normally when you make a verb on a mob, it's a verb that the mob itself can use... the default src=usr, I believe... but if you over-ride src to be in oview()... then it becomes a verb that is used by others around the mob.