… | |
… | |
445 | sub spell_add { |
445 | sub spell_add { |
446 | my ($self, $spell) = @_; |
446 | my ($self, $spell) = @_; |
447 | |
447 | |
448 | # TODO |
448 | # TODO |
449 | # create a widget dynamically, using spell face (CF::Protocol downloads them) |
449 | # create a widget dynamically, using spell face (CF::Protocol downloads them) |
450 | $::SPELL_LIST->add_spell ($spell); |
450 | $::SETUP_SPELLS->add_spell ($spell); |
451 | |
451 | |
452 | $self->{map_widget}->add_command ("invoke $spell->{name}", CFClient::UI::Label::escape $spell->{message}); |
452 | $self->{map_widget}->add_command ("invoke $spell->{name}", CFClient::UI::Label::escape $spell->{message}); |
453 | $self->{map_widget}->add_command ("cast $spell->{name}", CFClient::UI::Label::escape $spell->{message}); |
453 | $self->{map_widget}->add_command ("cast $spell->{name}", CFClient::UI::Label::escape $spell->{message}); |
454 | } |
454 | } |
455 | |
455 | |