diff options
author | Eugenio Favalli <elvenprogrammer@gmail.com> | 2005-07-03 10:40:06 +0000 |
---|---|---|
committer | Eugenio Favalli <elvenprogrammer@gmail.com> | 2005-07-03 10:40:06 +0000 |
commit | 4f40a1bcbdc27affb96737f5f5dc0c086d1031ce (patch) | |
tree | aa693beedd08e925b5e5ef9364bfcaed3e945edc /src | |
parent | 79d63d624b44faa4085bd82eaa3519df77bbb58b (diff) | |
download | mana-4f40a1bcbdc27affb96737f5f5dc0c086d1031ce.tar.gz mana-4f40a1bcbdc27affb96737f5f5dc0c086d1031ce.tar.bz2 mana-4f40a1bcbdc27affb96737f5f5dc0c086d1031ce.tar.xz mana-4f40a1bcbdc27affb96737f5f5dc0c086d1031ce.zip |
- Commenting out buddy and new skills windows
- Some code cleaning
- Workaround for colored text not being displayed in SDL mode (disabled)
Diffstat (limited to 'src')
-rw-r--r-- | src/being.cpp | 4 | ||||
-rw-r--r-- | src/engine.cpp | 22 | ||||
-rw-r--r-- | src/engine.h | 14 | ||||
-rw-r--r-- | src/game.cpp | 6 | ||||
-rw-r--r-- | src/gui/gui.cpp | 6 | ||||
-rw-r--r-- | src/gui/popupmenu.cpp | 7 |
6 files changed, 28 insertions, 31 deletions
diff --git a/src/being.cpp b/src/being.cpp index 770a5c5a..cd0a31c9 100644 --- a/src/being.cpp +++ b/src/being.cpp @@ -346,6 +346,7 @@ void Being::drawSpeech(Graphics *graphics) gcn::Graphics::CENTER); } if (showDamage) { +#ifdef USE_OPENGL // Selecting the right color if (damage == "miss") { @@ -359,6 +360,7 @@ void Being::drawSpeech(Graphics *graphics) { graphics->setFont(hitRedFont); } +#endif int textX = 0; int textY = 0; @@ -370,7 +372,7 @@ void Being::drawSpeech(Graphics *graphics) textX = 60; textY = 0; } - + graphics->drawText(damage, text_x + textX, text_y - textY - get_elapsed_time(damage_time) / 100, diff --git a/src/engine.cpp b/src/engine.cpp index 14c70541..0c2a0527 100644 --- a/src/engine.cpp +++ b/src/engine.cpp @@ -29,7 +29,7 @@ #include "gui/chargedialog.h" #include "gui/itemcontainer.h" #include "gui/trade.h" -#include "gui/buddywindow.h" +//#include "gui/buddywindow.h" #include "gui/help.h" #include "main.h" #include "being.h" @@ -55,14 +55,14 @@ InventoryWindow *inventoryWindow; NpcListDialog *npcListDialog; NpcTextDialog *npcTextDialog; SkillDialog *skillDialog; -NewSkillDialog *newSkillWindow; +//NewSkillDialog *newSkillWindow; StatsWindow *statsWindow; Setup* setupWindow; Minimap *minimap; EquipmentWindow *equipmentWindow; ChargeDialog *chargeDialog; TradeWindow *tradeWindow; -BuddyWindow *buddyWindow; +//BuddyWindow *buddyWindow; HelpWindow *helpWindow; PopupMenu *popupMenu; std::map<int, Spriteset*> monsterset; @@ -156,14 +156,14 @@ Engine::Engine(): npcTextDialog = new NpcTextDialog(); npcListDialog = new NpcListDialog(); skillDialog = new SkillDialog(); - newSkillWindow = new NewSkillDialog(); + //newSkillWindow = new NewSkillDialog(); statsWindow = new StatsWindow(); setupWindow = new Setup(); minimap = new Minimap(); equipmentWindow = new EquipmentWindow(); chargeDialog = new ChargeDialog(); tradeWindow = new TradeWindow(); - buddyWindow = new BuddyWindow(); + //buddyWindow = new BuddyWindow(); helpWindow = new HelpWindow(); popupMenu = new PopupMenu(); @@ -181,8 +181,8 @@ Engine::Engine(): tradeWindow->setPosition(screen->w - statusWindow->getWidth() - tradeWindow->getWidth() - 10, inventoryWindow->getY() + inventoryWindow->getHeight()); - buddyWindow->setPosition(10, - minimap->getHeight() + 30); + /*buddyWindow->setPosition(10, + minimap->getHeight() + 30);*/ equipmentWindow->setPosition(5,140); // Set initial window visibility @@ -195,13 +195,13 @@ Engine::Engine(): npcTextDialog->setVisible(false); npcListDialog->setVisible(false); skillDialog->setVisible(false); - newSkillWindow->setVisible(false); + //newSkillWindow->setVisible(false); statsWindow->setVisible(false); setupWindow->setVisible(false); equipmentWindow->setVisible(false); chargeDialog->setVisible(false); tradeWindow->setVisible(false); - buddyWindow->setVisible(false); + //buddyWindow->setVisible(false); helpWindow->setVisible(false); popupMenu->setVisible(false); @@ -247,9 +247,9 @@ Engine::~Engine() delete minimap; delete equipmentWindow; delete chargeDialog; - delete newSkillWindow; + //delete newSkillWindow; delete tradeWindow; - delete buddyWindow; + //delete buddyWindow; delete helpWindow; delete popupMenu; diff --git a/src/engine.h b/src/engine.h index 1a4c3b70..03a9cf2e 100644 --- a/src/engine.h +++ b/src/engine.h @@ -29,7 +29,7 @@ #include "gui/buy.h" #include "gui/sell.h" #include "gui/buysell.h" -#include "gui/buddywindow.h" +//#include "gui/buddywindow.h" #include "gui/chat.h" #include "gui/inventory.h" #include "gui/shop.h" @@ -48,14 +48,6 @@ #include "map.h" #include "graphic/spriteset.h" -extern char speech[255]; -extern char npc_text[1000]; -extern char skill_points[10]; -extern bool show_skill_dialog, show_skill_list_dialog; -extern int show_npc_dialog; -extern int map_x, map_y, camera_x, camera_y; -extern char npc_button[10]; - extern ChatWindow *chatWindow; extern StatusWindow *statusWindow; extern BuyDialog *buyDialog; @@ -65,13 +57,13 @@ extern InventoryWindow *inventoryWindow; extern NpcListDialog *npcListDialog; extern NpcTextDialog *npcTextDialog; extern SkillDialog *skillDialog; -extern NewSkillDialog *newSkillWindow; +//extern NewSkillDialog *newSkillWindow; extern StatsWindow *statsWindow; extern Setup *setupWindow; extern EquipmentWindow *equipmentWindow; extern ChargeDialog* chargeDialog; extern TradeWindow *tradeWindow; -extern BuddyWindow *buddyWindow; +//extern BuddyWindow *buddyWindow; extern HelpWindow *helpWindow; extern PopupMenu *popupMenu; extern std::map<int, Spriteset*> monsterset; diff --git a/src/game.cpp b/src/game.cpp index a6a9d866..27583d92 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -303,12 +303,13 @@ void do_input() statsWindow->setVisible(!statsWindow->isVisible()); used = true; } + /* // New skills window else if (keysym.sym == SDLK_n) { newSkillWindow->setVisible(!newSkillWindow->isVisible()); used = true; - } + }*/ // Skill window else if (keysym.sym == SDLK_k) { @@ -327,12 +328,13 @@ void do_input() equipmentWindow->setVisible(!equipmentWindow->isVisible()); used = true; } + /* // Buddy window else if (keysym.sym == SDLK_b) { buddyWindow->setVisible(!buddyWindow->isVisible()); used = true; - } + }*/ // Emotions else if (action_time && (player_node->emotion == 0)) diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index 35b3c843..ec9a6adc 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -91,8 +91,10 @@ Gui::Gui(Graphics *graphics) { logger->error("Unable to load fixedfont.png!"); } + + gcn::Widget::setGlobalFont(guiFont); - // Set hits' colourful fonts + // Load hits' colourful fonts try { hitRedFont = new gcn::ImageFont( TMW_DATADIR "data/graphics/gui/hits_red.png", @@ -108,8 +110,6 @@ Gui::Gui(Graphics *graphics) { logger->error("Unable to load colored hits' fonts!"); } - - gcn::Widget::setGlobalFont(guiFont); } Gui::~Gui() diff --git a/src/gui/popupmenu.cpp b/src/gui/popupmenu.cpp index 76b8e4e2..f58312db 100644 --- a/src/gui/popupmenu.cpp +++ b/src/gui/popupmenu.cpp @@ -91,7 +91,7 @@ void PopupMenu::showPopup(int mx, int my) //browserBox->addRow("@@attack|Attack " + name + "@@"); browserBox->addRow("@@trade|Trade With " + name + "@@"); browserBox->addRow("@@follow|Follow " + name + "@@"); - browserBox->addRow("@@buddy|Add " + name + " to Buddy List@@"); + //browserBox->addRow("@@buddy|Add " + name + " to Buddy List@@"); } } else if (floorItem) @@ -172,7 +172,8 @@ void PopupMenu::handleLink(const std::string& link) else if (link == "follow") { } - + + /* // Add Buddy action else if ((link == "buddy") && being && being->isPlayer()) { @@ -180,7 +181,7 @@ void PopupMenu::handleLink(const std::string& link) buddyWindow->setVisible(true); buddyWindow->addBuddy(being->name); - } + }*/ // Pick Up Floor Item action else if ((link == "pickup") && floorItem) |