summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
AgeCommit message (Collapse)AuthorFilesLines
2010-07-11Made the different hard-coded paths and files be now taken from theYohann Ferreira1-3/+1
data/paths.xml configuration file. Also added default gui theme path in branding and default wallpaper path and file searched respectively in the branding and paths.xml files. Hard-coded values are still used as fallbacks. Resolves: Manasource Mantis #148. Reviewed-by: jaxad0127.
2010-05-21Fix some issues found by CppcheckJared Adams1-5/+6
2010-05-04Fix mouse attack (tmwa)Andrei Karas1-4/+2
Reviewed-by: Thorbjørn Lindeijer <thorbjorn@lindeijer.nl>
2010-04-19Add afk mode for player.Andrei Karas1-1/+68
Add variable cur_time for current time. Add command /away [text] Reviewed by: Bertram
2010-04-17Changed eAthena protocol name to TmwAthena and changed the config files ↵Bertram1-5/+5
accordingly. This makes room for the actual eAthena protocol future inclusion.
2010-04-16Add race support for eAthenaJared Adams1-2/+2
The job/class field is used to select the race. If the given race isn't defined, it falls back on the first race (so servers can use jobs/classes without races). Also rename job to subtype for Being and subclasses, and begin support for changing monster and NPC subtypes on the fly (particle effects still need to be reset when they change). Reviewed-by: Bertram
2010-04-12Reviewed the LocalPlayer::nextTile() function. The ManaServ movement system ↵Bertram1-127/+347
is functional!! Introduced LocalPlayer::getNextWalkPosition(unsigned char dir) which takes care about the player next position while moving using keyboard. I removed the pixel scaler thing because it couldn't handle all the noticed cases and was rather heavy. There is still a bug in the movement system (nothing's perfect) but it's very rare and this is here in eAthena, too. So, I'll give a try at taking care of it once I'll have polished all of this a bit. Please try and give feedback!!
2010-04-12Forgot to remove Being::checkNodeOffset() function.Bertram1-2/+6
2010-04-12One step closer to the full movement system ready.Bertram1-32/+116
The LocalPlayer::nextTile() function has been sanitized and the movement system has been fine tuned, but yet not optimized. (Optimizations and riddance of 32 hard-coded value will come later.) There is just one case left not handled correctly when the character walked within one tile south-east of a blocking one and then the player click north-west (through the blocking tile) on a walkable location. Quite rare but still here.
2010-03-31Don't spam change direction packetsJared Adams1-2/+2
Reviewed-by: Chuck Miller
2010-03-25Remove the type boolean from InventoryWindowJared Adams1-2/+1
This moves inventory/storage type into the Inventory class, having size default to a call to the netcode to get the sive for the given type. Reviewed-by: Chuck Miller
2010-03-25Merge StorageWindow into InventoryWindowJared Adams1-1/+0
Reviewed-by: Chuck Miller
2010-03-25Eliminate the logic methods from InventoryWindow and StorageWindowJared Adams1-0/+15
2010-03-12Fix some issues with Being deletionJared Adams1-4/+5
Clear the Viewport's hover being when it gets removed and make sure LocalPlayer's target pointer get's cleared. Reviewed-by: Freeyorp
2010-03-12Split Palette into Theme and UserPaletteJared Adams1-7/+6
Themes can now control the colors they use. Colors in the Viewport (being names, particles, etc) can still be changed by the user. Also make ProgressBars more easily colored. DyePalette was made more flexible in the process. Also fixes comparing strings of different lengths insensitively. Reviewed-by: Thorbjørn Lindeijer
2010-03-05Rename SkinLoader to ThemeJared Adams1-3/+3
Also merge the guialpha ConfigListener into Theme. Reviewed-by: Thorbjørn Lindeijer
2010-03-02Remove some unused membersJared Adams1-5/+0
Reviewed-by: Chuck Miller
2010-03-02Revert "Merge WindowContainer into Viewport and remove extra members"Jared Adams1-0/+5
This reverts commit 67e678094b9fddd21fb3c690130e772937ab2746. Conflicts: src/gui/gui.cpp src/gui/viewport.cpp
2010-03-01Merge WindowContainer into Viewport and remove extra membersJared Adams1-5/+0
Reviewed-by: Chuck Miller
2010-02-28Make the gui more themeable and distribute two themesJared Adams1-15/+9
The older gray theme and the new wood theme are available as themes. The gray theme needs some new graphics for hilights. Add a theme option for branding and add path/to/branding/data to the PhysFS search path. Reviewed-by: Thorbjørn Lindeijer Reviewed-by: Chuck Miller
2010-02-24Move StorageWindow to instancing intead of globalJared Adams1-11/+0
Also make storage under eAthena more flexible. Reviewed-by: Dennis Friis
2010-02-23Sanitized ManaServ movement protocol, by mainly moving code from LocalPlayer ↵Bertram1-53/+7
to Being. This fixes some movement glitches under ManaServ and make the code much cleaner even if it's not perfect enough yet. First of all, many checks have been gathered in the Being::setDestination() calls. Also, now all path nodes including destination are checked against surrounding tiles to correct the path when necessary. The LocalPlayer::nextTile() still needs to be reviewed and some checks are missing but it's almost done :)
2010-02-23Got rid of superfluous Destination coordinates in LocalPlayer.Bertram1-5/+1
This will help simplifying setDestination() calls. No regression seen in both client.
2010-02-21Made tick counter and framerate limiter work during login sequenceThorbjørn Lindeijer1-1/+1
Much code was moved from main() to the new Client::exec(). This new event loop now integrates with the Game class, so that the tick counter and framerate limiter apply universally. The Client class is also responsible for some things that used to be global variables. Mantis-issue: ...
2010-02-22Modify copyright headersFreeyorp1-1/+2
2010-02-20License header update for The Mana ClientThorbjørn Lindeijer1-4/+3
2010-02-19Fixed a crash when trying to switch serversThorbjørn Lindeijer1-4/+4
Ownership of the charInfo global variable wasn't well defined. It was being locked, unlocked and generally modified from a lot of places, and somewhere in this mess it ended up crashing when switching servers. Now the CharHandler instances, for eAthena and manaserv respectively, own this list of characters. A new class, Net::Character wraps up the slot index in combination with the player dummy. The list is passed on to the CharSelectDialog each time it changes. Both related and unrelated cleanups were made as well. Reviewed-by: Jared Adams
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-02-01Small cleanups.Bertram1-4/+4
2010-01-31Unify eAthena and manaserv support in to one build.Daniel Bradshaw1-254/+266
Finish support for server types in the server dialog. Using the new server type function, strip out ifdefs, replacing them with if blocks for later merging in smaller atomic commits. Remove any remaining references to the support defs, including in build system.
2010-01-28Added virtual destructors, some implicit casts, and a couple of type changes.Daniel Bradshaw1-3/+3
Many warnings removed. Reviewed-by: Thorbjørn Lindeijer <thorbjorn@lindeijer.nl>
2010-01-27Added mutators/accessors to being.h and smal cleanups.Bertram1-1/+1
2010-01-26Fix a few more _SUPPORT ifdefs and namespace PartyTabJared Adams1-4/+1
2010-01-21No point in differentiating between int and Uint16Thorbjørn Lindeijer1-5/+1
2010-01-13Supress level up notifications when startingJared Adams1-4/+6
2010-01-13Fix initialization order in the new follor managerJared Adams1-3/+4
2010-01-13Adds a follow manager for usersBlueSansDouze1-2/+3
Right click contextual menu on player "follow" entry Cancel the following by moving with mouse or keys Adds a special behavior for map changes
2010-01-12Standardize header orderJared Adams1-3/+2
Also remove some extra new lines and fix eAthena's PartyTab define guards.
2010-01-10Remove some support ifdefsJared Adams1-22/+17
2010-01-10Change code styleAndrei Karas1-7/+16
2010-01-06Removed the nonsensical particle popups with the percent of exp to next ↵Philipp Sehmisch1-1/+3
level on Manaserv
2009-12-16Stored the cached config value which says if non-crucial particle effects ↵Philipp Sehmisch1-0/+3
are enabled or not in a static member of class Particle instead of an instanced member of Being.
2009-11-07More eAthena guild stuffJared Adams1-5/+5
Also some related chenges elsewhere
2009-11-03Move ManaServ guild code into GuildHandlerJared Adams1-5/+6
Ad start eAthena's GuildHandler
2009-11-03Remove more _SUPPORT ifdefs and do some cleanupJared Adams1-76/+14
2009-11-02Fix an uninitialized value error in LocalPlayerJared Adams1-0/+1
2009-10-29Second round of fine tuning for keyboard movement.Bertram1-4/+2
I just discovered that the X,Y offsets aren't handled the same way between eAthena and Manaserv to draw the player's character. So, this patch hopefully fix the walk on water bug. There are some glitches left: - Like walking diagonally to a blocked corner. - Or Some times the character miss a blocked tile and correct its route. - The character's name is drawn in the wrong place for Manaserv client. - The playerBox draws the player at the wrong location; He's not centered at login and isn't diplayed at all in equipment window... But anyway, it's better than before. I'll go on for some polishing before continuing. Some cleanups are becoming vital for code's understanding.
2009-10-29Mostly fixed the walk on water bug... But...Bertram1-18/+29
The current code tells that the character must stop in the middle of a tile when the tile to the north is blocking. But even now with respecting this, the player is still on water. So, what to do? Correct the water tile?
2009-10-24REplace instances of TMW with ManaJared Adams1-26/+26
2009-10-22Fix flipping player's direction when using keyboard to walk diagonally.Bertram1-2/+2