summaryrefslogtreecommitdiffstats
path: root/modules/enet/networked_multiplayer_enet.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Added some obvious errors explanationsqarmin2019-09-251-1/+1
|
* Replace 'ERR_EXPLAIN' with 'ERR_FAIL_*_MSG' in rest of 'modules/'Robin Hübner2019-08-121-9/+2
|
* Add default values to the editor help, docs, and generated RSTBojidar Marinov2019-06-271-1/+3
| | | | | Also, make spacing of "=" in the editor help a bit more consistent. Closes #16086
* Fix ENet incorrectly binding to wildcard.Fabio Alessandrelli2019-06-151-0/+1
| | | | | Values were not properly initialized, and wildcard would evaluate to true in most cases.
* Fix error macro calls not ending with semicolonRémi Verschelde2019-06-111-2/+2
| | | | | | | It's not necessary, but the vast majority of calls of error macros do have an ending semicolon, so it's best to be consistent. Most WARN_DEPRECATED calls did *not* have a semicolon, but there's no reason for them to be treated differently.
* Fix typos with codespellRémi Verschelde2019-05-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Using codespell 1.15.0. Method: ``` $ cat > ../godot-word-whitelist.txt << EOF ang curvelinear doubleclick leapyear lod merchantibility nd numer ois ony que seeked synching te uint unselect webp EOF $ codespell -w -q 3 -I ../godot-word-whitelist.txt --skip="./thirdparty,*.po" $ git diff // undo unwanted changes ```
* Merge pull request #25004 from Faless/enet/proto_optimizeHein-Pieter van Braam2019-04-231-9/+7
|\ | | | | Save 4 bytes in ENet multiplayer protocol.
| * Save 4 bytes in ENet multiplayer protocol.Fabio Alessandrelli2019-01-151-9/+7
| | | | | | | | | | | | Avoid sending encoded packet flags (reliable/unreliable/ordered) as that's already been done by ENet itself and we can read them from the incoming packet.
* | Style: Apply new changes from clang-format 8.0Rémi Verschelde2019-04-091-2/+5
| | | | | | | | | | | | It seems to stay compatible with formatting done by clang-format 6.0 and 7.0, so contributors can keep using those versions for now (they will not undo those changes).
* | Fix all -Wtype-limits warnings.marxin2019-02-211-1/+0
| |
* | Add check to validate client IDs in ENet.Fabio Alessandrelli2019-02-201-0/+7
|/ | | | | Server now checks that the ID received from the client is not already used by someone else and is a valid ID (>=2)
* Update copyright statements to 2019Rémi Verschelde2019-01-011-2/+2
| | | | Happy new year to the wonderful Godot community!
* ENet: Remove redundant if conditionRémi Verschelde2018-09-261-1/+1
| | | | Closes #22445.
* Set ENet service time to 0.Fabio Alessandrelli2018-09-251-2/+2
| | | | Process all packets in queue, but never wait.
* Merge pull request #21982 from luzpaz/misc-typosRémi Verschelde2018-09-131-6/+6
|\ | | | | Misc. typos
| * Misc. typosluz.paz2018-09-121-6/+6
| | | | | | Found via `codespell -q 3 -I ../godot-word-whitelist.txt --skip="./thirdparty,*.po"`
* | Make core/ includes absolute, remove subfolders from include pathRémi Verschelde2018-09-121-3/+3
|/ | | | | | This allows more consistency in the manner we include core headers, where previously there would be a mix of absolute, relative and include path-dependent includes.
* Reduce unnecessary COW on Vector by make writing explicitHein-Pieter van Braam2018-07-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | This commit makes operator[] on Vector const and adds a write proxy to it. From now on writes to Vectors need to happen through the .write proxy. So for instance: Vector<int> vec; vec.push_back(10); std::cout << vec[0] << std::endl; vec.write[0] = 20; Failing to use the .write proxy will cause a compilation error. In addition COWable datatypes can now embed a CowData pointer to their data. This means that String, CharString, and VMap no longer use or derive from Vector. _ALWAYS_INLINE_ and _FORCE_INLINE_ are now equivalent for debug and non-debug builds. This is a lot faster for Vector in the editor and while running tests. The reason why this difference used to exist is because force-inlined methods used to give a bad debugging experience. After extensive testing with modern compilers this is no longer the case.
* Expose channels in NetworkedMultiplayerENetFabio Alessandrelli2018-05-121-6/+79
|
* Document websocket module, further document enetFabio Alessandrelli2018-05-081-2/+2
|
* Enet: Add wait time param to close_connection()mhilbrunner2018-05-071-21/+61
| | | | | | | | Enet: Allow to set client interface/address and port Enet: More error checks Fix comment
* Add DNS resolution in NetworkedMultiplayerEnet::create_client()mhilbrunner2018-04-131-7/+21
|
* Implement get_peer_[address|port] in ENet/WSServerFabio Alessandrelli2018-04-121-1/+31
| | | | | | | Also implement get_connected_host and get_connected_port in WebSocketPeer (not supported in HTML5 due to browser limitation). Add shorthand disconnect_peer(id) for get_peer(id)->close() like in ENet to WebSocketServer.
* NetworkedMultiplayerEnet: Add disconnecting/kicking peersmhilbrunner2018-04-101-46/+70
|
* Bind many more properties to scriptsBojidar Marinov2018-01-121-0/+6
| | | | | | | Notable potentially breaking changes: - PROPERTY_USAGE_NOEDITOR is now PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_NETWORK, without PROPERTY_USAGE_INTERNAL - Some properties were renamed, and sometimes even shadowed by new ones - New getter methods (some virtual) were added
* Add missing copyright headers and fix formattingRémi Verschelde2018-01-051-0/+1
| | | | | | Using `misc/scripts/fix_headers.py` on all Godot files. Some missing header guards were added, and the header inclusion order was fixed in the Bullet module.
* Update copyright statements to 2018Rémi Verschelde2018-01-011-2/+2
| | | | Happy new year to the wonderful Godot community!
* Remove "const" from PacketPeer get_packet/get_varFabio Alessandrelli2017-12-151-2/+2
| | | | | | They are NOT constant methods, as state by the comment message, they fetch the last packet and then forget about it, actively changing the state of the object.
* Made Vector::ptrw explicit for writing, compiler was sometimes using the ↵Juan Linietsky2017-11-251-1/+1
| | | | | | wrong function, leading to unnecesary copy on writes and reduced performance.
* Rename OS::get_data_dir to OS::get_user_data_dirRémi Verschelde2017-11-171-1/+1
| | | | | Will be needed to avoid confusion with system data path (XDG_DATA_HOME) and editor data dir in upcoming refactoring.
* Use HTTPS URL for Godot's website in the headersRémi Verschelde2017-08-271-1/+1
|
* ClassDB: Provide the enum name of integer constantsIgnacio Etcheverry2017-08-201-5/+5
|
* Makes all Godot API's methods Lower CaseIndah Sylvia2017-08-071-1/+1
|
* Add zstd compression support.Ferenc Arn2017-06-081-1/+10
| | | | | zstd has much better compression speed and ratio, and better decompression speed than currently available methods. Also set zstd as the default compression method for Compression as well as FileAccessCompressed functions.
* Add "Godot Engine contributors" copyright lineRémi Verschelde2017-04-081-0/+1
|
* ENet code cleanup and changes from review.Fabio Alessandrelli2017-03-241-7/+0
|
* Update ENet module to support custom ENet libFabio Alessandrelli2017-03-241-6/+28
| | | | Keep compatibility with upstream enet libraries
* A Whole New World (clang-format edition)Rémi Verschelde2017-03-051-232/+214
| | | | | | | | | | | | | | | | | | | | | | | | I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
* Rename the _MD macro to D_METHODHein-Pieter van Braam2017-02-131-6/+6
| | | | | | This new name also makes its purpose a little clearer This is a step towards fixing #56
* Style: Fix whole-line commented codeRémi Verschelde2017-01-141-2/+4
| | | | | They do not play well with clang-format which aligns the `//` part with the rest of the code block, thus producing badly indented commented code.
* ObjectTypeDB was renamed to ClassDB. Types are meant to be more generic to ↵Juan Linietsky2017-01-021-6/+6
| | | | | | | | Variant. All usages of "type" to refer to classes were renamed to "class" ClassDB has been exposed to GDScript. OBJ_TYPE() macro is now GDCLASS()
* Merge pull request #7271 from Faless/ipv6_cleanupRémi Verschelde2017-01-021-6/+5
|\ | | | | Fixes and improvementes for IPv6 implementation.
| * IP_Address now handle IPv4 and IPv6 transparentlyFabio Alessandrelli2016-12-091-6/+5
| | | | | | | | | | | | | | | | | | | | IP_Address changes: - Converts to and from String transparently while handling IPv4 as IPv6 mapped (::ffff:[IP]) address internally. - Completely remove AddrType enum. - Setting/Getting of ip array is now only possible through dedicated functions (ie. set_ipv4, get_ipv4, set_ipv6, get_ipv6) - Add function to know if the address is a valid IPv4 (for IP implementation and enet)
* | Welcome in 2017, dear changelog reader!Rémi Verschelde2017-01-011-1/+1
|/ | | | | | | | That year should bring the long-awaited OpenGL ES 3.0 compatible renderer with state-of-the-art rendering techniques tuned to work as low as middle end handheld devices - without compromising with the possibilities given for higher end desktop games of course. Great times ahead for the Godot community and the gamers that will play our games!
* adding ipv6Ariel Manzur2016-10-181-3/+6
|
* enet: Split enet thirdparty files and allow unbundlingRémi Verschelde2016-10-151-0/+28
| | | | | Building against shared libraries only implemented for Linux X11 so far. TODO: Document Godot's modifications of upstream enet.
* Merge pull request #6741 from Faless/network_no_spoofRémi Verschelde2016-10-091-1/+6
|\ | | | | Better checks for Multiplayer API, prevent packet source spoofing.
| * Better checks for Multiplayer API, prevent packet source spoofing.Fabio Alessandrelli2016-10-071-1/+6
| | | | | | | | | | | | | | | | | | | | Fixes the following problems. A malicious client was able to contact another peer faking its identity (even looking like he was the server). A malicious client was able to force other client disconnections by sending bogus system packets to the server.
* | Merge pull request #6657 from Faless/multi_channel_rpcRémi Verschelde2016-10-091-16/+20
|\ \ | |/ |/| Use 2 different ENet channels for reliable/unreliable packets
| * Use 2 different ENet channels for reliable/unreliable packetsFabio Alessandrelli2016-09-301-16/+20
| | | | | | | | | | This avoids stalling other sequenced but unreliable packets (i.e. UNRELIABLE_ORDERED) when sending RELIABLE packets.