Commit Graph

4734 Commits

Author SHA1 Message Date
MrGadget1024
f31a9ce5ea doc: Updated Script Templates doc 2020-10-26 20:07:28 -04:00
MrGadget1024
78d420f6c9 doc: Updated Script Templates doc 2020-10-26 11:49:20 -04:00
MrGadget1024
e700e1e232 Updated ScriptTemplates to Mirror 23.0.3 2020-10-26 11:45:26 -04:00
James Frowen
8e772a2077
fix(weaver): Fixing weaver not writing when assemble didn't have NetworkBehaviour (#2373)
* Making ReaderWriterProcessor return if it found custom functions (not counting ones in mirror.dll)
* Always writing generateContainerClass if modified
* processing PropertySiteProcessor if either ReaderWriterProcessor or WeaveModule are successful
* creating generateContainerClass in WeaverList constructor
* Moving new WeaverList to after WeaverTypes.SetupTargetTypes
2020-10-26 15:51:38 +01:00
James Frowen
4efd19c4ff
feat: Middleware transport (#2362)
* feat: adding MiddlewareTransport

* Allows Middleware to be created at the transport layer
* Middleware can choice which methods they want to override and which to let inner handle

* using expression bodies
2020-10-25 21:42:00 +01:00
MrGadget1024
4628685a62 fixed outdated comment 2020-10-25 15:25:34 -04:00
MrGadget1024
8c08ecf84d Empty braces on same line 2020-10-25 13:44:07 -04:00
MrGadget
75ce277a68
Add Accept and Reject methods to Authenticator (#2370)
* Add Accept and Reject methods to Authenticator

* Tabs To Spaces

* Removed `base.`

Co-authored-by: MrGadget1024 <chris@clevertech.net>
2020-10-25 12:55:29 -04:00
James Frowen
b19a8ccd12 fix(SimpleWebTransport): making sure that ReadHelper.Read reads exactly number of bytes
Docs say that stream.Read could return less than length. Keep reading stream untill length is reached.
2020-10-25 16:05:35 +00:00
James Frowen
414030d023
fix: making ClientAuthorityCallback an event (#2363)
* stops error prone behaviour of using = from multiple scripts

BREAKING CHANGE: `= callback` now needs to be `+= callback`
2020-10-25 17:01:53 +01:00
MrGadget
8f4ff423cb
Basic Authenticator code organization and comments (#2369)
Co-authored-by: MrGadget1024 <chris@clevertech.net>
2020-10-25 09:52:16 -04:00
MrGadget1024
7f302dbe4c Updated ScriptTemplates package 2020-10-24 19:22:14 -04:00
James Frowen
a833f5c29f
Running code clean up (#2364)
* removing un-needed using
* whitespace
* using explicit types
2020-10-24 20:24:54 +01:00
James Frowen
28fc75140c
fix: improving errors in SendTargetRPCInternal (#2358)
* fix: improving errors in SendTargetRPCInternal

* now give error when connection is null
* updating error message to accurately explain what went wrong
2020-10-24 20:18:59 +01:00
MrGadget1024
25ebdbe9f9 fixed typo 2020-10-24 13:09:17 -04:00
MrGadget1024
cfde24570d Updated ChangeLog 2020-10-24 13:08:59 -04:00
MrGadget
77c844184e
Remove Obsoletes (#2361)
BREAKING CHANGE: Removed Obsolete Methods and Tests
2020-10-24 11:36:44 -05:00
MrGadget1024
60bc1555a5 Added Deprecated date to SyncList 2020-10-24 11:37:54 -04:00
MrGadget
749c9ee970
Make SerializeSyncVars & DeserializeSyncVars protected virtual (#2360)
Co-authored-by: MrGadget1024 <chris@clevertech.net>
2020-10-24 16:18:31 +02:00
MrGadget
cf3cf6a1ab
Remove EditorBrowsable Never Attributes (#2359)
Co-authored-by: MrGadget1024 <chris@clevertech.net>
2020-10-24 16:18:05 +02:00
MrGadget1024
0df71c9812 Updated ChangeLog 2020-10-24 08:05:38 -04:00
MrGadget1024
84ff75a8bb Updated ChangeLog 2020-10-23 21:37:01 -04:00
James Frowen
f08ce4e17e
docs: starting change log for next version (#2343)
* starting change log for next version

* changes
2020-10-24 02:21:12 +01:00
James Frowen
0c6b63a2b1 simpleweb refactor changes 2020-10-22 19:13:58 +01:00
MrGadget1024
8fb7b4b1f4 Revert "Replaced package with zip file"
This reverts commit 150fd1160a.
2020-10-22 10:16:27 -04:00
James Frowen
0c449da179
docs: allowing .unitypackage to be used 2020-10-22 15:15:58 +01:00
MrGadget1024
150fd1160a Replaced package with zip file 2020-10-22 09:47:28 -04:00
Chris Langsenkamp
b7fcd0eb55 Added ScriptTemplates package to docs 2020-10-22 08:25:18 -04:00
vis2k
d940db7e65 fix: #2357 (the second bug): NetworkServer.DisconnectAllConnections now iterates a copy of connections.Values to InvalidOperationException in cases where Transport.ServerDisconnect calls Mirror's OnServerDisconnect event immediately, which calls NetworkServer.OnDisconnected(connectionId), which would remove the connection while DisconnectAllConnections is iterating over them. 2020-10-22 11:36:18 +02:00
James Frowen
06ae90878d
Removing IDisposable from NetworkConnection (#2345)
* clientOwnedObjects is a hash set which doesn't need to be disposed
* DestroyOwnedObjects already clears list which is called by networkmanager when connection disconnects

Co-authored-by: vis2k <info@noobtuts.com>
2020-10-22 09:50:37 +02:00
James Frowen
46d8077780
Simplifing IsClientAlive check (#2346)
* moving check to base connection because it could be used for either
* renaming to IsAlive
* passing in timeout so it doesn't need to check NetworkServer
* updating doc comment
2020-10-22 09:48:35 +02:00
Chris Langsenkamp
048033faa6 Updated docs for NetworkMessage 2020-10-21 18:04:33 -04:00
Chris Langsenkamp
2439af8c5e Applied Mirror Icon 2020-10-21 17:56:14 -04:00
MrGadget
52de152245
Update Deprecations.md 2020-10-21 17:33:47 -04:00
vis2k
d3f1ee9819 fix: NetworkClient.Disconnect avoids NullReferenceException if Transport ClientDisconnect calls OnDisconnected immediately. Related to: https://github.com/vis2k/Mirror/issues/2353 2020-10-21 20:41:40 +02:00
Paul Pacheco
71dc3a2481 fix: recursive types with collections 2020-10-20 09:47:43 -05:00
Paul Pacheco
3bf41c89ea
simplify serializing collections (#416) (#2348)
The code to serialize lists, arrays, and array segments is now in the runtime instead of generated in the weaver.

removes about 300 LOC of weaver witchcraft
2020-10-20 09:47:00 +02:00
James Frowen
c789e2a510
using null propagation for RemoveOwnedObject (#2347) 2020-10-20 01:33:20 +01:00
James Frowen
25be44840e
checking if incoming message has length 0 before checking its id (#2336) 2020-10-18 23:07:10 +02:00
James Frowen
e368284f8e breaking: Removing websockets from mirror repo (#2268)
* Replacing transport with new that doesn't depend on library, see https://github.com/MirrorNetworking/SimpleWebTransport/
* Code for old transport can now be found here https://github.com/MirrorNetworking/NinjaWebSocketsTransport
* We shouldn't need to replace with empty files from store as having this in project should not break things

empty commit for CI, real commit here f3f0403
2020-10-18 00:36:20 +01:00
James Frowen
5eac88aa38 feat: adding NetworkRigidbody2D (#2322)(#2342)
* using angularVelocitySensitivity
* removing un-needed using
* using vec2 instead of vec3
2020-10-17 20:46:58 +01:00
James Frowen
59e91c8bec
moving page out of guides header (#2341)
* moving page out of guides header

* Community guides
* FAQ
* Resources

* updating note at top
2020-10-17 20:29:17 +01:00
pitaya4
b0430efa40
Added support for 2D rigidbodies (#2322)
Added `Mirror.Experimental.NetworkRigidbody2D`, which supports 2D rigid bodies instead of regular ones.
2020-10-17 20:24:30 +01:00
Paul Pacheco
ea7594e558
perf: use built in == instead of unity one (#2339)
* perf: use built in == instead of unity one

should be the same performance as #2325 without the complexity

* more readable version

* more readable version
2020-10-17 13:50:38 -05:00
James Frowen
b44cf7dbcf
docs: Updating transport docs (#2337)
* updating transport pages on litenetlib and simpleweb transports

* updating other pages to reference new transports

* updating links for new transports
2020-10-16 19:01:39 +01:00
James Frowen
9d2334ca19
Update main.yml
removing old websocket from sonar ignore
2020-10-16 16:59:46 +01:00
James Frowen
92c7196f69
feat: Adding SimpleWebTransport v0.6.1 to mirror repo (#2323)
* Intial commit

see https://github.com/MirrorNetworking/SimpleWebTransport  for full git histroy

* Update main.yml

Adding SimpleWebTransport to coverage exclusions

* fully ignoring SimpleWebTransport from sonarcloud

SimpleWebTransport has sonarcloud running on its own repo

* using Buffer.BlockCopy

* SimpleWebTransport v0.4.1

* making error messages use LogError (MirrorNetworking/SimpleWebTransport@5f0096c)
* messages with length of 1 can be recieved by the client (MirrorNetworking/SimpleWebTransport@4237fc4)
* stopping un-needed error logs after disconnect (MirrorNetworking/SimpleWebTransport@25ff190)

* updating readme

* SimpleWebTransport v0.5.0

* adding missing warn level to Log.Levels (MirrorNetworking/SimpleWebTransport@0f68498)
* Allowing multiple instances of javascript client (MirrorNetworking/SimpleWebTransport#14) (MirrorNetworking/SimpleWebTransport@cc6e513)

* SimpleWebTransport v0.5.8

* Stopping send error when client disconnects
* Adding buffer pool
* Using ArrayBuffer for receive
* Removing info and verbose logging by default so performance isnt effected in editor or development builds.
* Making WebSocketClientStandAlone use timeouts from inspector
* Removing incorrect header from inspector
* Removing readonly from logger so that it can be set
* Fixing use of Interlocked in buffer pools
* using ManualResetEventSlim
* making Log.Exception always be logged

* SimpleWebTransport v0.6.0

* Trying to fix error when connection is closed
* Increase arraybuffer speed
* Removing shared buffers from server handshake
* Improving debug logging

* fixing code smells

* SimpleWebTransport v0.6.1

* making sure pending connection work when stop serve is called

* removing exception that isnt directly thrown by this method

this breaks docfx for some reason
2020-10-16 16:46:45 +01:00
James Frowen
f3f0403005
Removing websockets from mirror repo (#2268)
* Adding new websocket transport soon that doesn't depend on library
* Code for old transport can now be found here https://github.com/MirrorNetworking/NinjaWebSocketsTransport
* We shouldn't need to replace with empty files from store as having this in project should not break things
2020-10-16 16:46:04 +01:00
James Frowen
a2b64a4d1d
Update cloud readme
making examples a link
2020-10-15 17:57:48 +01:00
Paul Pacheco
ad30db3cd7
Update CONTRIBUTING.md 2020-10-13 20:24:33 -05:00