valis
Apprentice
Posts: 1
|
Post by valis on Jun 6, 2009 21:41:26 GMT -5
I'm trying to figure out some issues with building and the guide is a little vague.
Specifically I want to create an action attached to an item, the item is a stungun, then action is stun. I want it to display "Valis prods <persons name> with a stungun" to people in the room, "Valis prods you with a stungun" to the target, and "You prod <person's name> with your stungun." to me.
I've created the item, and attached Stun to it as an action, but it won't use the pronouns correctly.
I'd also like to have eventually transport the target to a room called "unconcious" for 2 minutes, then return the target to whatever room they were in when stunned.
Also, I'd like to work on putting together some mob programs (zombie progs in this codebase?) to create some interactions....
Anyone point me to a better building tutorial than the regular guide?
|
|
|
Post by gravecat on Jun 28, 2009 22:37:33 GMT -5
Okay, hurr. This is probably completely wrong but let me attempt to formulate some kind of half-sane answer. If this isn't entirely coherent, blame the kievs. They've been in the fridge for a while, if you get my meaning. Anyway. One way to do it is simply use @succ for what you see, and @osucc for what everyone else sees, then kludge the victim's viewpoint in there somewhere. Bad idea. Here's how I'd do it, because I'm arrogant enough to assume a righteous stance on the matter: Ignore @osucc entirely, and do the whole thing in @succ with a little MPI script. Now, assuming you've linked the action correctly -- i.e. make sure you @link it to $nothing, or whatever appropriate do-nothing script exists on Chimaera (hey, I just keep the server running and occasionally trip over it, I don't really know how the internals work), just slap something like this on @succ: @succ <action name here> = {null:{tell:message to user here,me}{tell:message to victim here,{pmatch:{&arg}}{otell:message to everyone else here,{loc:me},{&pmatch:{&arg}}} This is where we start to have problems, yes. The problems arise because (a) Chimaera doesn't appear to have a {pmatch} macro and I'll be damned if I can remember how we survived back in the days before them, and (b) the part about transporting targets to rooms, creating mob programs, etc, are far, FAR beyond the realm of mere MPI. So, to conclude: I could explain in better detail how to do something like this in MUF (and/or install a {pmatch} macro on Chimaera sometime, assuming the admins don't object), but fundamentally, what you're describing is something that should really be written in pure MUF, and would require at minimum an M3 bit to function at all. As for mob/zombie programs... I'd recommend not. I spent a number of months working on something similar myself, and believe me, it's far too complex and really not worth the trouble. From someone who coded MPI and MUF for several years straight, take it from me, it's not something anyone with a modicum of sanity should attempt on a FuzzBall codebase.
|
|
|
Post by gravecat on Jun 28, 2009 22:39:00 GMT -5
Also, I didn't test that MPI at all, and it probably doesn't work; this is all off the top of my head, I haven't dabbled in such dark, arcane arts for a few years now. However, once I'm feeling a little more coherent and a little less megalomaniacal, I'll come back and attempt an explanation of how such a thing could be implemented in MUF.
|
|