[1154] in Coldmud discussion meeting

root meeting help first first in chain previous in chain previous next next in chain last in chain last

Re: [COLD] Is there a shortcut to @def?

daemon@ATHENA.MIT.EDU (Mon Dec 2 11:56:54 1996 )

Date: Mon, 2 Dec 1996 09:48:43 -0700 (MST)
From: Brandon Gillespie <brandon@glacier.cold.org>
To: Frank Crowell <frankc@maddog.com>
cc: Cold Stuff <coldstuff@cold.org>
In-Reply-To: <32A2BBD8.57CD781C@maddog.com>

On Mon, 2 Dec 1996, Frank Crowell wrote:
> [for Alpha4 Core]
> 
> I'm looking for a shortcut to @def.
> 
> I tried to use the example in the Admin's Guide, but I think
> I'm missing something: 
> 	;as $motd; server_name = "My New Server Name"
> 
> The way it worked for me was this way:
> 	@def $motd as $motd eval server_name = "My New Server Name";
> 
> If I didn't have @def available, how would I set any variable?

@def went away in Alpha5 in lieu of the 'as' syntax with eval, prefix a
"statement" to the eval starting with 'as' and followed by the ColdCore
way of formatting an object/definer, namely:

        $object<$definer>

The definer is optional.  Follow that by a semi colon and then the normal
eval from that point on.  This replaces both:

    @def xxx as yyy eval zzz        =>    ;as yyy<xxx>; zzz
    @as yyy eval zzz                =>    ;as yyy; zzz

-Brandon Gillespie