ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/maps/perl/eval.ext
Revision: 1.1
Committed: Fri Mar 31 20:21:19 2006 UTC (18 years, 1 month ago) by root
Branch: MAIN
Log Message:
add first implementation of a generic eval plug-in

File Contents

# User Rev Content
1 root 1.1 #! perl
2    
3     # generic perl code evaluator
4    
5     # currently say only
6     sub on_say {
7     my ($event) = @_;
8     my ($event, $ob, $msg, $options) = @$event{qw(event who message options)};
9    
10     local $_ = $msg;
11     eval $event->message
12     }