fishnet installed
This commit is contained in:
29
Assets/FishNet/Runtime/Object/Prediction/Attributes.cs
Normal file
29
Assets/FishNet/Runtime/Object/Prediction/Attributes.cs
Normal file
@ -0,0 +1,29 @@
|
||||
using System;
|
||||
|
||||
namespace FishNet.Object.Prediction
|
||||
{
|
||||
/// <summary>
|
||||
/// Replicated methods are to be called from clients and will run the same data and logic on the server.
|
||||
/// Only data used as method arguments will be serialized.
|
||||
/// </summary>
|
||||
[AttributeUsage(AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
|
||||
public class ReplicateAttribute : Attribute
|
||||
{
|
||||
/// <summary>
|
||||
/// How many past datas to resend.
|
||||
/// </summary>
|
||||
public byte Resends = 5;
|
||||
}
|
||||
/// <summary>
|
||||
/// Reconcile methods indicate how to reset your script or object after the server has replicated user data.
|
||||
/// </summary>
|
||||
[AttributeUsage(AttributeTargets.Method, Inherited = true, AllowMultiple = false)]
|
||||
public class ReconcileAttribute : Attribute
|
||||
{
|
||||
/// <summary>
|
||||
/// How many times to resend reconcile.
|
||||
/// </summary>
|
||||
public byte Resends = 3;
|
||||
}
|
||||
|
||||
}
|
11
Assets/FishNet/Runtime/Object/Prediction/Attributes.cs.meta
Normal file
11
Assets/FishNet/Runtime/Object/Prediction/Attributes.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b082d36535ce0404d8438bc1b0499e53
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
20
Assets/FishNet/Runtime/Object/Prediction/Delegates.cs
Normal file
20
Assets/FishNet/Runtime/Object/Prediction/Delegates.cs
Normal file
@ -0,0 +1,20 @@
|
||||
using FishNet.Connection;
|
||||
using FishNet.Documenting;
|
||||
using FishNet.Serializing;
|
||||
using FishNet.Transporting;
|
||||
using FishNet.Utility.Constant;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
[assembly: InternalsVisibleTo(UtilityConstants.CODEGEN_ASSEMBLY_NAME)]
|
||||
namespace FishNet.Object.Prediction.Delegating
|
||||
{
|
||||
[APIExclude]
|
||||
public delegate void ReplicateRpcDelegate(PooledReader reader, NetworkConnection sender, Channel channel);
|
||||
[APIExclude]
|
||||
public delegate void ReconcileRpcDelegate(PooledReader reader, Channel channel);
|
||||
|
||||
[APIExclude]
|
||||
public delegate void ReplicateUserLogicDelegate<T>(T data, bool asServer, Channel channel, bool replaying);
|
||||
[APIExclude]
|
||||
public delegate void ReconcileUserLogicDelegate<T>(T data, bool asServer, Channel channel);
|
||||
}
|
11
Assets/FishNet/Runtime/Object/Prediction/Delegates.cs.meta
Normal file
11
Assets/FishNet/Runtime/Object/Prediction/Delegates.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c9904192dacd41a4ba7b29bc3199ec3a
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
18
Assets/FishNet/Runtime/Object/Prediction/Interfaces.cs
Normal file
18
Assets/FishNet/Runtime/Object/Prediction/Interfaces.cs
Normal file
@ -0,0 +1,18 @@
|
||||
|
||||
namespace FishNet.Object.Prediction
|
||||
{
|
||||
public interface IReplicateData
|
||||
{
|
||||
uint GetTick();
|
||||
void SetTick(uint value);
|
||||
void Dispose();
|
||||
}
|
||||
|
||||
public interface IReconcileData
|
||||
{
|
||||
uint GetTick();
|
||||
void SetTick(uint value);
|
||||
void Dispose();
|
||||
}
|
||||
|
||||
}
|
11
Assets/FishNet/Runtime/Object/Prediction/Interfaces.cs.meta
Normal file
11
Assets/FishNet/Runtime/Object/Prediction/Interfaces.cs.meta
Normal file
@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 515754257f85574438408c7f5b268590
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
Reference in New Issue
Block a user