Moving to FishySteamworks

This commit is contained in:
Madhav Kapa 2023-06-01 10:17:45 -07:00
parent 4b3080af85
commit 0eea70ab4e
93 changed files with 13381 additions and 13053 deletions

View File

@ -9,7 +9,63 @@
</component>
<component name="ChangeListManager">
<list default="true" id="8e9b3697-c9b4-441a-aeed-4ea7b4488600" name="Changes" comment="">
<change beforePath="$PROJECT_DIR$/.idea/.idea.station_obscurum_temp/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/.idea.station_obscurum_temp/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/DefaultPrefabObjects.asset" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/DefaultPrefabObjects.asset" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/CodeGenerating/cecil-0.11.4/Mono.Cecil.sln.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/CHANGELOG.txt" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/CHANGELOG.txt.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/BidirectionalDictionary.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/BidirectionalDictionary.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/ClientHostSocket.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/ClientHostSocket.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/ClientSocket.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/ClientSocket.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/CommonSocket.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/CommonSocket.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/FishyConnectionManager.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/FishyConnectionManager.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/FishySocketManager.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/FishySocketManager.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/LocalPacket.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/LocalPacket.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/ServerSocket.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/Core/ServerSocket.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/FishyFacepunch.cs" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/FishyFacepunch.cs.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/VERSION.txt" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/FishNet/Plugins/FishyFacepunch/VERSION.txt.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Posix.dll" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Posix.dll.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Posix.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Posix.xml.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win32.dll" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win32.dll.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win32.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win32.xml.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win64.dll" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win64.dll.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win64.xml" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/Facepunch.Steamworks.Win64.xml.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/linux32.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/linux32/libsteam_api.so" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/linux32/libsteam_api.so.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/linux64.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/linux64/libsteam_api.so" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/linux64/libsteam_api.so.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/osx.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/osx/libsteam_api.bundle" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/osx/libsteam_api.bundle.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/steam_api.dll" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/steam_api.dll.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/steam_api.lib" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/steam_api.lib.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/win64/steam_api64.dll.meta" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Packages/Facepunch/redistributable_bin/win64/steam_api64.dll.meta" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Scenes/Experimentation/MultiplayerScenes/LobbyTesting3d.unity" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Scenes/Experimentation/MultiplayerScenes/LobbyTesting3d.unity" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/Scripts/Steam/SteamLobbyWithPlayer.cs" beforeDir="false" afterPath="$PROJECT_DIR$/Assets/Scripts/Steam/SteamLobbyWithPlayer.cs" afterDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/VFXGraph/GabrielAguiarProductions/VFXGraph_Muzzle_2020.3_HDRP_v1.0.1.unitypackage.meta" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/Assets/VFXGraph/GabrielAguiarProductions/VFXGraph_Muzzle_2020.3_URP_v1.0.1.unitypackage.meta" beforeDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -108,7 +164,7 @@
<workItem from="1685636572156" duration="4819000" />
<workItem from="1685617055026" duration="83000" />
<workItem from="1685617157524" duration="2799000" />
<workItem from="1685632962650" duration="2245000" />
<workItem from="1685632962650" duration="4402000" />
</task>
<servers />
</component>

View File

@ -13,6 +13,7 @@ MonoBehaviour:
m_Name: DefaultPrefabObjects
m_EditorClassIdentifier:
_prefabs:
- {fileID: 3680155643994880520, guid: 502609875cf67524391bcf30129c195b, type: 3}
- {fileID: 4512293259955182956, guid: 300370bdf7819da41937e0beac65b32c, type: 3}
- {fileID: 233110740096973419, guid: e05b94df3e7783a48ac1ed2d12a71774, type: 3}
- {fileID: 611616139817875448, guid: bf5f023b4017a5e41a9815ec5745df3d, type: 3}
@ -21,4 +22,3 @@ MonoBehaviour:
- {fileID: 3624261834906416601, guid: 4e1673ccc2acac543871855a0e8bed71, type: 3}
- {fileID: 201277550, guid: d904f93bc171bb144ba33c5155282f6f, type: 3}
- {fileID: 27039729695437543, guid: f820efff6a2871447b961fc755212ba3, type: 3}
- {fileID: 3680155643994880520, guid: 502609875cf67524391bcf30129c195b, type: 3}

View File

@ -1,30 +0,0 @@
2.1.1
- Added deinitializer to FishyFacepunch.
2.1.0
- Fixed ClientId 32767 not found error when being used with Multipass.
2.0.0
- FishNetworking 2.0.0 support.
1.3.1
- FishNetworking 1.3.1 Support
1.3.0
- Removed obsolete methods
- FishNetworking 1.3.0 Support
1.2.0
- Removed GC (Full Credits to Punfish - Thank you)
- Removed obsolete method
1.1.1
- FishNetworking 0.1.5.Nightly.10 Support
1.1.0
- Support for client hosted games (needs two separated steam accounts, to test) - Thank to Punfish
- Organized folder structure
- Removed ChannelData
1.0.0
- Initial release.

View File

@ -1,92 +0,0 @@
using System.Collections;
using System.Collections.Generic;
namespace FishyFacepunch
{
public class BidirectionalDictionary<T1, T2> : IEnumerable
{
private Dictionary<T1, T2> t1ToT2Dict = new Dictionary<T1, T2>();
private Dictionary<T2, T1> t2ToT1Dict = new Dictionary<T2, T1>();
public IEnumerable<T1> FirstTypes => t1ToT2Dict.Keys;
public IEnumerable<T2> SecondTypes => t2ToT1Dict.Keys;
public IEnumerator GetEnumerator() => t1ToT2Dict.GetEnumerator();
public int Count => t1ToT2Dict.Count;
public Dictionary<T1, T2> First => t1ToT2Dict;
public Dictionary<T2, T1> Second => t2ToT1Dict;
public void Add(T1 key, T2 value)
{
if (t1ToT2Dict.ContainsKey(key))
{
Remove(key);
}
t1ToT2Dict[key] = value;
t2ToT1Dict[value] = key;
}
public void Add(T2 key, T1 value)
{
if (t2ToT1Dict.ContainsKey(key))
{
Remove(key);
}
t2ToT1Dict[key] = value;
t1ToT2Dict[value] = key;
}
public T2 Get(T1 key) => t1ToT2Dict[key];
public T1 Get(T2 key) => t2ToT1Dict[key];
public bool TryGetValue(T1 key, out T2 value) => t1ToT2Dict.TryGetValue(key, out value);
public bool TryGetValue(T2 key, out T1 value) => t2ToT1Dict.TryGetValue(key, out value);
public bool Contains(T1 key) => t1ToT2Dict.ContainsKey(key);
public bool Contains(T2 key) => t2ToT1Dict.ContainsKey(key);
public void Remove(T1 key)
{
if (Contains(key))
{
T2 val = t1ToT2Dict[key];
t1ToT2Dict.Remove(key);
t2ToT1Dict.Remove(val);
}
}
public void Remove(T2 key)
{
if (Contains(key))
{
T1 val = t2ToT1Dict[key];
t1ToT2Dict.Remove(val);
t2ToT1Dict.Remove(key);
}
}
public T1 this[T2 key]
{
get => t2ToT1Dict[key];
set
{
Add(key, value);
}
}
public T2 this[T1 key]
{
get => t1ToT2Dict[key];
set
{
Add(key, value);
}
}
}
}

View File

@ -1,126 +0,0 @@
#if !FishyFacepunch
using FishNet.Transporting;
using FishyFacepunch.Server;
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
namespace FishyFacepunch.Client
{
/// <summary>
/// Creates a fake client connection to interact with the ServerSocket when acting as host.
/// </summary>
public class ClientHostSocket : CommonSocket
{
#region Private.
/// <summary>
/// Socket for the server.
/// </summary>
private ServerSocket _server;
/// <summary>
/// Incomimg data.
/// </summary>
private Queue<LocalPacket> _incoming = new Queue<LocalPacket>();
#endregion
/// <summary>
/// Checks to set localCLient started.
/// </summary>
internal void CheckSetStarted()
{
//Check to set as started.
if (_server != null && base.GetLocalConnectionState() == LocalConnectionState.Starting)
{
if (_server.GetLocalConnectionState() == LocalConnectionState.Started)
SetLocalConnectionState(LocalConnectionState.Started, false);
}
}
/// <summary>
/// Starts the client connection.
/// </summary>
/// <param name="address"></param>
/// <param name="port"></param>
/// <param name="channelsCount"></param>
/// <param name="pollTime"></param>
internal bool StartConnection(ServerSocket serverSocket)
{
_server = serverSocket;
_server.SetClientHostSocket(this);
if (_server.GetLocalConnectionState() != LocalConnectionState.Started)
return false;
SetLocalConnectionState(LocalConnectionState.Starting, false);
return true;
}
/// <summary>
/// Sets a new connection state.
/// </summary>
protected override void SetLocalConnectionState(LocalConnectionState connectionState, bool server)
{
base.SetLocalConnectionState(connectionState, server);
if (connectionState == LocalConnectionState.Started)
_server.OnClientHostState(true);
else
_server.OnClientHostState(false);
}
/// <summary>
/// Stops the local socket.
/// </summary>
internal bool StopConnection()
{
if (base.GetLocalConnectionState() == LocalConnectionState.Stopped || base.GetLocalConnectionState() == LocalConnectionState.Stopping)
return false;
base.ClearQueue(_incoming);
//Immediately set stopped since no real connection exists.
SetLocalConnectionState(LocalConnectionState.Stopping, false);
SetLocalConnectionState(LocalConnectionState.Stopped, false);
_server.SetClientHostSocket(null);
return true;
}
/// <summary>
/// Iterations data received.
/// </summary>
internal void IterateIncoming()
{
if (base.GetLocalConnectionState() != LocalConnectionState.Started)
return;
while (_incoming.Count > 0)
{
LocalPacket packet = _incoming.Dequeue();
ArraySegment<byte> segment = new ArraySegment<byte>(packet.Data, 0, packet.Length);
base.Transport.HandleClientReceivedDataArgs(new ClientReceivedDataArgs(segment, (Channel)packet.Channel, Transport.Index));
packet.Dispose();
}
}
/// <summary>
/// Called when the server sends the local client data.
/// </summary>
internal void ReceivedFromLocalServer(LocalPacket packet)
{
_incoming.Enqueue(packet);
}
/// <summary>
/// Queues data to be sent to server.
/// </summary>
internal void SendToServer(byte channelId, ArraySegment<byte> segment)
{
if (base.GetLocalConnectionState() != LocalConnectionState.Started)
return;
if (_server.GetLocalConnectionState() != LocalConnectionState.Started)
return;
LocalPacket packet = new LocalPacket(segment, channelId);
_server.ReceivedFromClientHost(packet);
}
}
}
#endif // !DISABLESTEAMWORKS

View File

@ -1,238 +0,0 @@
#if !FishyFacepunch
using FishNet.Managing.Logging;
using FishNet.Transporting;
using Steamworks;
using Steamworks.Data;
using System;
using System.Threading;
using System.Threading.Tasks;
using UnityEngine;
namespace FishyFacepunch.Client
{
public class ClientSocket : CommonSocket
{
#region Private.
/// <summary>
/// SteamId for host.
/// </summary>
private SteamId _hostSteamID = 0;
/// <summary>
/// Socket to use.
/// </summary>
private Connection HostConnection => HostConnectionManager.Connection;
/// <summary>
/// Use the internal connection manager from steam.
/// </summary>
private FishyConnectionManager HostConnectionManager;
/// <summary>
/// Task used to check for timeout.
/// </summary>
private CancellationTokenSource cancelToken;
private TaskCompletionSource<Task> connectedComplete;
private TimeSpan ConnectionTimeout;
/// <summary>
/// Task used to check for timeout.
/// </summary>
private bool _Error = false;
#endregion
/// <summary>
/// Initializes this for use.
/// </summary>
/// <param name="t"></param>
internal override void Initialize(Transport t)
{
base.Initialize(t);
}
/// <summary>
/// Starts the client connection.
/// </summary>
/// <param name="address"></param>
/// <param name="port"></param>
/// <param name="channelsCount"></param>
/// <param name="pollTime"></param>
internal async void StartConnection(string address, ushort port)
{
cancelToken = new CancellationTokenSource();
SteamNetworkingSockets.OnConnectionStatusChanged += OnConnectionStatusChanged;
ConnectionTimeout = TimeSpan.FromSeconds(Math.Max(1, base.Transport.GetTimeout(false)));
SetLocalConnectionState(LocalConnectionState.Starting, false);
try
{
if (SteamClient.IsValid)
{
connectedComplete = new TaskCompletionSource<Task>();
if (!IsValidAddress(address))
{
_hostSteamID = UInt64.Parse(address);
HostConnectionManager = SteamNetworkingSockets.ConnectRelay<FishyConnectionManager>(_hostSteamID);
}
else
{
HostConnectionManager = SteamNetworkingSockets.ConnectNormal<FishyConnectionManager>(NetAddress.From(address, port));
}
HostConnectionManager.ForwardMessage = OnMessageReceived;
Task connectedCompleteTask = connectedComplete.Task;
Task timeOutTask = Task.Delay(ConnectionTimeout, cancelToken.Token);
if (await Task.WhenAny(connectedCompleteTask, timeOutTask) != connectedCompleteTask)
{
if (cancelToken.IsCancellationRequested)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"The connection attempt was cancelled.");
}
else if (timeOutTask.IsCompleted)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"Connection to {address} timed out.");
StopConnection();
}
SetLocalConnectionState(LocalConnectionState.Stopped, false);
}
}
else
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError("SteamWorks not initialized");
SetLocalConnectionState(LocalConnectionState.Stopped, false);
}
}
catch (FormatException)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"Connection string was not in the right format. Did you enter a SteamId?");
SetLocalConnectionState(LocalConnectionState.Stopped, false);
_Error = true;
}
catch (Exception ex)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError(ex.Message);
SetLocalConnectionState(LocalConnectionState.Stopped, false);
_Error = true;
}
finally
{
if (_Error)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError("Connection failed.");
SetLocalConnectionState(LocalConnectionState.Stopped, false);
}
}
}
/// <summary>
/// Called when local connection state changes.
/// </summary>
private void OnConnectionStatusChanged(Connection conn, ConnectionInfo info)
{
if (info.State == ConnectionState.Connected)
{
SetLocalConnectionState(LocalConnectionState.Started, false);
connectedComplete.SetResult(connectedComplete.Task);
}
else if (info.State == ConnectionState.ClosedByPeer || info.State == ConnectionState.ProblemDetectedLocally)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Connection was closed by peer, {info.EndReason}");
StopConnection();
}
else
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Connection state changed: {info.State.ToString()} - {info.EndReason}");
}
}
/// <summary>
/// Stops the local socket.
/// </summary>
internal bool StopConnection()
{
if (base.GetLocalConnectionState() == LocalConnectionState.Stopped || base.GetLocalConnectionState() == LocalConnectionState.Stopping)
return false;
SetLocalConnectionState(LocalConnectionState.Stopping, false);
cancelToken?.Cancel();
//Reset callback.
SteamNetworkingSockets.OnConnectionStatusChanged -= OnConnectionStatusChanged;
if (HostConnectionManager != null)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log("Sending Disconnect message");
HostConnection.Close(false, 0, "Graceful disconnect");
HostConnectionManager = null;
}
SetLocalConnectionState(LocalConnectionState.Stopped, false);
return true;
}
/// <summary>
/// Iterations data received.
/// </summary>
internal void IterateIncoming()
{
if (base.GetLocalConnectionState() != LocalConnectionState.Started)
return;
HostConnectionManager.Receive(MAX_MESSAGES);
}
private void OnMessageReceived(IntPtr dataPtr, int size)
{
(byte[] data, int ch) = ProcessMessage(dataPtr, size);
base.Transport.HandleClientReceivedDataArgs(new ClientReceivedDataArgs(new ArraySegment<byte>(data), (Channel)ch, Transport.Index));
}
/// <summary>
/// Queues data to be sent to server.
/// </summary>
/// <param name="channelId"></param>
/// <param name="segment"></param>
internal void SendToServer(byte channelId, ArraySegment<byte> segment)
{
if (base.GetLocalConnectionState() != LocalConnectionState.Started)
return;
Result res = base.Send(HostConnection, segment, channelId);
if (res == Result.NoConnection || res == Result.InvalidParam)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Connection to server was lost.");
StopConnection();
}
else if (res != Result.OK)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"Could not send: {res.ToString()}");
}
}
/// <summary>
/// Sends queued data to server.
/// </summary>
internal void IterateOutgoing()
{
if (base.GetLocalConnectionState() != LocalConnectionState.Started)
return;
HostConnection.Flush();
}
}
}
#endif // !DISABLESTEAMWORKS

View File

@ -1,11 +0,0 @@
fileFormatVersion: 2
guid: c5c258174868ee54cb570bef71c82404
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,177 +0,0 @@
#if !FishyFacepunch
using FishNet.Managing.Logging;
using FishNet.Transporting;
using Steamworks;
using Steamworks.Data;
using System;
using System.Collections.Generic;
using System.Net;
using System.Runtime.InteropServices;
using UnityEngine;
namespace FishyFacepunch
{
public abstract class CommonSocket
{
#region Public.
/// <summary>
/// Current ConnectionState.
/// </summary>
private LocalConnectionState _connectionState = LocalConnectionState.Stopped;
/// <summary>
/// Returns the current ConnectionState.
/// </summary>
/// <returns></returns>
internal LocalConnectionState GetLocalConnectionState()
{
return _connectionState;
}
/// <summary>
/// Sets a new connection state.
/// </summary>
/// <param name="connectionState"></param>
protected virtual void SetLocalConnectionState(LocalConnectionState connectionState, bool asServer)
{
//If state hasn't changed.
if (connectionState == _connectionState)
return;
_connectionState = connectionState;
if (asServer)
Transport.HandleServerConnectionState(new ServerConnectionStateArgs(connectionState, Transport.Index));
else
Transport.HandleClientConnectionState(new ClientConnectionStateArgs(connectionState, Transport.Index));
}
#endregion
#region Protected.
/// <summary>
/// Transport controlling this socket.
/// </summary>
protected Transport Transport = null;
/// <summary>
/// Pointers for received messages per connection.
/// </summary>
protected IntPtr[] MessagePointers = new IntPtr[MAX_MESSAGES];
/// <summary>
/// Buffer used to receive data.
/// </summary>
protected byte[] InboundBuffer = null;
#endregion
#region Const.
/// <summary>
/// Maximum number of messages which can be received per connection.
/// </summary>
protected const int MAX_MESSAGES = 256;
#endregion
internal void ClearQueue(Queue<LocalPacket> lpq)
{
while (lpq.Count > 0)
{
LocalPacket lp = lpq.Dequeue();
lp.Dispose();
}
}
/// <summary>
/// Initializes this for use.
/// </summary>
/// <param name="t"></param>
internal virtual void Initialize(Transport t)
{
Transport = t;
//Get whichever channel has max MTU and resize buffer.
int maxMTU = Transport.GetMTU(0);
maxMTU = Math.Max(maxMTU, Transport.GetMTU(1));
InboundBuffer = new byte[maxMTU];
}
/// <summary>
/// Check if this is a valid address to start a p2p or c2s session.
/// </summary>
/// <param name="address"></param>
/// <returns></returns>
protected bool IsValidAddress(string address)
{
//If address is required then make sure it can be parsed.
if (!string.IsNullOrEmpty(address))
{
if (!IPAddress.TryParse(address, out IPAddress result))
{
return false;
}
else
{
return true;
}
}
else
{
return false;
}
}
/// <summary>
/// Sends data over the steamConnection.
/// </summary>
/// <param name="steamConnection"></param>
/// <param name="segment"></param>
/// <param name="channelId"></param>
/// <returns></returns>
protected Result Send(Connection conn, ArraySegment<byte> segment, byte channelId)
{
/* Have to resize array to include channel index
* if array isn't large enough to fit it. This is because
* we don't know what channel data comes in on so
* the channel has to be packed into the data sent.
* Odds of the array having to resize are extremely low
* so while this is not ideal, it's still very low risk. */
if ((segment.Array.Length - 1) <= (segment.Offset + segment.Count))
{
byte[] arr = segment.Array;
Array.Resize(ref arr, arr.Length + 1);
arr[arr.Length - 1] = channelId;
}
//If large enough just increase the segment and set the channel byte.
else
{
segment.Array[segment.Offset + segment.Count] = channelId;
}
//Make a new segment so count is right.
segment = new ArraySegment<byte>(segment.Array, segment.Offset, segment.Count + 1);
GCHandle pinnedArray = GCHandle.Alloc(segment.Array, GCHandleType.Pinned);
IntPtr pData = pinnedArray.AddrOfPinnedObject() + segment.Offset;
SendType sendFlag = (channelId == (byte)Channel.Unreliable) ? SendType.Unreliable : SendType.Reliable;
Result result = conn.SendMessage(pData, segment.Count, sendFlag);
if (result != Result.OK)
{
if (Transport.NetworkManager.CanLog(LoggingType.Warning))
Debug.LogWarning($"Send issue: {result}");
}
pinnedArray.Free();
return result;
}
/// <summary>
/// Returns a message from the steam network.
/// </summary>
/// <param name="ptr"></param>
/// <param name="buffer"></param>
/// <returns></returns>
protected (byte[], int) ProcessMessage(IntPtr ptrs, int size)
{
byte[] managedArray = new byte[size];
Marshal.Copy(ptrs, managedArray, 0, size);
int channel = managedArray[managedArray.Length - 1];
Array.Resize(ref managedArray, managedArray.Length - 1);
return (managedArray, channel);
}
}
}
#endif

View File

@ -1,11 +0,0 @@
fileFormatVersion: 2
guid: 3bc85d49720cf5844bf19af677e4f5f5
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,12 +0,0 @@
using Steamworks;
using System;
public class FishyConnectionManager : ConnectionManager
{
public Action<IntPtr, int> ForwardMessage;
public override void OnMessage(IntPtr data, int size, long messageNum, long recvTime, int channel)
{
ForwardMessage(data, size);
}
}

View File

@ -1,11 +0,0 @@
fileFormatVersion: 2
guid: 4200e3c1bd9ce214baf0cc323ef78429
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,13 +0,0 @@
using Steamworks;
using Steamworks.Data;
using System;
public class FishySocketManager : SocketManager
{
public Action<Connection, IntPtr, int> ForwardMessage;
public override void OnMessage(Connection connection, NetIdentity identity, IntPtr data, int size, long messageNum, long recvTime, int channel)
{
ForwardMessage(connection, data, size);
}
}

View File

@ -1,11 +0,0 @@
fileFormatVersion: 2
guid: 1180bddcdfeaad44e80261cedd2b806d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,25 +0,0 @@
using FishNet.Utility.Performance;
using System;
namespace FishyFacepunch
{
internal struct LocalPacket
{
public byte[] Data;
public int Length;
public byte Channel;
public LocalPacket(ArraySegment<byte> data, byte channel)
{
Data = ByteArrayPool.Retrieve(data.Count);
Length = data.Count;
Buffer.BlockCopy(data.Array, data.Offset, Data, 0, Length);
Channel = channel;
}
public void Dispose()
{
if (Data != null)
ByteArrayPool.Store(Data);
}
}
}

View File

@ -1,11 +0,0 @@
fileFormatVersion: 2
guid: c1e0f33bdfade44489a2decb96d23c72
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,425 +0,0 @@
#if !FishyFacepunch
using FishNet.Managing.Logging;
using FishNet.Transporting;
using FishyFacepunch.Client;
using Steamworks;
using Steamworks.Data;
using System;
using System.Collections.Generic;
using UnityEngine;
namespace FishyFacepunch.Server
{
public class ServerSocket : CommonSocket
{
#region Public.
/// <summary>
/// Gets the current ConnectionState of a remote client on the server.
/// </summary>
/// <param name="connectionId">ConnectionId to get ConnectionState for.</param>
internal RemoteConnectionState GetConnectionState(int connectionId)
{
//Remote clients can only have Started or Stopped states since we cannot know in between.
if (_steamConnections.Second.ContainsKey(connectionId))
return RemoteConnectionState.Started;
else
return RemoteConnectionState.Stopped;
}
#endregion
#region Private.
/// <summary>
/// SteamConnections for ConnectionIds.
/// </summary>
private BidirectionalDictionary<Connection, int> _steamConnections = new BidirectionalDictionary<Connection, int>();
/// <summary>
/// SteamIds for ConnectionIds.
/// </summary>
private BidirectionalDictionary<SteamId, int> _steamIds = new BidirectionalDictionary<SteamId, int>();
/// <summary>
/// Maximum number of remote connections.
/// </summary>
private int _maximumClients;
/// <summary>
/// Next Id to use for a connection.
/// </summary>
private int _nextConnectionId;
/// <summary>
/// Socket for the connection.
/// </summary>
private FishySocketManager _socket;
/// <summary>
/// ConnectionIds which can be reused.
/// </summary>
private Queue<int> _cachedConnectionIds = new Queue<int>();
/// <summary>
/// Contains state of the client host. True is started, false is stopped.
/// </summary>
private bool _clientHostStarted = false;
/// <summary>
/// Packets received from local client.
/// </summary>
private Queue<LocalPacket> _clientHostIncoming = new Queue<LocalPacket>();
/// <summary>
/// Socket for client host. Will be null if not being used.
/// </summary>
private ClientHostSocket _clientHost;
#endregion
/// <summary>
/// Initializes this for use.
/// </summary>
/// <param name="t"></param>
internal override void Initialize(Transport t)
{
base.Initialize(t);
}
/// <summary>
/// Resets the socket if invalid.
/// </summary>
internal void ResetInvalidSocket()
{
/* Force connection state to stopped if listener is invalid.
* Not sure if steam may change this internally so better
* safe than sorry and check before trying to connect
* rather than being stuck in the incorrect state. */
if (_socket == default)
base.SetLocalConnectionState(LocalConnectionState.Stopped, true);
}
/// <summary>
/// Starts the server.
/// </summary>
internal bool StartConnection(string address, ushort port, int maximumClients)
{
SteamNetworkingSockets.OnConnectionStatusChanged += OnRemoteConnectionState;
SetMaximumClients(maximumClients);
_nextConnectionId = 0;
_cachedConnectionIds.Clear();
base.SetLocalConnectionState(LocalConnectionState.Starting, true);
if (_socket != null)
{
_socket?.Close();
_socket = default;
}
#if UNITY_SERVER
_socket = SteamNetworkingSockets.CreateNormalSocket<FishySocketManager>(NetAddress.From(address, port));
#else
_socket = SteamNetworkingSockets.CreateRelaySocket<FishySocketManager>();
#endif
_socket.ForwardMessage = OnMessageReceived;
base.SetLocalConnectionState(LocalConnectionState.Started, true);
return true;
}
/// <summary>
/// Stops the local socket.
/// </summary>
internal bool StopConnection()
{
if (base.GetLocalConnectionState() == LocalConnectionState.Stopped)
return false;
base.SetLocalConnectionState(LocalConnectionState.Stopping, true);
if (_socket != null)
{
SteamNetworkingSockets.OnConnectionStatusChanged -= OnRemoteConnectionState;
_socket?.Close();
_socket = default;
}
base.SetLocalConnectionState(LocalConnectionState.Stopped, true);
return true;
}
/// <summary>
/// Stops a remote client from the server, disconnecting the client.
/// </summary>
/// <param name="connectionId">ConnectionId of the client to disconnect.</param>
internal bool StopConnection(int connectionId)
{
if (connectionId == FishyFacepunch.CLIENT_HOST_ID)
{
if (_clientHost != null)
{
_clientHost.StopConnection();
return true;
}
else
{
return false;
}
}
else
{
if (_steamConnections.Second.TryGetValue(connectionId, out Connection steamConn))
{
return StopConnection(connectionId, steamConn);
}
else
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"Steam connection not found for connectionId {connectionId}.");
return false;
}
}
}
/// <summary>
/// Stops a remote client from the server, disconnecting the client.
/// </summary>
/// <param name="connectionId"></param>
/// <param name="socket"></param>
private bool StopConnection(int connectionId, Connection socket)
{
socket.Close(false, 0, "Graceful disconnect");
_steamConnections.Remove(connectionId);
_steamIds.Remove(connectionId);
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Client with ConnectionID {connectionId} disconnected.");
base.Transport.HandleRemoteConnectionState(new RemoteConnectionStateArgs(RemoteConnectionState.Stopped, connectionId, Transport.Index));
_cachedConnectionIds.Enqueue(connectionId);
return true;
}
/// <summary>
/// Called when a remote connection state changes.
/// </summary>
private void OnRemoteConnectionState(Connection conn, ConnectionInfo info)
{
ulong clientSteamID = info.Identity.SteamId;
if (info.State == ConnectionState.Connecting)
{
if (_steamConnections.Count >= _maximumClients)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Incoming connection {clientSteamID} was rejected because would exceed the maximum connection count.");
conn.Close(false, 0, "Max Connection Count");
return;
}
Result res;
if ((res = conn.Accept()) == Result.OK)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Accepting connection {clientSteamID}");
}
else
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Connection {clientSteamID} could not be accepted: {res.ToString()}");
}
}
else if (info.State == ConnectionState.Connected)
{
int connectionId = (_cachedConnectionIds.Count > 0) ? _cachedConnectionIds.Dequeue() : _nextConnectionId++;
_steamConnections.Add(conn, connectionId);
_steamIds.Add(clientSteamID, connectionId);
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Client with SteamID {clientSteamID} connected. Assigning connection id {connectionId}");
base.Transport.HandleRemoteConnectionState(new RemoteConnectionStateArgs(RemoteConnectionState.Started, connectionId, Transport.Index));
}
else if (info.State == ConnectionState.ClosedByPeer || info.State == ConnectionState.ProblemDetectedLocally)
{
if (_steamConnections.TryGetValue(conn, out int connId))
{
StopConnection(connId, conn);
}
}
else
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Connection {clientSteamID} state changed: {info.State.ToString()}");
}
}
/// <summary>
/// Allows for Outgoing queue to be iterated.
/// </summary>
internal void IterateOutgoing()
{
if (base.GetLocalConnectionState() != LocalConnectionState.Started)
return;
foreach (Connection conn in _steamConnections.FirstTypes)
{
conn.Flush();
}
}
/// <summary>
/// Iterates the Incoming queue.
/// </summary>
/// <param name="transport"></param>
internal void IterateIncoming()
{
//Stopped or trying to stop.
if (base.GetLocalConnectionState() == LocalConnectionState.Stopped || base.GetLocalConnectionState() == LocalConnectionState.Stopping)
return;
//Iterate local client packets first.
while (_clientHostIncoming.Count > 0)
{
LocalPacket packet = _clientHostIncoming.Dequeue();
ArraySegment<byte> segment = new ArraySegment<byte>(packet.Data, 0, packet.Length);
base.Transport.HandleServerReceivedDataArgs(new ServerReceivedDataArgs(segment, (Channel)packet.Channel, FishyFacepunch.CLIENT_HOST_ID, Transport.Index));
packet.Dispose();
}
_socket.Receive(MAX_MESSAGES);
}
private void OnMessageReceived(Connection conn, IntPtr dataPtr, int size)
{
(byte[] data, int ch) = ProcessMessage(dataPtr, size);
base.Transport.HandleServerReceivedDataArgs(new ServerReceivedDataArgs(new ArraySegment<byte>(data), (Channel)ch, _steamConnections[conn], Transport.Index));
}
/// <summary>
/// Sends data to a client.
/// </summary>
/// <param name="channelId"></param>
/// <param name="segment"></param>
/// <param name="connectionId"></param>
internal void SendToClient(byte channelId, ArraySegment<byte> segment, int connectionId)
{
if (base.GetLocalConnectionState() != LocalConnectionState.Started)
return;
//Check if sending local client first, send and exit if so.
if (connectionId == FishyFacepunch.CLIENT_HOST_ID)
{
if (_clientHost != null)
{
LocalPacket packet = new LocalPacket(segment, channelId);
_clientHost.ReceivedFromLocalServer(packet);
}
return;
}
if (_steamConnections.TryGetValue(connectionId, out Connection steamConn))
{
Result res = base.Send(steamConn, segment, channelId);
if (res == Result.NoConnection || res == Result.InvalidParam)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Common))
Debug.Log($"Connection to {connectionId} was lost.");
StopConnection(connectionId, steamConn);
}
else if (res != Result.OK)
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"Could not send: {res.ToString()}");
}
}
else
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"ConnectionId {connectionId} does not exist, data will not be sent.");
}
}
/// <summary>
/// Gets the address of a remote connection Id.
/// </summary>
/// <param name="connectionId"></param>
/// <returns></returns>
internal string GetConnectionAddress(int connectionId)
{
if (_steamIds.TryGetValue(connectionId, out SteamId steamId))
{
return steamId.ToString();
}
else
{
if (base.Transport.NetworkManager.CanLog(LoggingType.Error))
Debug.LogError($"ConnectionId {connectionId} is invalid; address cannot be returned.");
return string.Empty;
}
}
/// <summary>
/// Sets maximum number of clients allowed to connect to the server. If applied at runtime and clients exceed this value existing clients will stay connected but new clients may not connect.
/// </summary>
/// <param name="value"></param>
internal void SetMaximumClients(int value)
{
_maximumClients = Math.Min(value, FishyFacepunch.CLIENT_HOST_ID - 1);
}
internal int GetMaximumClients()
{
return _maximumClients;
}
#region ClientHost (local client).
/// <summary>
/// Sets ClientHost value.
/// </summary>
/// <param name="socket"></param>
internal void SetClientHostSocket(ClientHostSocket socket)
{
_clientHost = socket;
}
/// <summary>
/// Called when the local client stops.
/// </summary>
internal void OnClientHostState(bool started)
{
_clientHostStarted = started;
FishyFacepunch ff = (FishyFacepunch)base.Transport;
SteamId steamId = new SteamId()
{
Value = ff.LocalUserSteamID
};
//If not started flush incoming from local client.
if (!started && _clientHostStarted)
{
base.ClearQueue(_clientHostIncoming);
base.Transport.HandleRemoteConnectionState(new RemoteConnectionStateArgs(RemoteConnectionState.Stopped, FishyFacepunch.CLIENT_HOST_ID, Transport.Index));
_steamIds.Remove(steamId);
}
//If started.
else if (started)
{
_steamIds[steamId] = FishyFacepunch.CLIENT_HOST_ID;
base.Transport.HandleRemoteConnectionState(new RemoteConnectionStateArgs(RemoteConnectionState.Started, FishyFacepunch.CLIENT_HOST_ID, Transport.Index));
}
_clientHostStarted = started;
}
/// <summary>
/// Queues a received packet from the local client.
/// </summary>
internal void ReceivedFromClientHost(LocalPacket packet)
{
if (!_clientHostStarted)
{
packet.Dispose();
return;
}
_clientHostIncoming.Enqueue(packet);
}
#endregion
}
}
#endif // !DISABLESTEAMWORKS

View File

@ -1,11 +0,0 @@
fileFormatVersion: 2
guid: a0f5d2e6e0da6a244a3fa589e4f6bba2
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,518 +0,0 @@
#if !FishyFacepunch
using FishNet.Managing;
using FishNet.Transporting;
using Steamworks;
using System;
using UnityEngine;
namespace FishyFacepunch
{
public class FishyFacepunch : Transport
{
~FishyFacepunch()
{
Shutdown();
}
#region Public.
[System.NonSerialized]
public ulong LocalUserSteamID;
#endregion
#region Serialized.
/// <summary>
/// Steam application Id.
/// </summary>
[Tooltip("Steam application Id.")]
[SerializeField]
private uint _steamAppID = 480;
[Header("Server")]
/// <summary>
/// Address server should bind to.
/// </summary>
[Tooltip("Address server should bind to.")]
[SerializeField]
private string _serverBindAddress = string.Empty;
/// <summary>
/// Port to use.
/// </summary>
[Tooltip("Port to use.")]
[SerializeField]
private ushort _port = 27015;
/// <summary>
/// Maximum number of players which may be connected at once.
/// </summary>
[Tooltip("Maximum number of players which may be connected at once.")]
[Range(1, ushort.MaxValue)]
[SerializeField]
private ushort _maximumClients = 16;
[Header("Client")]
/// <summary>
/// Address client should connect to.
/// </summary>
[Tooltip("Address client should connect to.")]
[SerializeField]
private string _clientAddress = string.Empty;
[Tooltip("Timeout for connecting in seconds.")]
[SerializeField]
private int _timeout = 25;
#endregion
#region Private.
/// <summary>
/// MTUs for each channel.
/// </summary>
private int[] _mtus;
/// <summary>
/// Client for the transport.
/// </summary>
private Client.ClientSocket _client = new Client.ClientSocket();
/// <summary>
/// Client when acting as host.
/// </summary>
private Client.ClientHostSocket _clientHost = new Client.ClientHostSocket();
/// <summary>
/// Server for the transport.
/// </summary>
private Server.ServerSocket _server = new Server.ServerSocket();
#endregion
#region Const.
/// <summary>
/// Id to use for client when acting as host.
/// </summary>
internal const int CLIENT_HOST_ID = short.MaxValue;
#endregion
#region Initialization and Unity.
public override void Initialize(NetworkManager networkManager, int transportIndex)
{
base.Initialize(networkManager, transportIndex);
CreateChannelData();
#if !UNITY_SERVER
SteamClient.Init(_steamAppID, true);
SteamNetworking.AllowP2PPacketRelay(true);
#endif
_clientHost.Initialize(this);
_client.Initialize(this);
_server.Initialize(this);
}
private void OnDestroy()
{
Shutdown();
}
private void Update()
{
_clientHost.CheckSetStarted();
}
#endregion
#region Setup.
/// <summary>
/// Creates ChannelData for the transport.
/// </summary>
private void CreateChannelData()
{
_mtus = new int[2]
{
1048576,
1200
};
}
/// <summary>
/// Tries to initialize steam network access.
/// </summary>
private void InitializeRelayNetworkAccess()
{
#if !UNITY_SERVER
SteamNetworkingUtils.InitRelayNetworkAccess();
LocalUserSteamID = Steamworks.SteamClient.SteamId.Value;
#endif
}
#endregion
#region ConnectionStates.
/// <summary>
/// Gets the IP address of a remote connection Id.
/// </summary>
/// <param name="connectionId"></param>
/// <returns></returns>
public override string GetConnectionAddress(int connectionId)
{
return _server.GetConnectionAddress(connectionId);
}
/// <summary>
/// Called when a connection state changes for the local client.
/// </summary>
public override event Action<ClientConnectionStateArgs> OnClientConnectionState;
/// <summary>
/// Called when a connection state changes for the local server.
/// </summary>
public override event Action<ServerConnectionStateArgs> OnServerConnectionState;
/// <summary>
/// Called when a connection state changes for a remote client.
/// </summary>
public override event Action<RemoteConnectionStateArgs> OnRemoteConnectionState;
/// <summary>
/// Gets the current local ConnectionState.
/// </summary>
/// <param name="server">True if getting ConnectionState for the server.</param>
public override LocalConnectionState GetConnectionState(bool server)
{
if (server)
return _server.GetLocalConnectionState();
else
return _client.GetLocalConnectionState();
}
/// <summary>
/// Gets the current ConnectionState of a remote client on the server.
/// </summary>
/// <param name="connectionId">ConnectionId to get ConnectionState for.</param>
public override RemoteConnectionState GetConnectionState(int connectionId)
{
return _server.GetConnectionState(connectionId);
}
/// <summary>
/// Handles a ConnectionStateArgs for the local client.
/// </summary>
/// <param name="connectionStateArgs"></param>
public override void HandleClientConnectionState(ClientConnectionStateArgs connectionStateArgs)
{
OnClientConnectionState?.Invoke(connectionStateArgs);
}
/// <summary>
/// Handles a ConnectionStateArgs for the local server.
/// </summary>
/// <param name="connectionStateArgs"></param>
public override void HandleServerConnectionState(ServerConnectionStateArgs connectionStateArgs)
{
OnServerConnectionState?.Invoke(connectionStateArgs);
}
/// <summary>
/// Handles a ConnectionStateArgs for a remote client.
/// </summary>
/// <param name="connectionStateArgs"></param>
public override void HandleRemoteConnectionState(RemoteConnectionStateArgs connectionStateArgs)
{
OnRemoteConnectionState?.Invoke(connectionStateArgs);
}
#endregion
#region Iterating.
/// <summary>
/// Processes data received by the socket.
/// </summary>
/// <param name="server">True to process data received on the server.</param>
public override void IterateIncoming(bool server)
{
if (server)
{
_server.IterateIncoming();
}
else
{
_client.IterateIncoming();
_clientHost.IterateIncoming();
}
}
/// <summary>
/// Processes data to be sent by the socket.
/// </summary>
/// <param name="server">True to process data received on the server.</param>
public override void IterateOutgoing(bool server)
{
if (server)
_server.IterateOutgoing();
else
_client.IterateOutgoing();
}
#endregion
#region ReceivedData.
/// <summary>
/// Called when client receives data.
/// </summary>
public override event Action<ClientReceivedDataArgs> OnClientReceivedData;
/// <summary>
/// Handles a ClientReceivedDataArgs.
/// </summary>
/// <param name="receivedDataArgs"></param>
public override void HandleClientReceivedDataArgs(ClientReceivedDataArgs receivedDataArgs)
{
OnClientReceivedData?.Invoke(receivedDataArgs);
}
/// <summary>
/// Called when server receives data.
/// </summary>
public override event Action<ServerReceivedDataArgs> OnServerReceivedData;
/// <summary>
/// Handles a ClientReceivedDataArgs.
/// </summary>
/// <param name="receivedDataArgs"></param>
public override void HandleServerReceivedDataArgs(ServerReceivedDataArgs receivedDataArgs)
{
OnServerReceivedData?.Invoke(receivedDataArgs);
}
#endregion
#region Sending.
/// <summary>
/// Sends to the server or all clients.
/// </summary>
/// <param name="channelId">Channel to use.</param>
/// /// <param name="segment">Data to send.</param>
public override void SendToServer(byte channelId, ArraySegment<byte> segment)
{
_client.SendToServer(channelId, segment);
_clientHost.SendToServer(channelId, segment);
}
/// <summary>
/// Sends data to a client.
/// </summary>
/// <param name="channelId"></param>
/// <param name="segment"></param>
/// <param name="connectionId"></param>
public override void SendToClient(byte channelId, ArraySegment<byte> segment, int connectionId)
{
_server.SendToClient(channelId, segment, connectionId);
}
#endregion
#region Configuration.
/// <summary>
/// Returns the maximum number of clients allowed to connect to the server. If the transport does not support this method the value -1 is returned.
/// </summary>
/// <returns></returns>
public override int GetMaximumClients()
{
return _server.GetMaximumClients();
}
/// <summary>
/// Sets maximum number of clients allowed to connect to the server. If applied at runtime and clients exceed this value existing clients will stay connected but new clients may not connect.
/// </summary>
/// <param name="value"></param>
public override void SetMaximumClients(int value)
{
_server.SetMaximumClients(value);
}
/// <summary>
/// Sets which address the client will connect to.
/// </summary>
/// <param name="address"></param>
public override void SetClientAddress(string address)
{
_clientAddress = address;
}
public override void SetServerBindAddress(string address, IPAddressType addressType)
{
_serverBindAddress = address;
}
/// <summary>
/// Sets which port to use.
/// </summary>
/// <param name="port"></param>
public override void SetPort(ushort port)
{
_port = port;
}
/// <summary>
/// Returns the adjusted timeout as float
/// </summary>
/// <param name="asServer"></param>
public override float GetTimeout(bool asServer)
{
return _timeout;
}
#endregion
#region Start and stop.
/// <summary>
/// Starts the local server or client using configured settings.
/// </summary>
/// <param name="server">True to start server.</param>
public override bool StartConnection(bool server)
{
Debug.Log("StartConnection fishy server: " + server);
if (server)
return StartServer();
else
return StartClient(_clientAddress);
}
/// <summary>
/// Stops the local server or client.
/// </summary>
/// <param name="server">True to stop server.</param>
public override bool StopConnection(bool server)
{
if (server)
return StopServer();
else
return StopClient();
}
/// <summary>
/// Stops a remote client from the server, disconnecting the client.
/// </summary>
/// <param name="connectionId">ConnectionId of the client to disconnect.</param>
/// <param name="immediately">True to abrutly stp the client socket without waiting socket thread.</param>
public override bool StopConnection(int connectionId, bool immediately)
{
return StopClient(connectionId, immediately);
}
/// <summary>
/// Stops both client and server.
/// </summary>
public override void Shutdown()
{
//Stops client then server connections.
StopConnection(false);
StopConnection(true);
}
#region Privates.
/// <summary>
/// Starts server.
/// </summary>
/// <returns>True if there were no blocks. A true response does not promise a socket will or has connected.</returns>
private bool StartServer()
{
bool clientRunning = false;
#if !UNITY_SERVER
if (!SteamClient.IsValid)
{
Debug.LogError("Steam Facepunch not initialized. Server could not be started.");
return false;
}
//if (_client.GetLocalConnectionState() != LocalConnectionState.Stopped)
//{
// Debug.LogError("Server cannot run while client is running.");
// return false;
//}
clientRunning = (_client.GetLocalConnectionState() != LocalConnectionState.Stopped);
/* If remote _client is running then stop it
* and start the client host variant. */
if (clientRunning)
_client.StopConnection();
#endif
_server.ResetInvalidSocket();
if (_server.GetLocalConnectionState() != LocalConnectionState.Stopped)
{
Debug.LogError("Server is already running.");
return false;
}
InitializeRelayNetworkAccess();
bool result = _server.StartConnection(_serverBindAddress, _port, _maximumClients);
//If need to restart client.
if (result && clientRunning)
StartConnection(false);
return result;
}
/// <summary>
/// Stops server.
/// </summary>
private bool StopServer()
{
return _server.StopConnection();
}
/// <summary>
/// Starts the client.
/// </summary>
/// <param name="address"></param>
/// <returns>True if there were no blocks. A true response does not promise a socket will or has connected.</returns>
private bool StartClient(string address)
{
if (!SteamClient.IsValid)
{
Debug.LogError("Steam Facepunch not initialized. Client could not be started.");
return false;
}
//If not acting as a host.
if (_server.GetLocalConnectionState() == LocalConnectionState.Stopped)
{
if (_client.GetLocalConnectionState() != LocalConnectionState.Stopped)
{
Debug.LogError("Client is already running.");
return false;
}
//Stop client host if running.
if (_clientHost.GetLocalConnectionState() != LocalConnectionState.Stopped)
_clientHost.StopConnection();
//Initialize.
InitializeRelayNetworkAccess();
_client.StartConnection(address, _port);
}
//Acting as host.
else
{
_clientHost.StartConnection(_server);
}
return true;
}
/// <summary>
/// Stops the client.
/// </summary>
private bool StopClient()
{
bool result = false;
result |= _client.StopConnection();
result |= _clientHost.StopConnection();
return result;
}
/// <summary>
/// Stops a remote client on the server.
/// </summary>
/// <param name="connectionId"></param>
/// <param name="immediately">True to abrutly stp the client socket without waiting socket thread.</param>
private bool StopClient(int connectionId, bool immediately)
{
return _server.StopConnection(connectionId);
}
#endregion
#endregion
#region Channels.
/// <summary>
/// Gets the MTU for a channel. This should take header size into consideration.
/// For example, if MTU is 1200 and a packet header for this channel is 10 in size, this method should return 1190.
/// </summary>
/// <param name="channel"></param>
/// <returns></returns>
public override int GetMTU(byte channel)
{
if (channel >= _mtus.Length)
{
Debug.LogError($"Channel {channel} is out of bounds.");
return 0;
}
return _mtus[channel];
}
#endregion
}
}
#endif // !DISABLESTEAMWORKS

View File

@ -1,11 +0,0 @@
fileFormatVersion: 2
guid: 9da90c29836670c49809661c5c09cd5d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1 +0,0 @@
2.1.1

View File

@ -1,81 +0,0 @@
fileFormatVersion: 2
guid: fc89a528dd38bd04a90af929e9c0f80e
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
: Any
second:
enabled: 0
settings:
Exclude Editor: 0
Exclude Linux64: 0
Exclude OSXUniversal: 0
Exclude Win: 1
Exclude Win64: 1
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 1
settings:
CPU: AnyCPU
DefaultValueInitialized: true
OS: OSX
- first:
Facebook: Win
second:
enabled: 0
settings:
CPU: None
- first:
Facebook: Win64
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Linux64
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: OSXUniversal
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: Win
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win64
second:
enabled: 0
settings:
CPU: None
- first:
Windows Store Apps: WindowsStoreApps
second:
enabled: 0
settings:
CPU: AnyCPU
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: f13b7820b3a9b6145a8ea48a92291748
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,81 +0,0 @@
fileFormatVersion: 2
guid: fb41692bc4208c0449c96c0576331408
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
'': Any
second:
enabled: 0
settings:
Exclude Editor: 0
Exclude Linux64: 1
Exclude OSXUniversal: 1
Exclude Win: 0
Exclude Win64: 1
- first:
Any:
second:
enabled: 1
settings: {}
- first:
Editor: Editor
second:
enabled: 1
settings:
CPU: x86
DefaultValueInitialized: true
OS: Windows
- first:
Facebook: Win
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Facebook: Win64
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Linux64
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: OSXUniversal
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: Win64
second:
enabled: 0
settings:
CPU: None
- first:
Windows Store Apps: WindowsStoreApps
second:
enabled: 0
settings:
CPU: AnyCPU
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: 1c9eb7c3219a16948b7520dc7026cf20
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,95 +0,0 @@
fileFormatVersion: 2
guid: b3ad7ccc15f481747842885a21b7b4ab
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
'': Any
second:
enabled: 0
settings:
Exclude Editor: 0
Exclude Linux: 1
Exclude Linux64: 1
Exclude LinuxUniversal: 1
Exclude OSXUniversal: 1
Exclude Win: 1
Exclude Win64: 0
- first:
Any:
second:
enabled: 1
settings: {}
- first:
Editor: Editor
second:
enabled: 1
settings:
CPU: x86_64
DefaultValueInitialized: true
OS: Windows
- first:
Facebook: Win
second:
enabled: 0
settings:
CPU: None
- first:
Facebook: Win64
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Standalone: Linux
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Linux64
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: LinuxUniversal
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: OSXUniversal
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win64
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Windows Store Apps: WindowsStoreApps
second:
enabled: 0
settings:
CPU: AnyCPU
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +0,0 @@
fileFormatVersion: 2
guid: ea452b431085aed499c01339e89fce8b
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,89 +0,0 @@
fileFormatVersion: 2
guid: fd99b19e202e95a44ace17e10bac2feb
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
'': Any
second:
enabled: 0
settings:
Exclude Editor: 1
Exclude Linux: 1
Exclude Linux64: 1
Exclude LinuxUniversal: 1
Exclude OSXUniversal: 1
Exclude Win: 1
Exclude Win64: 1
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
CPU: AnyCPU
DefaultValueInitialized: true
OS: AnyOS
- first:
Facebook: Win
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Facebook: Win64
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Standalone: Linux
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Linux64
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: LinuxUniversal
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: OSXUniversal
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Standalone: Win64
second:
enabled: 0
settings:
CPU: AnyCPU
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,89 +0,0 @@
fileFormatVersion: 2
guid: a3b75fd2a03fb3149b60c2040555c3fe
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
'': Any
second:
enabled: 0
settings:
Exclude Editor: 0
Exclude Linux: 1
Exclude Linux64: 0
Exclude LinuxUniversal: 0
Exclude OSXUniversal: 1
Exclude Win: 0
Exclude Win64: 0
- first:
Any:
second:
enabled: 1
settings: {}
- first:
Editor: Editor
second:
enabled: 1
settings:
CPU: x86_64
DefaultValueInitialized: true
OS: Linux
- first:
Facebook: Win
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Facebook: Win64
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Standalone: Linux
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Linux64
second:
enabled: 1
settings:
CPU: x86_64
- first:
Standalone: LinuxUniversal
second:
enabled: 1
settings:
CPU: x86_64
- first:
Standalone: OSXUniversal
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Win
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: Win64
second:
enabled: 1
settings:
CPU: AnyCPU
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,8 +0,0 @@
fileFormatVersion: 2
guid: 93319165ca0834f41b428adbdad19105
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,32 +0,0 @@
fileFormatVersion: 2
guid: 7d6647fb9d80f5b4f9b2ff1378756bee
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 1
settings:
DefaultValueInitialized: true
- first:
Standalone: OSXUniversal
second:
enabled: 1
settings: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,89 +0,0 @@
fileFormatVersion: 2
guid: f47308500f9b7734392a75ff281c7457
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
: Any
second:
enabled: 0
settings:
Exclude Editor: 0
Exclude Linux: 0
Exclude Linux64: 0
Exclude LinuxUniversal: 0
Exclude OSXUniversal: 0
Exclude Win: 0
Exclude Win64: 1
- first:
Any:
second:
enabled: 1
settings: {}
- first:
Editor: Editor
second:
enabled: 1
settings:
CPU: x86
DefaultValueInitialized: true
OS: Windows
- first:
Facebook: Win
second:
enabled: 0
settings:
CPU: AnyCPU
- first:
Facebook: Win64
second:
enabled: 0
settings:
CPU: None
- first:
Standalone: Linux
second:
enabled: 1
settings:
CPU: x86
- first:
Standalone: Linux64
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: LinuxUniversal
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: OSXUniversal
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: Win
second:
enabled: 1
settings:
CPU: AnyCPU
- first:
Standalone: Win64
second:
enabled: 0
settings:
CPU: None
userData:
assetBundleName:
assetBundleVariant:

View File

@ -12,7 +12,7 @@ PluginImporter:
validateReferences: 1
platformData:
- first:
'': Any
: Any
second:
enabled: 0
settings:
@ -59,7 +59,7 @@ PluginImporter:
second:
enabled: 1
settings:
CPU: x86_64
CPU: AnyCPU
- first:
Standalone: LinuxUniversal
second:

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 2b478e6d3d1ef9848b43453c8e68cd0d
guid: c9d00fbba9a42474abd74966db59e463
folderAsset: yes
DefaultImporter:
externalObjects: {}

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: c11e7223b052ece4cbb66d2cf012cb04
guid: 8e3d6d5626a422a4ba9855d0453dc8ec
folderAsset: yes
DefaultImporter:
externalObjects: {}

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: fc9c8228eea0edc4eb3428086998d364
guid: 45ac0e53d32d2934daf1ebf18e9b541c
folderAsset: yes
DefaultImporter:
externalObjects: {}

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: ce9561d2de976e74684ab44c5fec0813
guid: a8a3bb549ad2ff847bd4d70cca0067b9
folderAsset: yes
DefaultImporter:
externalObjects: {}

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: bf67a0fffab71f44289e46ca401be348
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: cbcc7df99e935724e9ce1ab1461416cb
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 246f31a0e00fea74a93125fec6d80da8
guid: 7fb5399c2d56f4d4da19cf33f8c8fcb3
DefaultImporter:
externalObjects: {}
userData:

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 3f09f612b141fac49a5d7d05b4d3c044
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 3ffd5813d91aefd459583d77d2e49ddd
guid: 8b5047bd7da93dc41b54a06db904f57f
DefaultImporter:
externalObjects: {}
userData:

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: f5e5cee01870f6649abd156a37da40c0
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 96a44475794fb6445a6f3c4b9ee13966
guid: 907d68f5e20897c48b082e585980c1a6
DefaultImporter:
externalObjects: {}
userData:

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 3adb407f35958864bac4e884dbf3836f
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,57 @@
#if HE_SYSCORE && (STEAMWORKSNET || FACEPUNCH) && !DISABLESTEAMWORKS
using HeathenEngineering.SteamworksIntegration;
using System;
using UnityEngine;
namespace HeathenEngineering.DEMO
{
/// <summary>
/// This is for demonstration purposes only
/// </summary>
[System.Obsolete("This script is for demonstration purposes ONLY")]
public class MarketingButtons : MonoBehaviour
{
public string[] urls;
public void LeaveAReview()
{
Application.OpenURL("https://assetstore.unity.com/packages/tools/integration/steamworks-v2-complete-190316#reviews");
}
public void JoinDiscord()
{
Application.OpenURL("https://discord.gg/6X3xrRc");
}
public void UXComplete()
{
Application.OpenURL("https://assetstore.unity.com/packages/tools/utilities/ux-v2-complete-201905");
}
public void uGUIExtras()
{
Application.OpenURL("https://assetstore.unity.com/packages/2d/gui/ux-v2-ugui-extras-202542");
}
public void PhysKit()
{
Application.OpenURL("https://assetstore.unity.com/packages/tools/physics/physkit-complete-122368");
}
public void Anibone()
{
Application.OpenURL("https://assetstore.unity.com/packages/tools/physics/physkit-anibone-173686");
}
public void Containers()
{
Application.OpenURL("https://assetstore.unity.com/packages/3d/props/heathen-containers-volume-1-150587");
}
public void URLButtons(int index)
{
Application.OpenURL(urls[index]);
}
}
}
#endif

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 336587b490f535a4aa3b1618c9ebac55
guid: 5bdd5a47267624c4aa9704e196c77653
MonoImporter:
externalObjects: {}
serializedVersion: 2

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: bc2b676f83ba7cc4e85d06d51ab39822
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 71 KiB

View File

@ -0,0 +1,108 @@
fileFormatVersion: 2
guid: d08d39e01a25e6a4a8f8234d913dd6ee
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 11
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 1
wrapV: 1
wrapW: 0
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 826 KiB

View File

@ -0,0 +1,108 @@
fileFormatVersion: 2
guid: 23e7e2d720dd430498fb0753fb80f8af
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 11
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 1
wrapV: 1
wrapW: 0
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,33 @@
#if UNITY_EDITOR
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace OnlyInEditor
{
[Obsolete("This class is onyl for use in Editor and will not compile for builds")]
public class Heathen : MonoBehaviour
{
public void BecomeSponsor()
{
Application.OpenURL("https://kb.heathenengineering.com/company/concepts/become-a-sponsor");
}
public void JoinDiscord()
{
Application.OpenURL("https://discord.gg/6X3xrRc");
}
public void KnowledgeBase()
{
Application.OpenURL("https://kb.heathenengineering.com/company/introduction");
}
public void OpenWebPage(string url)
{
Application.OpenURL(url);
}
}
}
#endif

View File

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 112bec8b5281832468d85543d0b6e31c
guid: 38418a9aefe04ab40b13f8f7934a09f6
MonoImporter:
externalObjects: {}
serializedVersion: 2

View File

@ -0,0 +1,854 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &7863141757382039312
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7863141757382039311}
- component: {fileID: 7863141757382039308}
- component: {fileID: 7863141757382039309}
- component: {fileID: 7863141757382039310}
m_Layer: 5
m_Name: Discord Button
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7863141757382039311
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757382039312}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 7863141758081882914}
m_Father: {fileID: 7863141757599531660}
m_RootOrder: 2
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0}
m_AnchorMax: {x: 0.5, y: 0}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 200, y: 28}
m_Pivot: {x: 0, y: 0}
--- !u!222 &7863141757382039308
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757382039312}
m_CullTransparentMesh: 1
--- !u!114 &7863141757382039309
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757382039312}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 0.16869159, g: 0.7191589, b: 0.95, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0}
m_Type: 1
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &7863141757382039310
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757382039312}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 0.695, g: 0.9087402, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.28884003, g: 0.6676519, b: 0.83, a: 1}
m_SelectedColor: {r: 0.72030586, g: 0.8805856, b: 0.9490196, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 7863141758081882913}
m_OnClick:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 1136993166192167592}
m_TargetAssemblyTypeName: OnlyInEditor.Heathen, Heathen.Steamworks.Examples
m_MethodName: JoinDiscord
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
--- !u!1 &7863141757599531661
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7863141757599531660}
- component: {fileID: 1136993166192167592}
m_Layer: 5
m_Name: Heathen
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7863141757599531660
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757599531661}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 7863141758703160306}
- {fileID: 7863141759259949490}
- {fileID: 7863141757382039311}
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 1}
m_AnchorMax: {x: 0.5, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 512, y: 128}
m_Pivot: {x: 0.5, y: 1}
--- !u!114 &1136993166192167592
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757599531661}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 38418a9aefe04ab40b13f8f7934a09f6, type: 3}
m_Name:
m_EditorClassIdentifier:
--- !u!1 &7863141757811621181
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7863141757811621180}
- component: {fileID: 7863141757811621178}
- component: {fileID: 7863141757811621179}
m_Layer: 5
m_Name: Text (TMP)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7863141757811621180
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757811621181}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 7863141759259949490}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &7863141757811621178
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757811621181}
m_CullTransparentMesh: 1
--- !u!114 &7863141757811621179
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141757811621181}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Knowledge Base
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4294967295
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 20
m_fontSizeBase: 20
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 2
m_VerticalAlignment: 512
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 1
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!1 &7863141758081882915
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7863141758081882914}
- component: {fileID: 7863141758081882912}
- component: {fileID: 7863141758081882913}
m_Layer: 5
m_Name: Text (TMP)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7863141758081882914
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758081882915}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 7863141757382039311}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &7863141758081882912
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758081882915}
m_CullTransparentMesh: 1
--- !u!114 &7863141758081882913
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758081882915}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Community
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4294967295
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 20
m_fontSizeBase: 20
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 2
m_VerticalAlignment: 512
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 1
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!1 &7863141758518367230
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7863141758518367229}
- component: {fileID: 7863141758518367227}
- component: {fileID: 7863141758518367228}
m_Layer: 5
m_Name: Text (TMP)
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7863141758518367229
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758518367230}
m_LocalRotation: {x: -0, y: -0, z: -0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 7863141758703160306}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 1, y: 0}
m_AnchorMax: {x: 1, y: 0}
m_AnchoredPosition: {x: -8.320007, y: 4.37}
m_SizeDelta: {x: 200, y: 28}
m_Pivot: {x: 1, y: 0}
--- !u!222 &7863141758518367227
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758518367230}
m_CullTransparentMesh: 1
--- !u!114 &7863141758518367228
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758518367230}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: (click to learn more)
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4294967295
m_fontColor: {r: 1, g: 1, b: 1, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 12
m_fontSizeBase: 12
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 4
m_VerticalAlignment: 1024
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 1
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!1 &7863141758703160307
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7863141758703160306}
- component: {fileID: 7863141758703160303}
- component: {fileID: 7863141758703160304}
- component: {fileID: 7863141758703160305}
m_Layer: 5
m_Name: Sponsor Button
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7863141758703160306
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758703160307}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 7863141758518367229}
m_Father: {fileID: 7863141757599531660}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 1}
m_AnchorMax: {x: 0.5, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 410, y: 100}
m_Pivot: {x: 0.5, y: 1}
--- !u!222 &7863141758703160303
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758703160307}
m_CullTransparentMesh: 1
--- !u!114 &7863141758703160304
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758703160307}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 21300000, guid: d08d39e01a25e6a4a8f8234d913dd6ee, type: 3}
m_Type: 0
m_PreserveAspect: 1
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &7863141758703160305
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141758703160307}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 0.5295059, g: 0.79888374, b: 0.9098039, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.48297414, g: 0.72982764, b: 0.83, a: 1}
m_SelectedColor: {r: 0.5294118, g: 0.8000001, b: 0.909804, a: 1}
m_DisabledColor: {r: 0.5294118, g: 0.8000001, b: 0.909804, a: 1}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 7863141758518367228}
m_OnClick:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 1136993166192167592}
m_TargetAssemblyTypeName: OnlyInEditor.Heathen, Heathen.Steamworks.Examples
m_MethodName: BecomeSponsor
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
--- !u!1 &7863141759259949491
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7863141759259949490}
- component: {fileID: 7863141759259949487}
- component: {fileID: 7863141759259949488}
- component: {fileID: 7863141759259949489}
m_Layer: 5
m_Name: KB Button
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7863141759259949490
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141759259949491}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 7863141757811621180}
m_Father: {fileID: 7863141757599531660}
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0}
m_AnchorMax: {x: 0.5, y: 0}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 200, y: 28}
m_Pivot: {x: 1, y: 0}
--- !u!222 &7863141759259949487
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141759259949491}
m_CullTransparentMesh: 1
--- !u!114 &7863141759259949488
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141759259949491}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 0.16869159, g: 0.7191589, b: 0.95, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 10905, guid: 0000000000000000f000000000000000, type: 0}
m_Type: 1
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &7863141759259949489
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7863141759259949491}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 0.695, g: 0.9087402, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.28884003, g: 0.6676519, b: 0.83, a: 1}
m_SelectedColor: {r: 0.72030586, g: 0.8805856, b: 0.9490196, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 7863141757811621179}
m_OnClick:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 1136993166192167592}
m_TargetAssemblyTypeName: OnlyInEditor.Heathen, Heathen.Steamworks.Examples
m_MethodName: KnowledgeBase
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2

View File

@ -1,6 +1,6 @@
fileFormatVersion: 2
guid: 0957b521a08374f4aa508231735153bc
DefaultImporter:
guid: 19105e6f44b84e84386e3f41cbb1a369
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:

View File

@ -0,0 +1,16 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: c04e506a9118b4a4f9e72d5379724776, type: 3}
m_Name: New Int Variable
m_EditorClassIdentifier:
DeveloperDescription:
m_value: 0

View File

@ -1,7 +1,8 @@
fileFormatVersion: 2
guid: cf7010bd3b524434c8cefe4534247875
TextScriptImporter:
guid: da6ef3e4529873948a2d9047fda37ce9
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,39 @@
{
"name": "Heathen.Steamworks.Examples",
"rootNamespace": "",
"references": [
"GUID:68bd7fdb68ef2684e982e8a9825b18a5",
"GUID:58d42c70423577947911995925414405",
"GUID:3e1f55b641cbc824881f0d12f6a5c69a",
"GUID:6055be8ebefd69e48b49212b09b47b2f",
"GUID:d8b63aba1907145bea998dd612889d6b",
"GUID:30817c1a0e6d646d99c048fc403f5979",
"GUID:75469ad4d38634e559750d17036d5f7c"
],
"includePlatforms": [
"Editor",
"LinuxStandalone64",
"macOSStandalone",
"WindowsStandalone32",
"WindowsStandalone64"
],
"excludePlatforms": [],
"allowUnsafeCode": false,
"overrideReferences": false,
"precompiledReferences": [],
"autoReferenced": true,
"defineConstraints": [],
"versionDefines": [
{
"name": "com.heathen.systemcore",
"expression": "",
"define": "HE_SYSCORE"
},
{
"name": "com.rlabrecque.steamworks.net",
"expression": "",
"define": "STEAMWORKSNET"
}
],
"noEngineReferences": false
}

View File

@ -1,6 +1,6 @@
fileFormatVersion: 2
guid: 1db9d679a4e8b8d4c9d5ab6cb2d3ad0f
TextScriptImporter:
guid: 8bb244c20c538f24f9f43c2f02d160c3
AssemblyDefinitionImporter:
externalObjects: {}
userData:
assetBundleName:

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: c0bd55c25f5e6754b86e1c3a8b8b6414
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,239 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!114 &-5797971409039324458
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: bc250c6c93d29664697c63cee645dbdb, type: 3}
m_Name: '[Stat Int] NumLosses'
m_EditorClassIdentifier:
data:
id: NumLosses
--- !u!114 &-5779673662737521517
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: e1590c8affe9f884388e9c8c5bcf1697, type: 3}
m_Name: '[Ach] ACH_WIN_ONE_GAME'
m_EditorClassIdentifier:
data:
id: ACH_WIN_ONE_GAME
StatusChanged:
m_PersistentCalls:
m_Calls: []
--- !u!114 &-5696335151814961415
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: e1590c8affe9f884388e9c8c5bcf1697, type: 3}
m_Name: '[Ach] ACH_WIN_100_GAMES'
m_EditorClassIdentifier:
data:
id: ACH_WIN_100_GAMES
StatusChanged:
m_PersistentCalls:
m_Calls: []
--- !u!114 &-4069362907877233145
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: bc250c6c93d29664697c63cee645dbdb, type: 3}
m_Name: '[Stat Int] NumGames'
m_EditorClassIdentifier:
data:
id: NumGames
--- !u!114 &-3203211658084346776
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: e1590c8affe9f884388e9c8c5bcf1697, type: 3}
m_Name: '[Ach] NEW_ACHIEVEMENT_0_4'
m_EditorClassIdentifier:
data:
id: NEW_ACHIEVEMENT_0_4
StatusChanged:
m_PersistentCalls:
m_Calls: []
--- !u!114 &-2224319964784241432
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: bc250c6c93d29664697c63cee645dbdb, type: 3}
m_Name: '[Stat Int] Unused2'
m_EditorClassIdentifier:
data:
id: Unused2
--- !u!114 &-2066227864163758038
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: e1590c8affe9f884388e9c8c5bcf1697, type: 3}
m_Name: '[Ach] ACH_TRAVEL_FAR_SINGLE'
m_EditorClassIdentifier:
data:
id: ACH_TRAVEL_FAR_SINGLE
StatusChanged:
m_PersistentCalls:
m_Calls: []
--- !u!114 &11400000
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 242f29df75dec3d4cb1cbb74a477bee6, type: 3}
m_Name: Sample Steam Settings
m_EditorClassIdentifier:
applicationId:
m_AppId: 480
callbackTick_Milliseconds: 15
isDebugging: 1
server:
autoInitialize: 1
autoLogon: 1
ip: 0
queryPort: 27016
gamePort: 27015
serverVersion: 1.0.0.0
spectatorPort: 27017
usingGameServerAuthApi: 1
enableHeartbeats: 1
supportSpectators: 1
spectatorServerName: Usually GameDescription + Spectator
anonymousServerLogin: 1
gameServerToken: See https://steamcommunity.com/dev/managegameservers
isPasswordProtected: 0
serverName: My Server Name
gameDescription: Usually the name of your game
gameDirectory: e.g. its folder name
isDedicated: 1
maxPlayerCount: 4
botPlayerCount: 0
mapName:
gameData:
rulePairs: []
stats:
- {fileID: -4069362907877233145}
- {fileID: 8164444839112459042}
- {fileID: -5797971409039324458}
- {fileID: 7262114162419496264}
- {fileID: 8326798814440580138}
- {fileID: -2224319964784241432}
- {fileID: 5420587755674467353}
achievements:
- {fileID: 5940351223977467042}
- {fileID: -2066227864163758038}
- {fileID: -5696335151814961415}
- {fileID: -5779673662737521517}
- {fileID: -3203211658084346776}
--- !u!114 &5420587755674467353
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 3da81eb7de88c2c4197e3d17cb88b1bf, type: 3}
m_Name: '[Stat Float] MaxFeetTraveled'
m_EditorClassIdentifier:
data:
id: MaxFeetTraveled
--- !u!114 &5940351223977467042
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: e1590c8affe9f884388e9c8c5bcf1697, type: 3}
m_Name: '[Ach] ACH_TRAVEL_FAR_ACCUM'
m_EditorClassIdentifier:
data:
id: ACH_TRAVEL_FAR_ACCUM
StatusChanged:
m_PersistentCalls:
m_Calls: []
--- !u!114 &7262114162419496264
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 3da81eb7de88c2c4197e3d17cb88b1bf, type: 3}
m_Name: '[Stat Float] FeetTraveled'
m_EditorClassIdentifier:
data:
id: FeetTraveled
--- !u!114 &8164444839112459042
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: bc250c6c93d29664697c63cee645dbdb, type: 3}
m_Name: '[Stat Int] NumWins'
m_EditorClassIdentifier:
data:
id: NumWins
--- !u!114 &8326798814440580138
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 0}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 7f5e53cd2021f15408d8f5f874c30f2b, type: 3}
m_Name: '[Stat AvgRate] AverageSpeed'
m_EditorClassIdentifier:
data:
id: AverageSpeed

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 85f8a80ca92ce574b82c98a512eca71a
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 11400000
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 509f4677df1795c449cc9bed7b85ee53
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,91 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &1217920214110866490
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 6392570084957893904}
- component: {fileID: 6641314865204518477}
- component: {fileID: 2960048113241458836}
- component: {fileID: 8407897246163889810}
m_Layer: 5
m_Name: Friend Avatar
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &6392570084957893904
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1217920214110866490}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 1485, y: -252}
m_SizeDelta: {x: 100, y: 100}
m_Pivot: {x: 0, y: 1}
--- !u!222 &6641314865204518477
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1217920214110866490}
m_CullTransparentMesh: 0
--- !u!114 &2960048113241458836
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1217920214110866490}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 1344c3c82d62a2a41a3576d8abb8e3ea, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Texture: {fileID: 10309, guid: 0000000000000000f000000000000000, type: 0}
m_UVRect:
serializedVersion: 2
x: 0
y: 0
width: 1
height: 1
--- !u!114 &8407897246163889810
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 1217920214110866490}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 374f9a67d24a6c04fa9d36f0d53eb913, type: 3}
m_Name:
m_EditorClassIdentifier:
useLocalUser: 1
evtLoaded:
m_PersistentCalls:
m_Calls: []

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 9c9335b5793f05e41baf6763b4384f21
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: fdea0b1e95bf37e409855ead63b8d368
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: efeaa8d0524ccb241a002d1fd76c8401
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,151 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &7830710938773558372
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 7830710938773558373}
- component: {fileID: 7830710938773558368}
- component: {fileID: 7830710938773558371}
- component: {fileID: 7240856291406597348}
m_Layer: 5
m_Name: Friend Name
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &7830710938773558373
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7830710938773558372}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 1485, y: -431.36}
m_SizeDelta: {x: 200, y: 50}
m_Pivot: {x: 0, y: 1}
--- !u!222 &7830710938773558368
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7830710938773558372}
m_CullTransparentMesh: 0
--- !u!114 &7830710938773558371
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7830710938773558372}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: New Text
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4290903778
m_fontColor: {r: 0.8862746, g: 0.9960785, b: 0.7568628, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 36
m_fontSizeBase: 36
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 1
m_VerticalAlignment: 256
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 0
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 0
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &7240856291406597348
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 7830710938773558372}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 994e5162d4f6be349a21e9060437ebaf, type: 3}
m_Name:
m_EditorClassIdentifier:
useLocalUser: 1
showNickname: 1

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: d3dce6b26b53db84ebb9c5d09a6321c3
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: d839f647c4247d540b8a31b8284cf228
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,528 @@
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &8670648778821032871
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 8670648778821032864}
- component: {fileID: 8670648778821032866}
- component: {fileID: 8670648778821032865}
m_Layer: 5
m_Name: Text
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &8670648778821032864
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648778821032871}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 8670648780255253977}
m_RootOrder: 1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &8670648778821032866
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648778821032871}
m_CullTransparentMesh: 0
--- !u!114 &8670648778821032865
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648778821032871}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: "00000000\u200B"
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 4292736511
m_fontColor: {r: 1, g: 0.9600985, b: 0.865, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 30
m_fontSizeBase: 30
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 0
m_HorizontalAlignment: 1
m_VerticalAlignment: 256
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 0
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 1
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!1 &8670648778916277782
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 8670648778916277783}
- component: {fileID: 8670648778916277778}
- component: {fileID: 8670648778916277777}
- component: {fileID: 8670648778916277776}
m_Layer: 5
m_Name: Placeholder
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &8670648778916277783
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648778916277782}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children: []
m_Father: {fileID: 8670648780255253977}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 0, y: 0}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &8670648778916277778
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648778916277782}
m_CullTransparentMesh: 0
--- !u!114 &8670648778916277777
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648778916277782}
m_Enabled: 0
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: f4688fdb7df04437aeb418b961361dc5, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_text: Enter text...
m_isRightToLeft: 0
m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_fontSharedMaterials: []
m_fontMaterial: {fileID: 0}
m_fontMaterials: []
m_fontColor32:
serializedVersion: 2
rgba: 2150773298
m_fontColor: {r: 1, g: 0.9600985, b: 0.865, a: 1}
m_enableVertexGradient: 0
m_colorMode: 3
m_fontColorGradient:
topLeft: {r: 1, g: 1, b: 1, a: 1}
topRight: {r: 1, g: 1, b: 1, a: 1}
bottomLeft: {r: 1, g: 1, b: 1, a: 1}
bottomRight: {r: 1, g: 1, b: 1, a: 1}
m_fontColorGradientPreset: {fileID: 0}
m_spriteAsset: {fileID: 0}
m_tintAllSprites: 0
m_StyleSheet: {fileID: 0}
m_TextStyleHashCode: -1183493901
m_overrideHtmlColors: 0
m_faceColor:
serializedVersion: 2
rgba: 4294967295
m_fontSize: 30
m_fontSizeBase: 30
m_fontWeight: 400
m_enableAutoSizing: 0
m_fontSizeMin: 18
m_fontSizeMax: 72
m_fontStyle: 2
m_HorizontalAlignment: 1
m_VerticalAlignment: 256
m_textAlignment: 65535
m_characterSpacing: 0
m_wordSpacing: 0
m_lineSpacing: 0
m_lineSpacingMax: 0
m_paragraphSpacing: 0
m_charWidthMaxAdj: 0
m_enableWordWrapping: 0
m_wordWrappingRatios: 0.4
m_overflowMode: 0
m_linkedTextComponent: {fileID: 0}
parentLinkedComponent: {fileID: 0}
m_enableKerning: 1
m_enableExtraPadding: 1
checkPaddingRequired: 0
m_isRichText: 1
m_parseCtrlCharacters: 1
m_isOrthographic: 1
m_isCullingEnabled: 0
m_horizontalMapping: 0
m_verticalMapping: 0
m_uvLineOffset: 0
m_geometrySortingOrder: 0
m_IsTextObjectScaleStatic: 0
m_VertexBufferAutoSizeReduction: 0
m_useMaxVisibleDescender: 1
m_pageToDisplay: 1
m_margin: {x: 0, y: 0, z: 0, w: 0}
m_isUsingLegacyAnimationComponent: 0
m_isVolumetricText: 0
m_hasFontAssetChanged: 0
m_baseMaterial: {fileID: 0}
m_maskOffset: {x: 0, y: 0, z: 0, w: 0}
--- !u!114 &8670648778916277776
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648778916277782}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 306cc8c2b49d7114eaa3623786fc2126, type: 3}
m_Name:
m_EditorClassIdentifier:
m_IgnoreLayout: 1
m_MinWidth: -1
m_MinHeight: -1
m_PreferredWidth: -1
m_PreferredHeight: -1
m_FlexibleWidth: -1
m_FlexibleHeight: -1
m_LayoutPriority: 1
--- !u!1 &8670648780226315679
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 8670648780226315672}
- component: {fileID: 8670648780226315620}
- component: {fileID: 8670648780226315675}
- component: {fileID: 8670648780226315674}
- component: {fileID: 8670648780226315673}
m_Layer: 5
m_Name: Selectable Friend ID
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &8670648780226315672
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648780226315679}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 8670648780255253977}
m_Father: {fileID: 0}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 1}
m_AnchorMax: {x: 0, y: 1}
m_AnchoredPosition: {x: 1485, y: -525}
m_SizeDelta: {x: 160, y: 46.48}
m_Pivot: {x: 0, y: 1}
--- !u!222 &8670648780226315620
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648780226315679}
m_CullTransparentMesh: 0
--- !u!114 &8670648780226315675
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648780226315679}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 0.16470589, g: 0.16058823, b: 0.14823529, a: 1}
m_RaycastTarget: 1
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 10911, guid: 0000000000000000f000000000000000, type: 0}
m_Type: 1
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &8670648780226315674
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648780226315679}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 2da0c512f12947e489f739169773d7ca, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 1
m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 8670648780226315675}
m_TextViewport: {fileID: 8670648780255253977}
m_TextComponent: {fileID: 8670648778821032865}
m_Placeholder: {fileID: 8670648778916277777}
m_VerticalScrollbar: {fileID: 0}
m_VerticalScrollbarEventHandler: {fileID: 0}
m_LayoutGroup: {fileID: 0}
m_ScrollSensitivity: 1
m_ContentType: 0
m_InputType: 0
m_AsteriskChar: 42
m_KeyboardType: 0
m_LineType: 0
m_HideMobileInput: 0
m_HideSoftKeyboard: 0
m_CharacterValidation: 0
m_RegexValue:
m_GlobalPointSize: 30
m_CharacterLimit: 0
m_OnEndEdit:
m_PersistentCalls:
m_Calls: []
m_OnSubmit:
m_PersistentCalls:
m_Calls: []
m_OnSelect:
m_PersistentCalls:
m_Calls: []
m_OnDeselect:
m_PersistentCalls:
m_Calls: []
m_OnTextSelection:
m_PersistentCalls:
m_Calls: []
m_OnEndTextSelection:
m_PersistentCalls:
m_Calls: []
m_OnValueChanged:
m_PersistentCalls:
m_Calls: []
m_OnTouchScreenKeyboardStatusChanged:
m_PersistentCalls:
m_Calls: []
m_CaretColor: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1}
m_CustomCaretColor: 0
m_SelectionColor: {r: 0.5128767, g: 0.5898082, b: 0.624, a: 1}
m_Text: 00000000
m_CaretBlinkRate: 0.85
m_CaretWidth: 1
m_ReadOnly: 1
m_RichText: 1
m_GlobalFontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2}
m_OnFocusSelectAll: 1
m_ResetOnDeActivation: 1
m_RestoreOriginalTextOnEscape: 1
m_isRichTextEditingAllowed: 0
m_LineLimit: 0
m_InputValidator: {fileID: 0}
--- !u!114 &8670648780226315673
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648780226315679}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 9c7e79f6dff0ff341812d1f0fc22b624, type: 3}
m_Name:
m_EditorClassIdentifier:
useLocalUser: 1
--- !u!1 &8670648780255253976
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 8670648780255253977}
- component: {fileID: 8670648780255253978}
m_Layer: 5
m_Name: Text Area
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &8670648780255253977
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648780255253976}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_Children:
- {fileID: 8670648778916277783}
- {fileID: 8670648778821032864}
m_Father: {fileID: 8670648780226315672}
m_RootOrder: 0
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0, y: 0}
m_AnchorMax: {x: 1, y: 1}
m_AnchoredPosition: {x: 0, y: -0.5}
m_SizeDelta: {x: -20, y: -13}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!114 &8670648780255253978
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8670648780255253976}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 3312d7739989d2b4e91e6319e9a96d76, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Padding: {x: -8, y: -5, z: -8, w: -5}
m_Softness: {x: 0, y: 0}

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 84f046bb97c3d3b4cb108c4d1d6c36eb
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -133,6 +133,11 @@ GameObject:
m_Component:
- component: {fileID: 193945569}
- component: {fileID: 193945568}
- component: {fileID: 193945571}
- component: {fileID: 193945570}
- component: {fileID: 193945574}
- component: {fileID: 193945573}
- component: {fileID: 193945572}
m_Layer: 0
m_Name: NetworkManager
m_TagString: Untagged
@ -152,13 +157,13 @@ MonoBehaviour:
m_Script: {fileID: 11500000, guid: d2c95dfde7d73b54dbbdc23155d35d36, type: 3}
m_Name:
m_EditorClassIdentifier:
_refreshDefaultPrefabs: 0
_refreshDefaultPrefabs: 1
_runInBackground: 1
_dontDestroyOnLoad: 1
_objectPool: {fileID: 0}
_persistence: 0
_logging: {fileID: 0}
_spawnablePrefabs: {fileID: 0}
_spawnablePrefabs: {fileID: 11400000, guid: e6b71f999cc8fc647a3f73f7088802e0, type: 2}
--- !u!4 &193945569
Transform:
m_ObjectHideFlags: 0
@ -174,6 +179,95 @@ Transform:
m_Father: {fileID: 0}
m_RootOrder: 5
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!114 &193945570
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 193945567}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 9da90c29836670c49809661c5c09cd5d, type: 3}
m_Name:
m_EditorClassIdentifier:
_steamAppID: 480
_serverBindAddress:
_port: 27015
_maximumClients: 16
_clientAddress:
_timeout: 25
--- !u!114 &193945571
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 193945567}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 34e4a322dca349547989b14021da4e23, type: 3}
m_Name:
m_EditorClassIdentifier:
Transport: {fileID: 193945570}
_intermediateLayer: {fileID: 0}
_latencySimulator:
_enabled: 0
_simulateHost: 1
_latency: 0
_outOfOrder: 0
_packetLoss: 0
--- !u!114 &193945572
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 193945567}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 211a9f6ec51ddc14f908f5acc0cd0423, type: 3}
m_Name:
m_EditorClassIdentifier:
_playerPrefab: {fileID: 0}
_addToDefaultScene: 1
Spawns: []
--- !u!114 &193945573
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 193945567}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 7d331f979d46e8e4a9fc90070c596d44, type: 3}
m_Name:
m_EditorClassIdentifier:
_useNetworkLod: 0
_levelOfDetailDistances: []
_updateHostVisibility: 1
_defaultConditions: []
--- !u!114 &193945574
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 193945567}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 3fdaae44044276a49a52229c1597e33b, type: 3}
m_Name:
m_EditorClassIdentifier:
_updateOrder: 0
_timingType: 0
_allowTickDropping: 0
_maximumFrameTicks: 2
_tickRate: 30
_pingInterval: 1
_timingInterval: 2
_physicsMode: 0
--- !u!1 &240545134
GameObject:
m_ObjectHideFlags: 0
@ -572,6 +666,7 @@ MonoBehaviour:
m_PersistentCalls:
m_Calls: []
playerPrefab: {fileID: 365318977076093365, guid: 502609875cf67524391bcf30129c195b, type: 3}
NetworkManager: {fileID: 0}
--- !u!1 &963194225
GameObject:
m_ObjectHideFlags: 0

View File

@ -19,6 +19,7 @@ public class SteamLobbyWithPlayer : MonoBehaviour
public Dictionary<SteamId, GameObject> inLobby = new();
public GameObject playerPrefab;
public GameObject NetworkManager;
private void Start()
{
DontDestroyOnLoad(this);
@ -48,6 +49,7 @@ public class SteamLobbyWithPlayer : MonoBehaviour
Debug.Log($"{friend.Name} joined the lobby");
GameObject obj = Instantiate(playerPrefab, Vector3.zero, Quaternion.identity);
inLobby.Add(friend.Id, obj);
}
private void OnLobbyMemberDisconnected(Lobby lobby, Friend friend)
{

View File

@ -1,5 +1,6 @@
{
"dependencies": {
"com.heathen.steamworksfoundation": "https://github.com/heathen-engineering/SteamworksFoundation.git?path=Unity/com.heathen.steamworksfoundation",
"com.unity.cinemachine": "2.8.9",
"com.unity.collab-proxy": "2.0.0",
"com.unity.feature.development": "1.0.1",

View File

@ -1,5 +1,14 @@
{
"dependencies": {
"com.heathen.steamworksfoundation": {
"version": "https://github.com/heathen-engineering/SteamworksFoundation.git?path=Unity/com.heathen.steamworksfoundation",
"depth": 0,
"source": "git",
"dependencies": {
"com.unity.mathematics": "1.2.5"
},
"hash": "3fc1f33a48211720c2ad7bc583b0b19e2f356695"
},
"com.unity.burst": {
"version": "1.8.2",
"depth": 1,