ID:161483
May 2 2008, 1:13 pm
|
|
I'm wanting to make a spy verb. Pretty simple. I want the client's eye to be switched to a mob's eye. I can't figure out how to do it though x_x
|
In response to Garthor
|
|
I read the stuff on the eye and perspective, but it didn't really help me because it didn't tell me how to change it from yourself to something else (though it did show how to change it to a location, but that's not really what I wanted.)
I tried it this way, but it didn't work. mob/verb |
In response to GohanIdz
|
|
Try client.eye=M
Or if you don't want to spy on a black screen if they are out of your view, change client.perspective to EYE_PERSPECTIVE. When you're done, change it back to MOB_PERSPECTIVE. |
In response to Kaiochao
|
|
verb Heres my code and it works perfectly for me, hope it helps. |
In response to Element Hero creator
|
|
Ah yes, that works very well ^^;
Now, would there be any way so that I'd also be able to hear what they're saying? Here's my say verb: Say(msg as text) |
In response to BUProductions
|
|
BUProductions wrote:
Now, would there be any way so that I'd also be able to hear what they're saying? Since the player mob isn't really at that location but is only viewing it, it won't be included into lists like view() (and by the way, you're using the wrong proc for things like Say()- should use viewers() or even better, hearers(). look them all up in the DM Reference to see the difference). But like said above viewers() wouldn't work either for your question. Unfortunately there isn't another, suitable built-in proc for this that will include everything the player himself can see instead of his mob. May be a good suggestion. So if you want to make the watcher hear what they're saying as well, you'd have to do a workaround such as put his actual mob there (you could create a new, dummy base type /mob and connect him to it instead of putting his "real" mob there) but you'd possibly need to account for it throughout your code; if you have an explosion proc then you'd need to make it ignore the dummy watcher mob, possibly the same for your attack verb and other things, etc. Another way would be to change your Say() verb so it will also send the message to people watching the speaker, similarly to how a "Hear Everyone" admin feature is done. |
In response to BUProductions
|
|
Not sure how to make it so they can see your text, best way to to make it through world or make a whisper verb >.>
|
Look those up in the reference.