Skip to content

Commit e86e916

Browse files
authored
Merge pull request #1 from Kassout/v0.1.1
update version v0.1.1
2 parents 85bd7d9 + 6b9b56d commit e86e916

File tree

4 files changed

+340
-24
lines changed

4 files changed

+340
-24
lines changed

ReallyTinyStrategies_Script/Assets/Scripts/Cameras/FaceCamera.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ public class FaceCamera : MonoBehaviour
1515
/// </summary>
1616
private void Start()
1717
{
18-
if (Camera.main != null)
18+
if (Camera.main is not null)
1919
{
2020
_mainCameraTransform = Camera.main.transform;
2121
}

ReallyTinyStrategies_Script/Assets/Scripts/Inputs/Controls.cs

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
1-
// GENERATED AUTOMATICALLY FROM 'Assets/Scripts/Inputs/Controls.inputactions'
1+
//------------------------------------------------------------------------------
2+
// <auto-generated>
3+
// This code was auto-generated by com.unity.inputsystem:InputActionCodeGenerator
4+
// version 1.2.0
5+
// from Assets/Scripts/Inputs/Controls.inputactions
6+
//
7+
// Changes to this file may cause incorrect behavior and will be lost if
8+
// the code is regenerated.
9+
// </auto-generated>
10+
//------------------------------------------------------------------------------
211

312
using System;
413
using System.Collections;
514
using System.Collections.Generic;
615
using UnityEngine.InputSystem;
716
using UnityEngine.InputSystem.Utilities;
817

9-
public class @Controls : IInputActionCollection, IDisposable
18+
public partial class @Controls : IInputActionCollection2, IDisposable
1019
{
1120
public InputActionAsset asset { get; }
1221
public @Controls()
@@ -24,7 +33,8 @@ public @Controls()
2433
""id"": ""5aa37ad2-2e02-4eb5-b070-6ace63607923"",
2534
""expectedControlType"": ""Vector2"",
2635
""processors"": """",
27-
""interactions"": """"
36+
""interactions"": """",
37+
""initialStateCheck"": true
2838
}
2939
],
3040
""bindings"": [
@@ -208,6 +218,16 @@ public void Disable()
208218
{
209219
asset.Disable();
210220
}
221+
public IEnumerable<InputBinding> bindings => asset.bindings;
222+
223+
public InputAction FindAction(string actionNameOrId, bool throwIfNotFound = false)
224+
{
225+
return asset.FindAction(actionNameOrId, throwIfNotFound);
226+
}
227+
public int FindBinding(InputBinding bindingMask, out InputAction action)
228+
{
229+
return asset.FindBinding(bindingMask, out action);
230+
}
211231

212232
// Player
213233
private readonly InputActionMap m_Player;

ReallyTinyStrategies_Script/Assets/Scripts/UI/MainMenu.cs

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1+
using kcp2k;
12
using Mirror;
3+
using Mirror.FizzySteam;
24
using Steamworks;
35
using UnityEngine;
46

@@ -39,12 +41,15 @@ private void Start()
3941
{
4042
if (!useSteam)
4143
{
42-
return;
44+
lobbyCreated = Callback<LobbyCreated_t>.Create(OnLobbyCreated);
45+
gameLobbyJoinRequested = Callback<GameLobbyJoinRequested_t>.Create(OnGameLobbyJoinRequested);
46+
lobbyEntered = Callback<LobbyEnter_t>.Create(OnLobbyEntered);
47+
}
48+
else
49+
{
50+
NetworkManager.singleton.GetComponent<KcpTransport>().enabled = true;
51+
NetworkManager.singleton.GetComponent<FizzySteamworks>().enabled = false;
4352
}
44-
45-
lobbyCreated = Callback<LobbyCreated_t>.Create(OnLobbyCreated);
46-
gameLobbyJoinRequested = Callback<GameLobbyJoinRequested_t>.Create(OnGameLobbyJoinRequested);
47-
lobbyEntered = Callback<LobbyEnter_t>.Create(OnLobbyEntered);
4853
}
4954

5055
/// <summary>

0 commit comments

Comments
 (0)