Commit Graph

4464 Commits

Author SHA1 Message Date
James Frowen
44401ab3bf
Update NetworkHeadlessLogger.cs 2020-09-19 11:30:41 +01:00
vis2k
c776b88e69 docs: background updated 2020-09-19 11:09:00 +02:00
vis2k
d9cb416501 docs: logo size fixed 2020-09-19 11:02:17 +02:00
vis2k
e569754962 docs: favicon updated 2020-09-19 10:16:15 +02:00
vis2k
112408e0eb docs: logo updated 2020-09-19 10:08:14 +02:00
vis2k
d559bcfea7 Icon updated to half M 2020-09-19 10:01:10 +02:00
Paul Pacheco
07d290fd8c
Enhance code readability by using extension method (#2260)
# Before

This is hard to read:
```
if (ca.AttributeType.FullName == typeof(Mirror.CommandAttribute).FullName) {
...
}
```

# After

```
if (ca.AttributeType.Is<Mirror.CommandAttribute>()) {
...
}
```
2020-09-18 14:54:51 -05:00
James Frowen
7919942110
Splitting up test function
* Update NetworkServerTest.cs

splitting up test

* Update NetworkServer.cs

using string interpolation
2020-09-18 20:47:54 +01:00
Paul Pacheco
e50ea6318f
perf(weaver): No need to manually load mirror and unity assemblies (#2261) 2020-09-18 14:32:14 -05:00
James Frowen
a573bccc79
Update ApiUpdater.cs 2020-09-18 20:14:10 +01:00
Paul Pacheco
0b5989f87d Move overloads together 2020-09-18 13:06:34 -05:00
Paul Pacheco
6cfdd6469a
Simplify type lookup in weaver (#2258)
# Before
WeaverTypes declared a static variable like this:
```cs
public static TypeReference int32Type;
```
Weavertypes then loaded the variable in SetupTargetTypes like this:
```cs
int32Type = ImportSystemModuleType(currentAssembly, systemModule, "System.Int32");
```
Note we lookup the type with a string,  any typo there won't be detected until the code is executed.  It will also not be found by the IDE when you click "find references",  or when you refactor.

Then we use it like this:
```cs
var intType = WeaverTypes.int32Type;
```
This is a DRY violation: I have to modify 3 different code sections just to say that I want the int32 type.

# After
Get rid of all the duplication, and use the type instead of a string:
```cs
var intType = WeaverTypes.Import<int>();
```
No need for static variable,  or to add it in SetupTargetTypes.
2020-09-18 13:05:16 -05:00
vis2k
9d49a25c7b
Update README.md 2020-09-18 16:36:10 +02:00
vis2k
0c848a535f
Update README.md 2020-09-18 16:34:15 +02:00
vis2k
928145df58
Update README.md 2020-09-18 11:37:31 +02:00
James Frowen
13be048f81
Update toc.yml
removing ? from toc
2020-09-17 23:59:28 +01:00
James Frowen
fd80ef734b
Update TCPvsUDP.md 2020-09-17 23:38:25 +01:00
James Frowen
a03df2b8d5
Update index.md
* adding list
* adding node at bottom on how to submit
2020-09-17 23:18:09 +01:00
James Frowen
1370085f2e
Adding user guide mirror quick start guide (#2239)
* adding Mirror Quick Start Guide

* proof read
2020-09-17 22:42:43 +01:00
James Frowen
8dac53ce3c
making InvokeUserCode use correct type in argument (#2259) 2020-09-17 22:41:37 +01:00
James Frowen
b1429df53a
Update toc.yml 2020-09-17 16:15:51 +01:00
James Frowen
7e7b1405ec
Update toc.yml 2020-09-17 16:13:35 +01:00
James Frowen
71dd5835ad
Update index.md
making links include Network
2020-09-17 00:29:55 +01:00
James Frowen
514a61d8d3
Docs tcp vs udp (#2257)
* renaming page

* changing start and end blocks

* updating blocks on tcp and udp

* moving lines above features

* moving links to header
2020-09-17 00:28:40 +01:00
James Frowen
8209a7319a
Update README.md 2020-09-16 22:29:09 +01:00
James Frowen
b86a611674
Restructure docs (#2249)
* moving all guides to Articles folder

* updating toc for root and articles

* fixing toc

* css on side toc

* fixing links on index
2020-09-16 22:27:05 +01:00
James Frowen
c69d8cca0b
flip equals to return early (#2245)
* flip equals to return early

* flip equals to return early

* removing un-needed comment
2020-09-16 12:05:43 +01:00
James Frowen
23bd9559d3
pref: increasing performance when Send is called on no observers (#2244)
* pref increasing performance when sending to no observers

* pref increasing performance when sending to no observers
2020-09-16 10:32:16 +02:00
James Frowen
5eb5ff6601
fix: fixing NullReferenceException when loading scene (#2240)
* fixing null ref error when local player is destroyed

* removing null objects

* fixing InvalidOperationException

* moving code to its own function

* Update Assets/Mirror/Runtime/ClientScene.cs
2020-09-16 10:30:10 +02:00
James Frowen
8b9178faa8
Update main.css
using inherit so color is only in 1 place
2020-09-15 12:14:08 +01:00
James Frowen
4b5b9d9181
Update toc.yml 2020-09-15 12:05:11 +01:00
James Frowen
1025d6a5ef
Update main.css
autoformatting
removing duplicate .sidefilter  block
2020-09-15 11:56:22 +01:00
James Frowen
8461428b13
moving favicon to templates (#2253) 2020-09-15 11:52:51 +01:00
James Frowen
feca6417de
remoivng sub folder from templates (#2252) 2020-09-15 11:52:43 +01:00
James Frowen
f1a028f09c
renaming user guides to Community guides (#2251) 2020-09-15 11:47:03 +01:00
James Frowen
34eb9e5c68
updating docfx.json (#2238) 2020-09-15 11:44:08 +01:00
James Frowen
7580e9a6f5
Update ClientScene.cs (#2250)
* Update ClientScene.cs

Improving logging
- making sure sceneId is always hex
- only logging "Client spawn for ..." if it was successful

* Update ClientSceneTests_OnSpawn.cs
2020-09-14 22:35:41 +01:00
James Frowen
833c329ab2
Update ApiUpdater.cs
- Adding handlers in Awake instead of Start to make sure they are added before start on headless
- using GetComponent for NetworkManagerListServer
- Adding asserts to make sure values are set
2020-09-14 21:58:33 +01:00
James Frowen
b4fea1bfa3
Update NetworkServer.cs (#2247) 2020-09-13 19:07:59 +01:00
James Frowen
5a95ae6fe3
Update FAQ.md 2020-09-13 16:52:33 +01:00
James Frowen
aec9b8a2ec
Update NetworkIdentity.cs
fixing block not being in remarks
2020-09-13 15:44:25 +01:00
James Frowen
d5c2387d1d
Update SyncObject.cs 2020-09-13 14:33:32 +01:00
James Frowen
6411013253
Update FAQ.md 2020-09-13 13:57:34 +01:00
James Frowen
6186aeb9d9
Update Resources.md 2020-09-13 12:28:55 +01:00
James Frowen
f302e2e8bf
Update BestPractices.md 2020-09-13 12:28:09 +01:00
James Frowen
ae9d2e35a9
docs: adding debug notes on list server (#2246) 2020-09-13 02:47:57 +01:00
James Frowen
844904dae5
adding doc comment (#2243) 2020-09-13 01:54:23 +01:00
James Frowen
94da8aec34
fix: Fixing IndexChanged hook not being called for NetworkRoomPlayer (#2242)
* adding Server to make sure index is only changed on the server

* removing calls to RecalculateRoomPlayerIndices on client
2020-09-13 01:52:32 +01:00
James Frowen
0c78fa0d7a
making sure CallOnClientExitRoom is called when object is disabled/destroyed (#2241) 2020-09-12 23:36:46 +01:00
James Frowen
d147bbbb38
docs: adding new pages (#2237) 2020-09-12 23:19:42 +01:00