diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2006-12-03 17:00:07 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2006-12-03 17:00:07 +0000 |
commit | 061b9e817ffe73acca163510b276e6ca7dd8f6c2 (patch) | |
tree | c1488381a9a62520f94cdb353bd5bd12ebc1b699 /src/net/playerhandler.cpp | |
parent | 092bf185fc056338bcde2749a304e576edf342fd (diff) | |
download | mana-061b9e817ffe73acca163510b276e6ca7dd8f6c2.tar.gz mana-061b9e817ffe73acca163510b276e6ca7dd8f6c2.tar.bz2 mana-061b9e817ffe73acca163510b276e6ca7dd8f6c2.tar.xz mana-061b9e817ffe73acca163510b276e6ca7dd8f6c2.zip |
Made NPC names visible. Windows are now invisible by default.
Diffstat (limited to 'src/net/playerhandler.cpp')
-rw-r--r-- | src/net/playerhandler.cpp | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/src/net/playerhandler.cpp b/src/net/playerhandler.cpp index 3786cd0b..e83bcce8 100644 --- a/src/net/playerhandler.cpp +++ b/src/net/playerhandler.cpp @@ -46,7 +46,10 @@ OkDialog *deathNotice = NULL; namespace { struct WeightListener : public gcn::ActionListener { - void action(const std::string& eventId, gcn::Widget* widget) { weightNotice = NULL; } + void action(const std::string &eventId, gcn::Widget *widget) + { + weightNotice = NULL; + } } weightListener; } @@ -55,8 +58,10 @@ namespace { */ // TODO Move somewhere else namespace { - struct DeathListener : public gcn::ActionListener { - void action(const std::string& eventId, gcn::Widget* widget) { + struct DeathListener : public gcn::ActionListener + { + void action(const std::string &eventId, gcn::Widget *widget) + { player_node->revive(); deathNotice = NULL; } @@ -137,10 +142,11 @@ void PlayerHandler::handleMessage(MessageIn *msg) player_node->mMaxWeight / 2) { weightNotice = new OkDialog("Message", - "You are carrying more then half your " - "weight. You are unable to regain " - "health."); - weightNotice->addActionListener(&weightListener); + "You are carrying more then half " + "your weight. You are unable to " + "regain health."); + weightNotice->addActionListener( + &weightListener); } player_node->mTotalWeight = value; break; |