mirror of
https://github.com/MrOkiDoki/BattleBit-Community-Server-API.git
synced 2025-02-02 14:37:15 -03:00
Update CI, auto-adjust namespaces
This commit is contained in:
parent
e9745348a3
commit
94fc8a025e
40 changed files with 77 additions and 58 deletions
6
.github/workflows/ci.yml
vendored
6
.github/workflows/ci.yml
vendored
|
@ -7,7 +7,7 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
framework-version: [ 'net6.0', 'net7.0' ]
|
||||
framework-version: [ 'netstandard2.1', 'net6.0', 'net7.0' ]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v2
|
||||
|
@ -20,9 +20,9 @@ jobs:
|
|||
with:
|
||||
dotnet-version: '7.0.x'
|
||||
dotnet-quality: 'ga'
|
||||
|
||||
|
||||
- name: Install dependencies
|
||||
run: dotnet restore
|
||||
|
||||
|
||||
- name: Build for ${{ matrix.framework-version }}
|
||||
run: dotnet build BattleBitAPI --framework ${{ matrix.framework-version }} --configuration Release --no-restore
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
using BattleBitAPI;
|
||||
using BattleBitAPI.Common;
|
||||
using BattleBitAPI.Common.Arguments;
|
||||
using BattleBitAPI.Common.Data;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
using BattleBitAPI.Server;
|
||||
using System.Threading.Channels;
|
||||
using System.Xml;
|
||||
|
||||
namespace BattleBitAPI.Playground;
|
||||
|
||||
class Program
|
||||
{
|
||||
|
|
|
@ -2,11 +2,11 @@
|
|||
|
||||
<PropertyGroup>
|
||||
<OutputType>Library</OutputType>
|
||||
<TargetFramework>netstandard2.1</TargetFramework>
|
||||
<TargetFrameworks>netstandard2.1;net7.0;net6.0</TargetFrameworks>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>disable</Nullable>
|
||||
<AllowUnsafeBlocks>True</AllowUnsafeBlocks>
|
||||
<RootNamespace>CommunityServerAPI</RootNamespace>
|
||||
<RootNamespace>BattleBitAPI</RootNamespace>
|
||||
<LangVersion>latest</LangVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
using System.Numerics;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common.Arguments
|
||||
{
|
||||
public struct OnPlayerKillArguments<TPlayer> where TPlayer : Player<TPlayer>
|
||||
{
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
using System.Numerics;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
using BattleBitAPI.Common.Data;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common.Arguments
|
||||
{
|
||||
public struct OnPlayerSpawnArguments
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace CommunityServerAPI.BattleBitAPI
|
||||
namespace BattleBitAPI.Common
|
||||
{
|
||||
public static class Const
|
||||
{
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
using BattleBitAPI.Common;
|
||||
using System;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public class Attachment : IEquatable<string>, IEquatable<Attachment>
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public class Gadget : IEquatable<string>, IEquatable<Gadget>
|
||||
{
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
using System.Reflection;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public static class Gadgets
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public class Map : IEquatable<string>, IEquatable<Map>
|
||||
{
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
namespace BattleBitAPI.Common
|
||||
using BattleBitAPI.Common.Datasets;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public struct PlayerLoadout
|
||||
{
|
||||
|
|
|
@ -1,4 +1,6 @@
|
|||
namespace BattleBitAPI.Common
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public class PlayerStats
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public struct PlayerWearings
|
||||
{
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
using System;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Data
|
||||
{
|
||||
public class Weapon : IEquatable<string>, IEquatable<Weapon>
|
||||
{
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
using System.Reflection;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
using BattleBitAPI.Common.Data;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common.Datasets
|
||||
{
|
||||
public static class Attachments
|
||||
{
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
using Microsoft.VisualBasic;
|
||||
using System.Reflection;
|
||||
using System.Reflection;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
using BattleBitAPI.Common.Data;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Common.Datasets
|
||||
{
|
||||
public static class Weapons
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum AttachmentType
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum ChatChannel
|
||||
{
|
||||
|
|
|
@ -1,10 +1,4 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum ReasonOfDamage : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum GameRole
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum GameState : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum MapDayNight : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum MapSize : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum PlayerBody : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum PlayerSpawningPosition : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum PlayerStand : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum ReportReason
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum Roles : ulong
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum Squads
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum Team : byte
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Common
|
||||
namespace BattleBitAPI.Common.Enums
|
||||
{
|
||||
public enum WeaponType : int
|
||||
{
|
||||
|
|
|
@ -4,6 +4,9 @@ using BattleBitAPI.Server;
|
|||
using System.Net;
|
||||
using System.Numerics;
|
||||
|
||||
using BattleBitAPI.Common.Data;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI
|
||||
{
|
||||
public class Player<TPlayer> where TPlayer : Player<TPlayer>
|
||||
|
|
|
@ -4,9 +4,12 @@ using System.Net.Sockets;
|
|||
using System.Numerics;
|
||||
using System.Text;
|
||||
using BattleBitAPI.Common;
|
||||
using BattleBitAPI.Common.Arguments;
|
||||
using BattleBitAPI.Common.Data;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
using BattleBitAPI.Common.Extentions;
|
||||
using BattleBitAPI.Networking;
|
||||
using CommunityServerAPI.BattleBitAPI;
|
||||
using BattleBitAPI.Server.Internal;
|
||||
|
||||
namespace BattleBitAPI.Server
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Server
|
||||
namespace BattleBitAPI.Server.Internal
|
||||
{
|
||||
public class GamemodeRotation<TPlayer> where TPlayer : Player<TPlayer>
|
||||
{
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Server
|
||||
namespace BattleBitAPI.Server.Internal
|
||||
{
|
||||
public class MapRotation<TPlayer> where TPlayer : Player<TPlayer>
|
||||
{
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
using BattleBitAPI.Common;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
|
||||
namespace BattleBitAPI.Server
|
||||
namespace BattleBitAPI.Server.Internal
|
||||
{
|
||||
public class RoundSettings<TPlayer> where TPlayer : Player<TPlayer>
|
||||
{
|
||||
|
@ -32,12 +32,12 @@ namespace BattleBitAPI.Server
|
|||
this.mResources.IsDirtyRoundSettings = true;
|
||||
}
|
||||
}
|
||||
public double MaxTickets
|
||||
public int MaxTickets
|
||||
{
|
||||
get => this.mResources._RoundSettings.MaxTickets;
|
||||
get => this.mResources._RoundSettings.PlayersToStart;
|
||||
set
|
||||
{
|
||||
this.mResources._RoundSettings.MaxTickets = value;
|
||||
this.mResources._RoundSettings.PlayersToStart = value;
|
||||
this.mResources.IsDirtyRoundSettings = true;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
namespace BattleBitAPI.Server
|
||||
namespace BattleBitAPI.Server.Internal
|
||||
{
|
||||
public class ServerSettings<TPlayer> where TPlayer : Player<TPlayer>
|
||||
{
|
||||
|
|
|
@ -3,10 +3,12 @@ using System.Net.Security;
|
|||
using System.Net.Sockets;
|
||||
using System.Numerics;
|
||||
using BattleBitAPI.Common;
|
||||
using BattleBitAPI.Common.Arguments;
|
||||
using BattleBitAPI.Common.Data;
|
||||
using BattleBitAPI.Common.Enums;
|
||||
using BattleBitAPI.Common.Extentions;
|
||||
using BattleBitAPI.Common.Serialization;
|
||||
using BattleBitAPI.Networking;
|
||||
using CommunityServerAPI.BattleBitAPI;
|
||||
|
||||
namespace BattleBitAPI.Server
|
||||
{
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
using BattleBitAPI.Common;
|
||||
using BattleBitAPI.Common.Data;
|
||||
|
||||
namespace BattleBitAPI.Storage
|
||||
{
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
using BattleBitAPI.Common;
|
||||
using BattleBitAPI.Common.Data;
|
||||
|
||||
namespace BattleBitAPI.Storage
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue