ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/Deliantra-Client/bin/pclient
(Generate patch)

Comparing deliantra/Deliantra-Client/bin/pclient (file contents):
Revision 1.222 by elmex, Wed May 17 10:33:03 2006 UTC vs.
Revision 1.230 by root, Fri May 19 23:18:42 2006 UTC

1#!/opt/bin/perl 1#!/opt/bin/perl
2 2
3use strict; 3use strict;
4use utf8; 4use utf8;
5 5
6# do things only needed for single-binary version (par)
6BEGIN { 7BEGIN {
7 if (%PAR::LibCache) { 8 if (%PAR::LibCache) {
8 @INC = grep ref, @INC; # weed out all paths except pars loader refs 9 @INC = grep ref, @INC; # weed out all paths except pars loader refs
9 10
10 while (my ($filename, $zip) = each %PAR::LibCache) { 11 while (my ($filename, $zip) = each %PAR::LibCache) {
13 $zip->extractMember ($_, "$ENV{PAR_TEMP}/$1") 14 $zip->extractMember ($_, "$ENV{PAR_TEMP}/$1")
14 unless -e "$ENV{PAR_TEMP}/$1"; 15 unless -e "$ENV{PAR_TEMP}/$1";
15 } 16 }
16 } 17 }
17 18
19 # TODO: pango-rc file, anybody?
20
18 unshift @INC, $ENV{PAR_TEMP}; 21 unshift @INC, $ENV{PAR_TEMP};
19
20 if ($^O eq "MSWin32") {
21 $ENV{GTK_RC_FILES} = "$ENV{PAR_TEMP}/share/themes/MS-Windows/gtk-2.0/gtkrc";
22 }
23 } 22 }
24} 23}
25 24
26# need to do it again because that pile of garbage called PAR nukes it before main 25# need to do it again because that pile of garbage called PAR nukes it before main
27unshift @INC, $ENV{PAR_TEMP}; 26unshift @INC, $ENV{PAR_TEMP}
27 if %PAR::LibCache;
28 28
29use Time::HiRes 'time'; 29use Time::HiRes 'time';
30use Pod::POM;
30use Event; 31use Event;
31 32
32use Crossfire; 33use Crossfire;
33use Crossfire::Protocol; 34use Crossfire::Protocol;
34 35
100our $DEBUG_STATUS; 101our $DEBUG_STATUS;
101 102
102our $INVWIN; 103our $INVWIN;
103our $INV; 104our $INV;
104our $INVR; 105our $INVR;
106our $INVR_LBL;
105our $OPENCONT; 107our $OPENCONT;
106 108
107sub status { 109sub status {
108 $STATUSBOX->add ($_[0], pri => -10, group => "status", timeout => 20, fg => [1, 1, 0, 1]); 110 $STATUSBOX->add (CFClient::UI::Label::escape $_[0], pri => -10, group => "status", timeout => 20, fg => [1, 1, 0, 1]);
109} 111}
110 112
111sub debug { 113sub debug {
112 $DEBUG_STATUS->set_text ($_[0]); 114 $DEBUG_STATUS->set_text ($_[0]);
113 my ($w, $h) = $DEBUG_STATUS->size_request; 115 my ($w, $h) = $DEBUG_STATUS->size_request;
134 maph => $mapsize, 136 maph => $mapsize,
135 ; 137 ;
136 }; 138 };
137 139
138 if ($CONN) { 140 if ($CONN) {
141 CFClient::lowdelay fileno $CONN->{fh};
142
139 $LOGIN_BUTTON->set_text ("Logout"); 143 $LOGIN_BUTTON->set_text ("Logout");
140
141 status "login successful"; 144 status "login successful";
142 145
143 CFClient::lowdelay fileno $CONN->{fh}; 146 $BUTTONBAR->{children}[1]->emit ("activate")
147 if $BUTTONBAR->{children}[1]->{state};
148
144 } else { 149 } else {
145 status "unable to connect"; 150 status "unable to connect";
146 stop_game(); 151 stop_game();
147 } 152 }
148} 153}
152 157
153 status "connection closed"; 158 status "connection closed";
154 $LOGIN_BUTTON->set_text ("Login"); 159 $LOGIN_BUTTON->set_text ("Login");
155 $CONN->destroy; 160 $CONN->destroy;
156 $CONN = 0; # false, does not autovivify 161 $CONN = 0; # false, does not autovivify
162
163 $BUTTONBAR->{children}[1]->emit ("activate")
164 unless $BUTTONBAR->{children}[1]->{state};
157 165
158 undef $MAPCACHE; 166 undef $MAPCACHE;
159 undef $MAP; 167 undef $MAP;
160} 168}
161 169
665 $HOST->set_text ($CFG->{host} = $host); 673 $HOST->set_text ($CFG->{host} = $host);
666 }), 674 }),
667 (new CFClient::UI::Empty expand => 1), 675 (new CFClient::UI::Empty expand => 1),
668 ]); 676 ]);
669 677
670 $table->add ($_ + 1, $y, new CFClient::UI::Label align => $align[$_], text => $m->[$_], fontsize => 0.8) 678 $table->add ($_ + 1, $y, new CFClient::UI::Label
679 ellipsise => 0, align => $align[$_], text => $m->[$_], fontsize => 0.8)
671 for 0 .. $#$m; 680 for 0 .. $#$m;
672 } 681 }
673 } 682 }
674 }); 683 });
675} 684}
741 750
742 $CFG->{mapsize} = $self->{range}[0] = $value = int $value; 751 $CFG->{mapsize} = $self->{range}[0] = $value = int $value;
743 }, 752 },
744 ); 753 );
745 754
755 $table->add (0, 8, new CFClient::UI::Label valign => 0, align => 1, text => "Output-Count");
756 $table->add (1, 8, new CFClient::UI::Entry
757 text => $CFG->{output_count},
758 tooltip => "Should be set to 1 unless you know what you are doing",
759 connect_changed => sub { $CFG->{output_count} = $_[1] },
760 );
761
762 $table->add (0, 9, new CFClient::UI::Label valign => 0, align => 1, text => "Output-Sync");
763 $table->add (1, 9, new CFClient::UI::Entry
764 text => $CFG->{output_sync},
765 tooltip => "Should be set to 1 unless you know what you are doing",
766 connect_changed => sub { $CFG->{output_sync} = $_[1] },
767 );
768
746 $table->add (1, 8, $LOGIN_BUTTON = new CFClient::UI::Button 769 $table->add (1, 10, $LOGIN_BUTTON = new CFClient::UI::Button
747 expand => 1, 770 expand => 1,
748 align => 0, 771 align => 0,
749 text => "Login", 772 text => "Login",
750 connect_activate => sub { 773 connect_activate => sub {
751 $CONN ? stop_game 774 $CONN ? stop_game
763 bg => [0, 0, 0, 0.5], 786 bg => [0, 0, 0, 0.5],
764 user_w => int $::WIDTH / 3, 787 user_w => int $::WIDTH / 3,
765 user_h => int $::HEIGHT / 5, 788 user_h => int $::HEIGHT / 5,
766 child => (my $vbox = new CFClient::UI::VBox); 789 child => (my $vbox = new CFClient::UI::VBox);
767 790
768 $vbox->add ($LOGVIEW = new CFClient::UI::TextView 791 $vbox->add ($LOGVIEW);
769 expand => 1,
770 font => $FONT_FIXED,
771 fontsize => $::CFG->{log_fontsize},
772 );
773 792
774 $vbox->add (my $input = new CFClient::UI::Entry 793 $vbox->add (my $input = new CFClient::UI::Entry
775 connect_focus_in => sub { 794 connect_focus_in => sub {
776 my ($input, $prev_focus) = @_; 795 my ($input, $prev_focus) = @_;
777 796
812 831
813sub make_inventory_window { 832sub make_inventory_window {
814 my $invwin = new CFClient::UI::FancyFrame 833 my $invwin = new CFClient::UI::FancyFrame
815 user_w => $WIDTH * (4/5), user_h => $HEIGHT * (4/5), title => "Inventory"; 834 user_w => $WIDTH * (4/5), user_h => $HEIGHT * (4/5), title => "Inventory";
816 835
817 $invwin->add (my $hb = new CFClient::UI::HBox); 836 $invwin->add (my $hb = new CFClient::UI::HBox expand => 1);
837
838 $hb->add (my $vb1 = new CFClient::UI::VBox expand => 1);
839 $vb1->add (my $lbl = new CFClient::UI::Label);
840 $lbl->set_text ("Player");
818 $hb->add ($INV = new CFClient::UI::Inventory expand => 1); 841 $vb1->add ($INV = new CFClient::UI::Inventory expand => 1);
842
843 $hb->add (my $vb2 = new CFClient::UI::VBox expand => 1);
844 $vb2->add ($INVR_LBL = new CFClient::UI::Label);
845 $INVR_LBL->set_text ("Floor");
819 $hb->add ($INVR = new CFClient::UI::Inventory expand => 1); 846 $vb2->add ($INVR = new CFClient::UI::Inventory expand => 1);
820 847
821 $invwin 848 $invwin
822} 849}
823 850
824sub sdl_init { 851sub sdl_init {
834 ($WIDTH, $HEIGHT) = @{ $SDL_MODES[$CFG->{sdl_mode}] }; 861 ($WIDTH, $HEIGHT) = @{ $SDL_MODES[$CFG->{sdl_mode}] };
835 $FULLSCREEN = $CFG->{fullscreen}; 862 $FULLSCREEN = $CFG->{fullscreen};
836 $FAST = $CFG->{fast}; 863 $FAST = $CFG->{fast};
837 864
838 CFClient::SDL_SetVideoMode $WIDTH, $HEIGHT, $FULLSCREEN 865 CFClient::SDL_SetVideoMode $WIDTH, $HEIGHT, $FULLSCREEN
839 or die "SDL_SetVideoMode failed!\n"; 866 or die "SDL_SetVideoMode failed: " . (CFClient::SDL_GetError) . "\n";
840 867
841 $SDL_ACTIVE = 1; 868 $SDL_ACTIVE = 1;
842 $LAST_REFRESH = time - 0.01; 869 $LAST_REFRESH = time - 0.01;
843 870
844 CFClient::gl_init; 871 CFClient::gl_init;
884 } 911 }
885 }); 912 });
886 $MAPWIDGET->show; 913 $MAPWIDGET->show;
887 $MAPWIDGET->focus_in; 914 $MAPWIDGET->focus_in;
888 915
916 $LOGVIEW = new CFClient::UI::TextView
917 expand => 1,
918 font => $FONT_FIXED,
919 fontsize => $::CFG->{log_fontsize},
920 ;
921
889 $BUTTONBAR = new CFClient::UI::HBox; 922 $BUTTONBAR = new CFClient::UI::HBox;
890 923
891 $BUTTONBAR->add (new CFClient::UI::Flopper text => "Client Setup", other => client_setup); 924 $BUTTONBAR->add (new CFClient::UI::Flopper text => "Client Setup", other => client_setup);
892 $BUTTONBAR->add (new CFClient::UI::Flopper text => "Server Setup", other => server_setup); 925 $BUTTONBAR->add (new CFClient::UI::Flopper text => "Server Setup", other => server_setup);
893 $BUTTONBAR->add (new CFClient::UI::Flopper text => "Message Window", other => message_window); 926 $BUTTONBAR->add (new CFClient::UI::Flopper text => "Message Window", other => message_window);
924my $bgmusic;#TODO#hack#d# 957my $bgmusic;#TODO#hack#d#
925 958
926sub audio_channel_finished { 959sub audio_channel_finished {
927 my ($channel) = @_; 960 my ($channel) = @_;
928 961
929 warn "channel $channel finished\n";#d# 962 #warn "channel $channel finished\n";#d#
930} 963}
931 964
932sub audio_music_finished { 965sub audio_music_finished {
933 return unless $CFG->{bgm_enable}; 966 return unless $CFG->{bgm_enable};
934 967
1020 delete $animate_object{$widget}; 1053 delete $animate_object{$widget};
1021} 1054}
1022 1055
1023@conn::ISA = Crossfire::Protocol::; 1056@conn::ISA = Crossfire::Protocol::;
1024 1057
1058sub conn::new {
1059 my $class = shift;
1060
1061 my $self = $class->Crossfire::Protocol::new (@_);
1062
1063 $MAPWIDGET->clr_commands;
1064
1065 my $parser = new Pod::POM;
1066 my $pod = $parser->parse_file (CFClient::find_rcfile "pod/command_help.pod");
1067
1068 for my $head2 ($pod->head2) {
1069 $head2->title =~ /^(\S+) (?:\s+ \( ([^\)]*) \) )?/x
1070 or next;
1071
1072 my $cmd = $1;
1073 my @args = split /\|/, $2;
1074 @args = (".*") unless @args;
1075
1076 my $text = CFClient::pod_to_pango $head2->content;
1077
1078 for my $arg (@args) {
1079 $arg = $arg eq ".*" ? "" : " $arg";
1080
1081 $MAPWIDGET->add_command ("$cmd$arg", $text);
1082 }
1083 }
1084
1085 $self
1086}
1087
1025sub conn::stats_update { 1088sub conn::stats_update {
1026 my ($self, $stats) = @_; 1089 my ($self, $stats) = @_;
1090
1091 if (my $exp = $stats->{Crossfire::Protocol::CS_STAT_EXP64}) {
1092 my $diff = $exp - $self->{prev_exp};
1093 $STATUSBOX->add ("$diff experience gained", group => "experience $diff", fg => [0.5, 1, 0.5, 0.8], timeout => 5)
1094 if exists $self->{prev_exp} && $diff;
1095 $self->{prev_exp} = $exp;
1096 }
1027 1097
1028 update_stats_window ($stats); 1098 update_stats_window ($stats);
1029} 1099}
1030 1100
1031sub conn::user_send { 1101sub conn::user_send {
1356sub conn::spell_add { 1426sub conn::spell_add {
1357 my ($self, $spell) = @_; 1427 my ($self, $spell) = @_;
1358 1428
1359 # TODO 1429 # TODO
1360 # create a widget dynamically, using spell face (CF::Protocol downloads them) 1430 # create a widget dynamically, using spell face (CF::Protocol downloads them)
1361 $MAPWIDGET->add_command ("invoke $spell->{name}", $spell->{message}); 1431 $MAPWIDGET->add_command ("invoke $spell->{name}", CFClient::UI::Label::escape $spell->{message});
1362 $MAPWIDGET->add_command ("cast $spell->{name}", $spell->{message}); 1432 $MAPWIDGET->add_command ("cast $spell->{name}", CFClient::UI::Label::escape $spell->{message});
1363} 1433}
1364 1434
1365sub conn::spell_delete { 1435sub conn::spell_delete {
1366 my ($self, $spell) = @_; 1436 my ($self, $spell) = @_;
1367} 1437}
1368 1438
1369sub conn::addme_success { 1439sub conn::addme_success {
1370 my ($self) = @_; 1440 my ($self) = @_;
1371 1441
1372 $MAPWIDGET->clr_commands; 1442 $self->send ("command output-sync $CFG->{output_sync}");
1443 $self->send ("command output-count $CFG->{output_count}");
1373 1444
1374 for my $skill (values %{$self->{skill_info}}) { 1445 for my $skill (values %{$self->{skill_info}}) {
1375 $MAPWIDGET->add_command ("ready_skill $skill", "Ready the skill '$skill'"); 1446 $MAPWIDGET->add_command ("ready_skill $skill", CFClient::UI::Label::escape "Ready the skill '$skill'");
1376 $MAPWIDGET->add_command ("use_skill $skill", "Immediately use the skill '$skill'"); 1447 $MAPWIDGET->add_command ("use_skill $skill", CFClient::UI::Label::escape "Immediately use the skill '$skill'");
1377 } 1448 }
1378
1379 $MAPWIDGET->add_command ("petmode defend", "Tell pets to stay close to you and defend you");
1380 $MAPWIDGET->add_command ("petmode arena", "Same as petmode sad, but also attack other players");
1381 $MAPWIDGET->add_command ("petmode sad", "Search & Destroy - tell pets to roam about and attack enemies");
1382 $MAPWIDGET->add_command ("killpets", "Kill your pets");
1383 $MAPWIDGET->add_command ("chat", "chat TEXT\nChat with all other players");
1384 $MAPWIDGET->add_command ("shout", "shout TEXT\nShout loudly, used for emergencies");
1385 $MAPWIDGET->add_command ("tell", "tell USERNAME TEXT\nPrivately tell a specific player");
1386
1387 # TODO: add documentation on these
1388 for (qw(
1389 afk
1390 apply
1391 body
1392 bowmode
1393 brace
1394 build
1395 disarm
1396 dm
1397 dmhide
1398 drop
1399 dropall
1400 examine
1401 get
1402 gsay
1403 help
1404 hiscore
1405 inventory
1406 invoke
1407 killpets
1408 listen
1409 logs
1410 mapinfo
1411 maps
1412 mark
1413 motd
1414 output-count
1415 output-sync
1416 party
1417 peaceful
1418 petmode
1419 pickup
1420 players
1421 prepare
1422 quests
1423 rename
1424 resistances
1425 rotateshoottype
1426 save
1427 say
1428 search
1429 search-items
1430 showpets
1431 skills
1432 sound
1433 take
1434 throw
1435 time
1436 title
1437 usekeys
1438 version
1439 weather
1440 whereabouts
1441 whereami
1442 who
1443 wimpy
1444 )) {
1445 $MAPWIDGET->add_command ($_, "$_: no help available (yet)");
1446 }
1447
1448 #TODO: add " and ' "aliases" etc.
1449} 1449}
1450 1450
1451sub conn::eof { 1451sub conn::eof {
1452 $MAPWIDGET->clr_commands; 1452 $MAPWIDGET->clr_commands;
1453 1453
1481 #d# print "container_add: container $tag ($self->{player}{tag})\n"; 1481 #d# print "container_add: container $tag ($self->{player}{tag})\n";
1482 1482
1483 if ($tag == 0) { 1483 if ($tag == 0) {
1484 update_floorbox; 1484 update_floorbox;
1485 $OPENCONT = 0; 1485 $OPENCONT = 0;
1486 $INVR_LBL->set_text ("Floor");
1486 $INVR->set_items ($self->{container}{0}); 1487 $INVR->set_items ($self->{container}{0});
1487 } elsif ($tag == $self->{player}{tag}) { 1488 } elsif ($tag == $self->{player}{tag}) {
1489 $INVR_LBL->set_text ("Player");
1488 $INV->set_items ($self->{container}{$self->{player}{tag}}) 1490 $INV->set_items ($self->{container}{$self->{player}{tag}})
1489 } else { 1491 } else {
1490 $OPENCONT = $tag; 1492 $OPENCONT = $tag;
1493 $INVR_LBL->set_text (CFClient::UI::InventoryItem::_item_to_desc ($self->{item}->{$OPENCONT}));
1491 $INVR->set_items ($self->{container}{$tag}); 1494 $INVR->set_items ($self->{container}{$tag});
1492 } 1495 }
1493 1496
1494 # $self-<{player}{tag} => player inv 1497 # $self-<{player}{tag} => player inv
1495 #use PApp::Util; warn PApp::Util::dumpval $self->{container}{$self->{player}{tag}}; 1498 #use PApp::Util; warn PApp::Util::dumpval $self->{container}{$self->{player}{tag}};
1501 #d# print "container_clear: container $tag ($self->{player}{tag})\n"; 1504 #d# print "container_clear: container $tag ($self->{player}{tag})\n";
1502 1505
1503 if ($tag == 0) { 1506 if ($tag == 0) {
1504 update_floorbox; 1507 update_floorbox;
1505 $OPENCONT = 0; 1508 $OPENCONT = 0;
1509 $INVR_LBL->set_text ("Floor");
1506 $INVR->set_items ($self->{container}{0}); 1510 $INVR->set_items ($self->{container}{0});
1507 } elsif ($tag == $self->{player}{tag}) { 1511 } elsif ($tag == $self->{player}{tag}) {
1512 $INVR_LBL->set_text ("Player");
1508 $INV->set_items ($self->{container}{$tag}) 1513 $INV->set_items ($self->{container}{$tag})
1509 } else { 1514 } else {
1510 $OPENCONT = $tag; 1515 $OPENCONT = $tag;
1516 $INVR_LBL->set_text (CFClient::UI::InventoryItem::_item_to_desc ($self->{item}->{$OPENCONT}));
1511 $INVR->set_items ($self->{container}{$tag}); 1517 $INVR->set_items ($self->{container}{$tag});
1512 } 1518 }
1513 1519
1514# use PApp::Util; warn PApp::Util::dumpval $self->{container}{0}; 1520# use PApp::Util; warn PApp::Util::dumpval $self->{container}{0};
1515} 1521}
1521 #d# print "item_delete: $_->{tag} from $_->{container} ($self->{player}{tag})\n"; 1527 #d# print "item_delete: $_->{tag} from $_->{container} ($self->{player}{tag})\n";
1522 1528
1523 if ($_->{container} == 0) { 1529 if ($_->{container} == 0) {
1524 update_floorbox; 1530 update_floorbox;
1525 $OPENCONT = 0; 1531 $OPENCONT = 0;
1532 $INVR_LBL->set_text ("Floor");
1526 $INVR->set_items ($self->{container}{0}); 1533 $INVR->set_items ($self->{container}{0});
1527 } elsif ($_->{container} == $self->{player}{tag}) { 1534 } elsif ($_->{container} == $self->{player}{tag}) {
1535 $INVR_LBL->set_text ("Player");
1528 $INV->set_items ($self->{container}{$self->{player}{tag}}) 1536 $INV->set_items ($self->{container}{$self->{player}{tag}})
1529 } else { 1537 } else {
1530 $OPENCONT = $_->{container}; 1538 $OPENCONT = $_->{container};
1539 $INVR_LBL->set_text (CFClient::UI::InventoryItem::_item_to_desc ($self->{item}->{$OPENCONT}));
1531 $INVR->set_items ($self->{container}{$_->{container}}); 1540 $INVR->set_items ($self->{container}{$_->{container}});
1532 } 1541 }
1533 } 1542 }
1534} 1543}
1535 1544
1538 1547
1539 #d# print "item_update: $item->{tag} in $item->{container} ($self->{player}{tag}) ($OPENCONT)\n"; 1548 #d# print "item_update: $item->{tag} in $item->{container} ($self->{player}{tag}) ($OPENCONT)\n";
1540 1549
1541 if ($item->{tag} == $OPENCONT && not ($item->{flags} & Crossfire::Protocol::F_OPEN)) { 1550 if ($item->{tag} == $OPENCONT && not ($item->{flags} & Crossfire::Protocol::F_OPEN)) {
1542 $OPENCONT = 0; 1551 $OPENCONT = 0;
1552 $INVR_LBL->set_text ("Floor");
1543 $INVR->set_items ($self->{container}{0}); 1553 $INVR->set_items ($self->{container}{0});
1554
1555 $item->{widget}->update_item
1556 if $item->{widget};
1544 } else { 1557 } else {
1545 if ($item->{container} == 0) { 1558 if ($item->{container} == 0) {
1546 update_floorbox; 1559 update_floorbox;
1547 $OPENCONT = 0; 1560 $OPENCONT = 0;
1561 $INVR_LBL->set_text ("Floor");
1548 $INVR->set_items ($self->{container}{0}); 1562 $INVR->set_items ($self->{container}{0});
1549 } elsif ($item->{container} == $self->{player}{tag}) { 1563 } elsif ($item->{container} == $self->{player}{tag}) {
1550 $INV->set_items ($self->{container}{$item->{container}}) 1564 $INV->set_items ($self->{container}{$item->{container}})
1551 } 1565 }
1552 } 1566 }
1603 sdl_mode => 0, 1617 sdl_mode => 0,
1604 width => 640, 1618 width => 640,
1605 height => 480, 1619 height => 480,
1606 fullscreen => 0, 1620 fullscreen => 0,
1607 fast => 0, 1621 fast => 0,
1608 map_scale => 0.5, 1622 map_scale => 1,
1609 fow_enable => 1, 1623 fow_enable => 1,
1610 fow_intensity => 0.45, 1624 fow_intensity => 0.45,
1611 fow_smooth => 0, 1625 fow_smooth => 0,
1612 gui_fontsize => 1, 1626 gui_fontsize => 1,
1613 log_fontsize => 1, 1627 log_fontsize => 1,
1618 host => "crossfire.schmorp.de", 1632 host => "crossfire.schmorp.de",
1619 say_command => 'say', 1633 say_command => 'say',
1620 audio_enable => 1, 1634 audio_enable => 1,
1621 bgm_enable => 1, 1635 bgm_enable => 1,
1622 bgm_volume => 0.25, 1636 bgm_volume => 0.25,
1637 output_sync => 1,
1638 output_count => 1,
1623 ); 1639 );
1624 1640
1625 while (my ($k, $v) = each %DEF_CFG) { 1641 while (my ($k, $v) = each %DEF_CFG) {
1626 $CFG->{$k} = $v unless exists $CFG->{$k}; 1642 $CFG->{$k} = $v unless exists $CFG->{$k};
1627 } 1643 }
1732 1748
1733Typing B<climb> will display a list of commands with I<climb> in their 1749Typing B<climb> will display a list of commands with I<climb> in their
1734name, such as I<ready_skill climbing> and I<use_skill climbing>. 1750name, such as I<ready_skill climbing> and I<use_skill climbing>.
1735 1751
1736You can abbreviate commands by typing only the first character of every 1752You can abbreviate commands by typing only the first character of every
1737word. For example, typing I<iwor> will likely select I<invoke word of 1753word (or even characters within the word - the client will try to make
1738recall>, while I<ccfo> will select I<cast create food>. Likewise, I<rscli> 1754a good guess, as long as the characters are in order). For example,
1739will likely select I<ready_skill climbing> and I<usl> will give you 1755typing I<iwor> will likely select I<invoke word of recall>, while I<ccfo>
1740I<use_skill levitation>. 1756will select I<cast create food>. Likewise, I<rscli> will likely select
1757I<ready_skill climbing> and I<usl> will give you I<use_skill levitation>.
1758
1759You can enter space and other text as arguemnt to the command. For
1760example, C<cfoo waybread> will expand to C<cast create food waybread>.
1741 1761
1742=head2 The map overview 1762=head2 The map overview
1743 1763
1744#TODO# 1764#TODO#
1745 1765

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines