summaryrefslogtreecommitdiff
path: root/src/net
AgeCommit message (Collapse)AuthorFilesLines
2011-03-28Random code cleanups requested righteously by Thorbjorn - part 1.Yohann Ferreira6-32/+24
- Fixed bogus documentation. - Fixed Vector parameters to const Vector& where releavant. - Removed a false comment. - Removed superfluous headers in src/net/tmwa/beinghandler.h. - Optimize a bit the tmwa::beingHandler::getPixelsPerTickMoveSpeed() function.
2011-03-28Added some tolerance on the tA being position message.Yohann Ferreira1-1/+11
Also made the destination equal to the desired position in that case since it's what the tA server expects. This fixes monsters going to strange destinations while fighting them, and makes it all much smoother.
2011-03-17Simplified the get/setAttackRange() functions as requested.Yohann Ferreira2-3/+4
The attack range is still hardcoded for Manaserv as long as generic equipment handling hasn't been implemented.
2011-03-17Handle ta move and position message in a more generic way.Yohann Ferreira1-86/+47
This avoids code duplication.
2011-03-17Now the client centers the pixel positions when using tA.Yohann Ferreira3-0/+12
I made it so that the behaviour can be changed with only a boolean setting in the playerhandler.
2011-03-16Fixed the bug with remote player movement animation,Yohann Ferreira1-7/+9
by removing a now useless reset in the beinghandler. Also added checks for flawed directions.
2011-03-16Fixed the attack range handling for both servers.Yohann Ferreira1-1/+22
The attack range is always the default for manaserv, as proper equipment handling is to be added. Anyway, now the proper attack range is handled in tmwAthena and is always set a proper minimum for both protocols.
2011-03-15Made the tA Beinghandler avoid dealing with flawed coordinates.Yohann Ferreira1-51/+81
Also fixed again a condition in Being::logic(). I'll beautify the code in tmwAthena:Beinghandler once everything will be working better. Note: I also suspect current clients to flood the server with keyboard messages, hence blocking the animation when they are remote. I'll need to test that with someone having the same client than here..
2011-03-15Add a tolerance check on current position to limit desyncs.Yohann Ferreira1-11/+42
Also removed dead code.
2011-03-15Reset destination to position at warp time for TmwAthena.Yohann Ferreira1-2/+5
This fix the following bug: When changing map, the local player sometimes walks randomly until the player reacts.
2011-03-15Simplify the tmwAthena calculation of the pixel/tick speed.Yohann Ferreira1-11/+3
2011-03-15Basically merged the two movement algorithms into one.Yohann Ferreira12-84/+180
This was made in favour of the manaserv way of doing things. I also added a way to keep the original server speed value so the pixel value can be recomputed at each map change, as this was necessary since the speed is given before the first map is loaded. The code is much more simpler now about movement handling, and we can already see improvements on other characters movements in The Mana World with this. Everything can't be perfect the first time; here are bugs identified so far: - Monsters direction isn't updated on TmwAthena for obscure reasons. - Remote players walking animation is sometimes reset on each steps. - When changing map, the local player sometimes walks randomly until the player reacts. Stay tuned!
2011-02-21Merge branch '0.5'Thorbjørn Lindeijer1-3/+4
Translation file updates ignored. Conflicts: src/client.cpp src/commandhandler.cpp src/gui/popupmenu.cpp src/localplayer.cpp
2011-02-21Fixing segmentation fault in chathandlerStefan Dombrowski1-5/+7
Reviewed-by: Jaxad0127, Thorbjorn
2011-02-17Specific messages for each pickup failure reason.Ben Longbons1-3/+4
Reviewed-by: Jaxad0127
2011-02-07Removed remaining reference to MANASERV_SUPPORT define switchPhilipp Sehmisch1-4/+1
Also added an error message should a server ever need another protocol.
2011-02-01Merge branch '0.5'Thorbjørn Lindeijer1-1/+2
Conflicts: po/de.po src/game.cpp src/resources/wallpaper.cpp
2011-01-27Send the correct protocol version when registering on Manaserv.Yohann Ferreira1-1/+1
2011-01-26Prune the enet and manaserv files dependency of the 0.5 binary.Yohann Ferreira1-1/+2
Only using cmake conditions and an ifdef. This will greatly help packaging the mana 0.5 version on other distros.
2011-01-25Upgraded the manaserv protocol version to 1.Yohann Ferreira1-1/+1
Yeah, I know Jaxad, we're not releasing but as agreed with Thorbjorn, the protocol is incompatible even when moving, so better get rid of old clients early.
2011-01-24Refactored the item loading in a more extensible and per protocol way.Yohann Ferreira3-28/+28
This will greatly help into upgrading the need of each protocol separately. This is the first step to a new item and equipment system for manaserv. A subclassing of the EquipmentWindow will be done in the next commit, as requested by Thorbjorn. Reviewed-by: Thorbjorn.
2011-01-11Remove the protocol version magic number.Yohann Ferreira2-1/+3
This follows the changes made on the server. Reviewed-by: Jaxad.
2011-01-09Fix other direction discrepancies on the client.Yohann Ferreira2-23/+10
This fix the change dir (with alt key), attacks directions, and the direction of a being standing when you come in its range. Reviewed-by: Jaxad. Resolves: Mana-mantis #257
2011-01-03Merge branch '0.5'Thorbjørn Lindeijer1-3/+5
Conflicts: po/es.po po/fr.po src/net/tmwa/adminhandler.cpp update-creator.sh
2011-01-03Sync the manaserv_protocol.h file witht the one of the server.Yohann Ferreira1-4/+55
Trivial.
2011-01-02Fixed possible crash when receiving player IPThorbjørn Lindeijer1-3/+6
Could happen sometimes for GMs when the message is received either before the player instance is created or after it was destroyed. Also changed to a dynamic_cast, putting a little less trust in the server. Reviewed-by: Freeyorp
2010-12-30Renamed protocol.h to manaserv_protocol.h to follow server's changes.Yohann Ferreira17-16/+16
I'll sync the two files as for the new enums in a separate commit. Trivial fix. Resolves: Mana-mantis #278.
2010-12-29Made the client handle the characters slots properly for Manaserv.Yohann Ferreira2-6/+11
Reviewed-by: Crush.
2010-12-29Fixed potential flaw for the number of characters slots on tAthena.Yohann Ferreira2-6/+19
Was happening when logging to the dev manaserv server and then to TMW-eA. The client is still crashing after selecting the characters after relogging but that's not introduced with this patch anyway. Reviewed-by: Crush.
2010-12-17Update the net/manaserv/protocol.h file with latest description.Yohann Ferreira1-2/+2
Trivial fix.
2010-12-16Made the client handle the number of slots given by the server.Yohann Ferreira3-4/+23
I turned the CharacterEntries into a vector. As for now, it's basically working but I discovered bugs about slots handling mainly for Manaserv that were already present before that patch. Hence, there are three remaining issues: - Under ManaServ, the character's slots numbers aren't handled when loading the characters but used when sending selection or deletion attempts. For instance, if you delete the character at slot 1, you won't be able to select or delete characters at slots 2 and 3, since the server believes that the characters are now in slots 1 and 2, even thought the client still displays them at the former slots. - Also under manaserv, you won't be able to create a character at slot 1 and 3, the server will automatically add the new one to the next slot, which is not corresponding to where you clicked to the 'Create' button. I propose to make Manaserv send again the character slots numbers and store them in database since we used them in creation, selection, and deletion attempts. It would make more sense IMHO. - The last remaining issue found is that when switching between different servers, the loginData don't get cleaned up, make the characterSelect dialog look crazy when the number of slots is different between two servers. If this one is accepted, my next patch will make the logindata be cleaned up between each login attempts (as for the slot number, and maybe other sensible data) and the next ones will readd character slot handling server and client side. Reviewed-by: Jaxad0127.
2010-12-15Unlock the char select dialog even if we've got an error.Yohann Ferreira1-1/+1
This permit not to be stuck at character deletion when something goes wrong. Trivial fix.
2010-12-06Removed superfluous #includes taken from checkheaders list.Yohann Ferreira5-9/+0
Resolves: Mana-Mantis #265. Trivial fix.
2010-11-12Change NPC handling in the net codeChuck Miller5-104/+212
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 Miller12-57/+58
2010-11-11Have the event system channels use enums instead of stringsChuck Miller18-55/+55
Reviewed-by: Freeyorp
2010-11-09Fix client successful unregister behaviour for manaserv.Yohann Ferreira1-1/+1
Resolves: Mana-Mantis #250. Reviewed-by: Freeyorp, thorbjorn.
2010-11-07Convert the emote system to use particlesChuck Miller1-5/+4
Reviewed-by: Jared Adams
2010-11-02Re-Enable the support of manaserv servers.Yohann Ferreira1-5/+0
Reviewed-by: CodyMartin.
2010-11-01Merge branch '0.5' of gitorious.org:mana/manaYohann Ferreira9-7/+30
Conflicts: src/being.cpp src/client.cpp src/commandhandler.cpp src/gui/setup_video.cpp src/gui/socialwindow.cpp src/gui/viewport.cpp src/gui/widgets/browserbox.cpp src/gui/widgets/itemcontainer.cpp src/imageparticle.cpp src/localplayer.cpp src/localplayer.h src/map.cpp src/net/tmwa/beinghandler.cpp src/particle.cpp src/particle.h src/player.cpp src/player.h
2010-10-31Fix memory leak of localplayer classes in the charserverhandlerChuck Miller2-2/+2
They are initialized else where in the code Reviewed-by: Jared Adams
2010-10-19Heavy GUI fixes related to stats for Manaserv.Yohann Ferreira3-21/+114
Also tested to be compatible with tA. Now the Status window is much more nicer when using Manaserv. HP, max hp, ... are now working fine along with corrections made in the attributes.xml file (in next commit.) Reviewed-by: Thorbjorn.
2010-10-17Removed unnecessary condition in net::readCoordinates.Yohann Ferreira1-6/+2
It is used only by tmwa handlers. Trivial fix.
2010-10-17Fixing missing translation of direction for tA-serverStefan Dombrowski1-0/+7
Reviewed-by: Bertram
2010-10-13Adding theme colors for party tabsStefan Dombrowski1-1/+1
Following Rotonen's advise to "make anything and everything you can think of recolorable", a theme can now define colors for PARTY_CHAT_TAB and PARTY_SOCIAL_TAB. This was badly needed, because the requirements for a color of a chat tab and of a player name are quite different. TODO: When guild support gets enabled, then have a look at the colors for guilds. Reviewed-by: 4144
2010-10-13Hiding Manaserv from the player on TMW-Athena only releaseStefan Dombrowski1-0/+4
With the preprocessor definition MANASERV_SUPPORT the manaserv support is avaible as before. * Removing server type from server dialog GUI. * Ignoring Manaserv entries in serverlist.xml. * In order not to lose Manaserv CustomServers from the config.xml, they get stored in mManaservServers. * The entries in mManaservServers are saved in config.xml again. But they are now behind the TMWA-Athena servers. * For custom server the GUI sets 6901 as default value for port. * If the server type is unknown, then we use TMW-Athena. This is relevant, if the client is started with command line options for server. Reviewed-by: Bertram
2010-10-11Implementing show IP for game mastersStefan Dombrowski3-2/+12
As an upcoming feature the TMW-Athena server sends IP addresses or IP hashes to game masters. The current client freezes if it receives such a packet, therefor the game masters need to use a new client before the server can use it. Normal players are not affected, because they do not get this packet. Showing the IP is optional and can be enable with the chat command "/showip 1". The IP is then shown behind the players name. Reviewed-by: Bertram
2010-10-08Remove the following systemStefan Dombrowski1-21/+0
Removed due to unresolved social issues. In master it had been already removed by Kage in commit 89f192b9039f9c000515f0a12f4bb9fb55c4691c.
2010-10-07Disable guilds netcode.Andrei Karas1-0/+2
Reviewed-by: Jaxad0127
2010-10-04Remove the following systemChuck Miller1-20/+0
The implamentation is poor, and this is something that would be better handled by the addon engine later down the road. Reviewed-By: Freeyorp < Freeyorp101@hotmail.com >