summaryrefslogtreecommitdiff
path: root/src/gui/npcdialog.cpp
AgeCommit message (Collapse)AuthorFilesLines
2024-08-04Removed a bunch of unused NPC related eventssome-cleanupsThorbjørn Lindeijer1-26/+7
Nobody cared for the events that were emitted when NPC related network messages had been sent.
2024-06-23Added support for text formatting and links to NPC dialogThorbjørn Lindeijer1-24/+19
Use BrowserBox in NpcDialog to enable the use of text formatting and links in NPC texts. This change is roughly based on ManaPlus commit 94f11a223e03c6845e7ce6e9fe67c0e9fa7061f4.
2024-04-08Compile fixes for MSYS2 UCRT64Thorbjørn Lindeijer1-1/+1
Also added instructions for installing the dependencies on MSYS2. The selection of the default language is commented out for now. It will be fixed in another change.
2024-03-12General code cleanupsThorbjørn Lindeijer1-3/+1
* Use default member initializers * Use range-based for loops * Avoid needless pointer references for ShopItem::mDuplicates * Removed type aliases that are only used once or twice * Removed more unused includes * Removed some unused functions * Removed superfluous .c_str() * Rely on default copy and assignment operators for Vector class * Use std::unique_ptr in some places * Removed duplicated mPlayerMoney updating in SellDialog * Removed duplicated Game::handleInput call * Removed unused SDLInput::mMouseInWindow * Removed remnant of manual widget positioning in HelpWindow * Removed superfluous initialization of static pointers
2024-03-04Added support for handling SMSG_NPC_COMMANDThorbjørn Lindeijer1-0/+10
This only adds support for the NPC_CLOSE_DIALOG and NPC_CLEAR_DIALOG sub-commands. Closes #47
2024-02-22General code cleanupsThorbjørn Lindeijer1-4/+4
* Use default member initializers * Use range-based loops * Don't use 'else' after 'return' * Removed some unused includes * Construct empty strings with std::string() instead of "" * Clear strings with .clear() instead of assigning "" * Check whether strings are empty with .empty() instead of comparing to "" * Removed redundant initializations
2024-02-09C++11: Use default member initializersThorbjørn Lindeijer1-4/+1
This patch is not exhaustive.
2024-01-26Apply C++11 fixitsThorbjørn Lindeijer1-13/+13
modernize-use-auto modernize-use-nullptr modernize-use-override modernize-use-using
2012-01-30Keep a single blank line between NPC textsThorbjørn Lindeijer1-0/+1
Makes it easier to see what was added during a conversation. Reviewed-by: Yohann Ferreira
2012-01-26Remove "> Next" from NPC dialogsAndrei Karas1-2/+0
Reviewed-by: Thorbjørn Lindeijer
2012-01-26Updated copyrights to 2012Thorbjørn Lindeijer1-1/+1
2012-01-09Added a close button to the npc dialog window.Yohann Ferreira1-22/+26
The close button will only display when the window is waiting for the server, so that crashed windows can be closed without restarting the client. Pushing the QUIT key (Escape by default) will also close the crashed windows in that case. I also fixed a memleak with the "next" button. Resolves: Mana-Mantis #72, 93, 389. Reviewed-by: Ablu.
2012-01-07Made the first choice item be selected at the beginningBen Longbons1-0/+6
Resolves Mana-Mantis: #432. Reviewed-by: Bertram, Ablu.
2011-05-26Fix compilation on gcc 4.6.1.Yohann Ferreira1-1/+1
2011-05-25Added more double clickable actionsAngelo Castellani1-0/+15
- double clicking a do_choice item submits it - double clicking the npc chat will hit 'next' - double click to buy/sell a single item - clicking on no item in the inventory now deselects - double click to use/activate items in inventory
2011-04-09Renamed Listener to EventListenerThorbjørn Lindeijer1-2/+2
Makes it clear what kind of listener it is, since there are other listener classes as well. Acked-by: Jared Adams
2011-04-09Removed the Mana namespaceThorbjørn Lindeijer1-20/+20
It's just an annoyance when it's only applied to a few classes. Either we place everything in this namespace or nothing, and at the moment I don't see any rationale for placing everything in a Mana namespace. Acked-by: Jared Adams
2011-04-09Moved Channels to Mana::Event::ChannelThorbjørn Lindeijer1-7/+7
Acked-by: Jared Adams
2011-04-09Moved Events to Mana::Event::TypeThorbjørn Lindeijer1-10/+10
Acked-by: Jared Adams
2010-12-15Merge branch '0.5'Thorbjørn Lindeijer1-0/+5
2010-11-29Allow enter OK button key in input field.Andrei Karas1-0/+5
By default OK shortcut is space key. Reviewed-by: Jaxad0127, Kage
2010-11-13Replace config listeners with the event systemChuck Miller1-4/+7
Reviewed-by: Jared Adams
2010-11-12Change NPC handling in the net codeChuck Miller1-20/+10
Instead of using events to invoke netcode, invoke netcode directly and have it send events Reviewed-by: Freeyorp
2010-11-11Replace Event names with enums instead of stringsChuck Miller1-16/+16
2010-11-11Have the event system channels use enums instead of stringsChuck Miller1-11/+11
Reviewed-by: Freeyorp
2010-08-12Simplify working with the event systemJared Adams1-12/+12
EventManager has been merged into Event, with some new convinience methods added. Reviewed-by: Chuck Miller
2010-08-12Replace most of Net::NpcHandler with eventsJared Adams1-14/+26
Reviewed-by: Chuck Miller
2010-08-10Remove NpcDialog references from netcodeJared Adams1-9/+150
Reviewed-by: Chuck Miller
2010-08-01Remove isActive methods from NPC dialogs and InventoryWindowJared Adams1-0/+5
Uses counts in PlayerInfo instead. Reviewed-by: Chuck Miller
2010-07-28Centralized configuration default values using the VariableData system.Yohann Ferreira1-2/+2
Please note that I didn't turned all the getValue() call into new ones, simply because I have to have config object initiated which is not forcefully the case the branding file. Resolves: Manasource Mantis #170.
2010-05-17Remove Monster, Player, and NPC classesJared Adams1-1/+0
Instead of having these three subclasses with minor differences, this commit merges them back into Being. In the future, we can make Beings that are talkable to some, attackable by others, etc. This also puts back support for monster equipment. Also changes remaining references to Being::Type and the constants to refer to ActorSprite::Type. Reviewed-by: Freeyorp
2010-04-21Add a clear button to the NPC dialogJared Adams1-14/+50
Reviewed-by: Bertram
2010-03-25Simplify NPC input when only one dialog is openJared Adams1-0/+3
Reviewed-by: Freeyorp
2010-02-22Modify copyright headersFreeyorp1-1/+2
2010-02-20License header update for The Mana ClientThorbjørn Lindeijer1-4/+3
2010-02-13Make NPC dialogs instance instead of globalJared Adams1-7/+67
This change allows players to talk to multiple NPCs at a time (if the server agrees). Manaserv's netcode allows multiple commerce instances too. eAthena's is limited to one commerce instance, due to protocol limitations.
2010-02-07Updated Copyright year to 2010!Bertram1-1/+1
Also added the update copyright tool from the Wormux Team. ( And not forgetting credit's due. :P )
2010-01-11Cleanup GUI classesJared Adams1-3/+4
Moved remaining widgets into widgets folder, standardized include order, moved TextRenderer out.
2010-01-10Fix handling of NPC talking statusJared Adams1-1/+0
2009-11-29Fix NPC choice interfaceJared Adams1-14/+14
Don't allow no selection to be sent. Reset selection on new dialog to fix issues with list size changes. Fixes: http://bugs.manasource.org/view.php?id=36
2009-08-07Gettext fixesKess Vargavind1-1/+2
Trying to use the same kind of capitalization and interpunctuation for various parts of the gui, melding a few split strings, updating POTFILES.in and adding translators' notes.
2009-07-26Gettext fixesKess Vargavind1-4/+4
And a Swedish translation of the desktop file.
2009-07-23Clear some more support ifdefsJared Adams1-0/+2
2009-06-30Fixed compiler warning about unsigned/signed integer comparisionThorbjørn Lindeijer1-1/+1
2009-06-27Prevent selection of out of range menu optionsJared Adams1-1/+5
2009-05-13Fixed two compiler warningsBjørn Lindeijer1-0/+3
Enumeration values not handled in switch and an ambiguous else.
2009-05-13Allow more control of NpcDialog using the keyboardJared Adams1-0/+16
The move up and move down keys will now let you navigate the list mode and change the value on the integer mode.
2009-05-10Fixed the resize grip of the party windowBjørn Lindeijer1-3/+0
It wasn't re-added after doing a clear. Also, don't leak all the PartyMember and Avatar instances.
2009-05-10Marked some strings as not translatableBjørn Lindeijer1-2/+2
NPC dialog requested translation of + and - and the chat dialog tried to translate a semicolon.
2009-05-09Increased the distance between head and overhead text a bitBjørn Lindeijer1-2/+3
Plus some small code cleanups.