making a $p (person wielding) isnt that hard, i dont think, i've looked at
the code... under cmd_eval_obj() look for the $ cases... add case 'p'
lval_char = obj->carried_by or something like that...

getting them to cast is another matter, if you notice all the spell_fun's
need a char_data, so you'd have to make a NULL char data, like people showed
me before, then then somehow make the object seem like it cast it...
conversely it might be easier to make the person wielding it cast the
spell... add a new obj command (under the oforce and stuff, for ocast or
something, that did the spell fun with the person holding it as the caster?

I've been just messing with mobprogs myself, and dont understand them fully
yet... the best thing to do is just play around and understand the code you
patched first... personally i hate patching in code i dont understand fully,
so i go study it first.

Josh

----- Original Message -----
From: "oioi" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Wednesday, April 17, 2002 7:24 PM
Subject: pet peeve, re: Obj progs


> Damnit.  I got the wonderfully laid out snippet of how to put object progs
> and room progs into a rom24 code that already had olc with mob progs.
>
> I spent the time, put it in, fixed the errors, and promptly started to
code
> the various progs needed for my mud.
>
>
> The problem is....I have become mostly convinced that there is no real way
> to do 98% of what myself and my builders WANT to do with object progs.
>
> My biggest wish...is to have a $* value that you can put in object code
that
> would stand for the character(or mob) who wore/held/wielded the item.
>
> for most of the triggers to the progs (such as random, fight, speech)...$n
> doesn't really work.
>
> $r works....if the person wearing the item doesn't enter a room with other
> creatures (walking into a room with a mob reset's $r as the name of the
mob.
>
> my deepest wish at this point in time would be to know how I could add
> another $* target for obj progs...
>
> any time the objprog goes off...the new $* target would be whoever
> wore/held/wielded the item.
>
> But, I don't have the coding knowledge to do so...and I've spent a good
day
> and a half working on trying to force obj progs to always and only...and
> consistently...fire (let me say ONLY again) on the wearer of the item.
>
>
> I do have another dream as well.
>
> using obj vforce [vnum]
>
> you can make the mob point, emote, social, talk, yell...
>
> but for some reason you can't get the damned thing to cast.
>
> I created a mob...with the same short name as the item...and a long
> intricate name so that only that one mob would be affected...
>
> using (for example)
> obj mload 26
> obj vforce 26 nudge $r   <- of course, there is no $* argument that I know
> of that will point to the right person
> obj vforce 26 ' what the
> obj vforce 26 c continual
> obj purge specialswordobjprogmob
>
>
> everything works...but the spell. (put the spell in quotes, and it takes
the
> quote to mean "say")
>
> I've tried every spell in stock rom....none work.  I've checked that the
> item was higher rank than the mob so the force would work...I've checked
> that the mob had mana to cast...
>
> so...I guess I have two "over the rainbow..it would be a perfect world
if.."
> wishes.
>
> a $* target for the wearer...
>
> and a way to have objects cast...(or a way for them to force mobs to cast)
>
>
> Out of those of you who have read this far down my long train of thought
> ramble...if any of you could offer some insight or help or direction on
how
> I can fulfill those two wishes...I would be eternally greatfull.
>
> --
> ROM mailing list
> [email protected]
> http://www.rom.org/cgi-bin/mailman/listinfo/rom


Reply via email to