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

Comparing deliantra/maps/perl/bank.ext (file contents):
Revision 1.19 by elmex, Tue Jul 11 16:56:27 2006 UTC vs.
Revision 1.20 by root, Wed Jul 19 08:52:57 2006 UTC

160 } 160 }
161 161
162 if ($cmd eq "balance") { 162 if ($cmd eq "balance") {
163 if ($who->flag (cf::FLAG_WIZ)) { 163 if ($who->flag (cf::FLAG_WIZ)) {
164 if (my $player = cf::player::find $arguments) { 164 if (my $player = cf::player::find $arguments) {
165 $who->message ("$name says: ".balance ($player->ob, 1), cf::NDI_WHITE); 165 $who->reply ("$name says: " . balance ($player->ob, 1));
166 } 166 }
167 } else { 167 } else {
168 $who->message ("$name says: ".balance ($who, 0), cf::NDI_WHITE); 168 $who->reply ("$name says: " . balance ($who, 0));
169 } 169 }
170 170
171 } elsif ($cmd eq "balance" and !$arguments) { 171 } elsif ($cmd eq "balance" and !$arguments) {
172 $who->message ("$name says: Balance of whom?", cf::NDI_WHITE); 172 $who->reply ("$name says: Balance of whom?");
173 173
174 } elsif ($cmd eq "deposit" and $currency) { 174 } elsif ($cmd eq "deposit" and $currency) {
175 $who->message ("$name says: " . (transaction $who, "deposit", $amount, $currency), cf::NDI_WHITE); 175 $who->reply ("$name says: " . (transaction $who, "deposit", $amount, $currency));
176 $who->message ("$name says: " . (balance $who), cf::NDI_WHITE); 176 $who->reply ("$name says: " . (balance $who));
177 177
178 } elsif ($cmd eq "deposit" and $amount and $currency eq "") { 178 } elsif ($cmd eq "deposit" and $amount and $currency eq "") {
179 $who->message ("$name says: Deposit $amount of what: $units", cf::NDI_WHITE); 179 $who->reply ("$name says: Deposit $amount of what: $units");
180 180
181 } elsif ($cmd eq "deposit" and $amount eq "" and $currency eq "") { 181 } elsif ($cmd eq "deposit" and $amount eq "" and $currency eq "") {
182 $who->message ("$name says: How much do you want to deposit?", cf::NDI_WHITE); 182 $who->reply ("$name says: How much do you want to deposit?");
183 183
184 } elsif ($cmd eq "withdraw" and $currency) { 184 } elsif ($cmd eq "withdraw" and $currency) {
185 $who->message ("$name says: " . (transaction $who, "withdraw", $amount, $currency), cf::NDI_WHITE); 185 $who->reply ("$name says: " . (transaction $who, "withdraw", $amount, $currency));
186 $who->message ("$name says: " . (balance $who), cf::NDI_WHITE); 186 $who->reply ("$name says: " . (balance $who));
187 187
188 } elsif ($cmd eq "withdraw" and $amount and $currency eq "") { 188 } elsif ($cmd eq "withdraw" and $amount and $currency eq "") {
189 $who->message ("$name says: Withdraw $amount of what: $units", cf::NDI_WHITE); 189 $who->reply ("$name says: Withdraw $amount of what: $units");
190 190
191 } elsif ($cmd eq "withdraw" and $amount eq "" and $currency eq "") { 191 } elsif ($cmd eq "withdraw" and $amount eq "" and $currency eq "") {
192 $who->message ("$name says: How much do you want to withdraw?", cf::NDI_WHITE); 192 $who->reply ("$name says: How much do you want to withdraw?");
193 193
194 } elsif ($cmd eq "exchange") { 194 } elsif ($cmd eq "exchange") {
195 $who->message ("$name says: This function is not yet implemented. Ask me again later.", cf::NDI_WHITE); 195 $who->reply ("$name says: This function is not yet implemented. Ask me again later.");
196 196
197 } elsif ($cmd eq "help" or $cmd eq "yes" and $arguments eq "") { 197 } elsif ($cmd eq "help" or $cmd eq "yes" and $arguments eq "") {
198 $who->message ("$name says: " . (help $arguments), cf::NDI_WHITE); 198 $who->reply ("$name says: " . (help $arguments));
199 199
200 } elsif ($cmd eq "help" or $cmd eq "yes" and $arguments ne "") { 200 } elsif ($cmd eq "help" or $cmd eq "yes" and $arguments ne "") {
201 $who->message ("$name says: " . (help), cf::NDI_WHITE); 201 $who->reply ("$name says: " . (help));
202 202
203 } else { 203 } else {
204 $who->message ("$name says: Do you need help?", cf::NDI_WHITE); 204 $who->reply ("$name says: Do you need help?");
205 } 205 }
206} 206}
207 207

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines