TAEB / TAEB-AI-Behavioral

behavioral AI for TAEB
http://taeb.github.io
5 stars 4 forks source link

Altar checking in FixHunger doesn't work when altar is obscured #77

Open seankelly opened 10 years ago

seankelly commented 10 years ago
<T9318> 2013-12-24 12:13:02 [WARNING:undef] Use of uninitialized value in string eq at ../cpan/TAEB-AI-Behavioral/lib/TAEB/AI/Behavioral/Behavior/FixHunger.pm line 11.
 at /home/sean/.perlbrew/libs/perl-5.16.3@beat/lib/perl5/Log/Dispatch/Base.pm line 30.
        Log::Dispatch::Base::_apply_callbacks('Log::Dispatch=HASH(0x80d9b4528)', 'level', 'warning', 'message', 'Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...') called at /home/sean/.perlbrew/libs/perl-5.16.3@beat/lib/perl5/Log/Dispatch.pm line 155
        Log::Dispatch::_prepare_message('Log::Dispatch=HASH(0x80d9b4528)', 'level', 'warning', 'message', 'Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...') called at /home/sean/.perlbrew/libs/perl-5.16.3@beat/lib/perl5/Log/Dispatch.pm line 145
        Log::Dispatch::log('Log::Dispatch=HASH(0x80d9b4528)', 'level', 'warning', 'message', 'Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...') called at /home/sean/.perlbrew/libs/perl-5.16.3@beat/lib/perl5/Log/Dispatch/Channels.pm line 59
        Log::Dispatch::Channels::_forward_to_channels('TAEB::Logger=HASH(0x80a8606d8)', 'undef', 'log', 'level', 'warning', 'message', 'Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...') called at /home/sean/.perlbrew/libs/perl-5.16.3@beat/lib/perl5/Log/Dispatch/Channels.pm line 98
        Log::Dispatch::Channels::log('TAEB::Logger=HASH(0x80a8606d8)', 'channels', 'undef', 'level', 'debug', 'message', 'Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...', 'level', 'warning', ...) called at lib/TAEB/Logger.pm line 140
        TAEB::Logger::log_to_channel('TAEB::Logger=HASH(0x80a8606d8)', 'undef', 'Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...', 'level', 'warning') called at lib/TAEB/Logger.pm line 153
        TAEB::Logger::AUTOLOAD('TAEB::Logger=HASH(0x80a8606d8)', 'Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...', 'level', 'warning') called at lib/TAEB.pm line 696
        TAEB::__ANON__('Use of uninitialized value in string eq at ../cpan/TAEB-AI-Be...') called at ../cpan/TAEB-AI-Behavioral/lib/TAEB/AI/Behavioral/Behavior/FixHunger.pm line 11
        TAEB::AI::Behavioral::Behavior::FixHunger::prepare('TAEB::AI::Behavioral::Behavior::FixHunger=HASH(0x80cabaa38)') called at ../cpan/TAEB-AI-Behavioral/lib/TAEB/AI/Behavioral/Personality.pm line 208
        TAEB::AI::Behavioral::Personality::find_urgency('TAEB::AI::Behavioral::Personality::Explorer=HASH(0x80ab92f18)', 'FixHunger', 0) called at ../cpan/TAEB-AI-Behavioral/lib/TAEB/AI/Behavioral/Personality.pm line 244
        TAEB::AI::Behavioral::Personality::next_behavior('TAEB::AI::Behavioral::Personality::Explorer=HASH(0x80ab92f18)') called at ../cpan/TAEB-AI-Behavioral/lib/TAEB/AI/Behavioral/Personality.pm line 268
        TAEB::AI::Behavioral::Personality::next_action('TAEB::AI::Behavioral::Personality::Explorer=HASH(0x80ab92f18)') called at lib/TAEB/AI/Role/Action/Backoff.pm line 118

Not sure what was happening at the time.

seankelly commented 10 years ago

Game was restarted with the state cleared. BEAT was on the altar and got this message when checking the tile.

There is an altar to Tyr (lawful) here.

Things that are here:
a fire giant corpse
a mace
a scroll labeled VE FORBRYDERNE
a robe
a small shield
a glittering spellbook
a pink spellbook
a cursed dagger
2 cursed darts
--More--
doy commented 10 years ago

We only get the alignment from altars by farlooking them when they come into view, we don't parse the floor message. This should be fixed - it also comes up on bones levels where the previous player left items on the altar.