[Home] [Groups] - Message: [Prev in Group] [Next in Group]
66: command parsing
[Full Header] [Plain Text]
From: claw@null.net
Newsgroups: nu.kanga.list.mud-dev
Date: Mon, 17 Mar 97 09:30:32 -0800
References: [1]
Organization: Kanga.Nu
On 12/03/97 at 10:23 PM, cg@ami-cg.GraySage.Edmonton.AB.CA (Chris Gray)
said:
>:I guess it's the difference between making a wall and letting users get
>:over it in whatever way they can manage (whether it be flying, climbing,
>:becoming non-corporeal and walking through, or even smashing it down)
>and :doing a script like:
>:
>:if token++.Is("climb") and token.Is("wall")
>: room_message("$n scale$s the wall.", ch);
>: move_char(ch, UP)
>You're going to have to have a very general scenario in order for all of
>those methods of getting past the wall work! You're not going to get any
>of them for free, I suspect.
I suspect that the solution to the general case for this sort of
limitation (eg can he get over the wall) is to fract the problem into an
attempted motion in a direction (which is easy to code for the success
failure of), and a generalist reaction to motions. In the case of the
wall, if he can somehow get "up" (or "scale" or whatever you call the
verb), you do that. If he then achieves the position of being atop the
wall, you then report or react that.
This comes back to coding in general physical laws into the world, and
then presuming that they will ensure correct behaviour.
--
J C Lawrence Internet: coder@null.net
----------(*) Internet: coder@ibm.net
...Honourary Member of Clan McFud -- Teamer's Avenging Monolith...