ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/maps/perl/tell.ext
(Generate patch)

Comparing deliantra/maps/perl/tell.ext (file contents):
Revision 1.2 by pippijn, Sat May 6 20:29:44 2006 UTC vs.
Revision 1.3 by pippijn, Sat May 6 20:38:56 2006 UTC

28 } 28 }
29}; 29};
30 30
31cf::register_command reply => 0, sub 31cf::register_command reply => 0, sub
32{ 32{
33 my ($who, $args) = @_;
33 my $name = $who->name; 34 my $name = $who->name;
34 35
35 if (my $other = cf::player::find $who->{ext_last_tell}) 36 if (my $other = cf::player::find $who->{ext_last_tell})
36 { 37 {
37 if ($other->ob->{ext_ignore_tell}{$name} < time) { 38 if ($other->ob->{ext_ignore_tell}{$name} < time) {
38 delete $other->ob->{ext_ignore_tell}{$name}; 39 delete $other->ob->{ext_ignore_tell}{$name};
39 } 40 }
40 if (!$other->ob->{ext_ignore_tell}{$name}) { 41 if (!$other->ob->{ext_ignore_tell}{$name}) {
41 $who->message ("You tell $target: $_"); 42 $who->message ("You tell ".$other->ob->name.": $args");
42 $other->ob->message ("$name tells you: $_"); 43 $other->ob->message ("$name tells you: $args");
43 $who->{ext_last_tell} = $other->ob->name; 44 $who->{ext_last_tell} = $other->ob->name;
44 } else { 45 } else {
45 $who->message ($other->ob->name." ignores what you say. Give up on it.", cf::NDI_UNIQUE); 46 $who->message ($other->ob->name." ignores what you say. Give up on it.", cf::NDI_UNIQUE);
46 } 47 }
47 } 48 }
48 else 49 else
49 { 50 {
50 $who->message ("Can't reply, player left. Your message: ".$_, 51 $who->message ("Can't reply, player left. Your message: ".$args,
51 cf::NDI_UNIQUE); 52 cf::NDI_UNIQUE);
52 } 53 }
53}; 54};

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines