could someone please explain to me how Order: works? Never used it before and now noticed the documentation gives me hints but I always fail. What I do is
Order:
if(action==##Follow) “TEST”;
and I define me a [ FollowSub; dummy routine. But “NPC, follow me” is not recognized. What am I supposed to do? “NPC, follow me” is what I need to parse, and if I learn how Order: generally works, all the better.
Order works pretty much like before. To make sure I was doing it right, I first created the new verb:
[code]Verb ‘follow’
* noun -> Follow
;
[FollowSub;
print "But “;
print (the) noun;
print_ret " isn’t moving.”;
];[/code]
I then gave my NPC a simple response to it:
Object Bob "Bob" study
with
name 'bob' 'man',
description "He's rather chubby, and his shirt tail isn't tucked in.",
following 0,
orders [;
Jump: "~Okay, watch me -- here I go!~ Bob takes a standing leap.";
Follow: if (noun == player) {
self.following = 1;
"~Sure thing. Where are we going?~";
}
else "~I'm not sure how to do that,~ Bob admits.";
]
has proper animate
;
In a real game, you would need to test whether Bob.following is true when the player character is in the process of moving. Does that make sense?