Skip to content

Commit 4550b47

Browse files
update project
1 parent 2732923 commit 4550b47

22 files changed

Lines changed: 169 additions & 170 deletions

.gitattributes

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
###############################################################################
2+
# Set default behavior to automatically normalize line endings.
3+
###############################################################################
4+
* text=auto
5+
6+
###############################################################################
7+
# Set default behavior for command prompt diff.
8+
#
9+
# This is need for earlier builds of msysgit that does not have it on by
10+
# default for csharp files.
11+
# Note: This is only used by command line
12+
###############################################################################
13+
#*.cs diff=csharp
14+
15+
###############################################################################
16+
# Set the merge driver for project and solution files
17+
#
18+
# Merging from the command prompt will add diff markers to the files if there
19+
# are conflicts (Merging from VS is not affected by the settings below, in VS
20+
# the diff markers are never inserted). Diff markers may cause the following
21+
# file extensions to fail to load in VS. An alternative would be to treat
22+
# these files as binary and thus will always conflict and require user
23+
# intervention with every merge. To do so, just uncomment the entries below
24+
###############################################################################
25+
#*.sln merge=binary
26+
#*.csproj merge=binary
27+
#*.vbproj merge=binary
28+
#*.vcxproj merge=binary
29+
#*.vcproj merge=binary
30+
#*.dbproj merge=binary
31+
#*.fsproj merge=binary
32+
#*.lsproj merge=binary
33+
#*.wixproj merge=binary
34+
#*.modelproj merge=binary
35+
#*.sqlproj merge=binary
36+
#*.wwaproj merge=binary
37+
38+
###############################################################################
39+
# behavior for image files
40+
#
41+
# image files are treated as binary by default.
42+
###############################################################################
43+
#*.jpg binary
44+
#*.png binary
45+
#*.gif binary
46+
47+
###############################################################################
48+
# diff behavior for common document formats
49+
#
50+
# Convert binary document formats to text before diffing them. This feature
51+
# is only available from the command line. Turn it on by uncommenting the
52+
# entries below.
53+
###############################################################################
54+
#*.doc diff=astextplain
55+
#*.DOC diff=astextplain
56+
#*.docx diff=astextplain
57+
#*.DOCX diff=astextplain
58+
#*.dot diff=astextplain
59+
#*.DOT diff=astextplain
60+
#*.pdf diff=astextplain
61+
#*.PDF diff=astextplain
62+
#*.rtf diff=astextplain
63+
#*.RTF diff=astextplain

.gitignore

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,15 @@ mono_crash.*
2323
[Rr]eleases/
2424
x64/
2525
x86/
26+
[Ww][Ii][Nn]32/
2627
[Aa][Rr][Mm]/
2728
[Aa][Rr][Mm]64/
2829
bld/
2930
[Bb]in/
3031
[Oo]bj/
32+
[Oo]ut/
3133
[Ll]og/
34+
[Ll]ogs/
3235

3336
# Visual Studio 2015/2017 cache/options directory
3437
.vs/
@@ -60,6 +63,9 @@ project.lock.json
6063
project.fragment.lock.json
6164
artifacts/
6265

66+
# ASP.NET Scaffolding
67+
ScaffoldingReadMe.txt
68+
6369
# StyleCop
6470
StyleCopReport.xml
6571

@@ -126,9 +132,6 @@ _ReSharper*/
126132
*.[Rr]e[Ss]harper
127133
*.DotSettings.user
128134

129-
# JustCode is a .NET coding add-in
130-
.JustCode
131-
132135
# TeamCity is a build add-in
133136
_TeamCity*
134137

@@ -139,6 +142,11 @@ _TeamCity*
139142
.axoCover/*
140143
!.axoCover/settings.json
141144

145+
# Coverlet is a free, cross platform Code Coverage Tool
146+
coverage*.json
147+
coverage*.xml
148+
coverage*.info
149+
142150
# Visual Studio code coverage results
143151
*.coverage
144152
*.coveragexml
@@ -347,3 +355,9 @@ healthchecksdb
347355

348356
# Backup folder for Package Reference Convert tool in Visual Studio 2017
349357
MigrationBackup/
358+
359+
# Ionide (cross platform F# VS Code tools) working folder
360+
.ionide/
361+
362+
# Fody - auto-generated XML schema
363+
FodyWeavers.xsd

Properties/AssemblyInfo.cs

Lines changed: 0 additions & 36 deletions
This file was deleted.

README.md

Lines changed: 5 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,10 @@
1-
[![Version](https://img.shields.io/github/release/RestoreMonarchyPlugins/RPLicenses.svg)](https://github.com/RestoreMonarchyPlugins/RPLicenses/releases) [![Discord](https://discordapp.com/api/guilds/520355060312440853/widget.png)](https://restoremonarchy.com/discord)
21
# RPLicenses
3-
Simple Vehicle & Gun license plugin for Unturned RP servers.
4-
Based on DiagonalRPLicenses, but created from scratch.
2+
Simple vehicle & gun license plugin for Roleplay servers.
53

6-
### Features
7-
* Allows you to require your players to have license for actions, in current version it is driving and carrying guns.
8-
* You may want to limit license requirements only to specific action in `VehicleLicenseEnabled` or `GunLicenseEnabled` parameter.
9-
* Rocket permissions can bypass requirement to have a license in your inventory. So for example if you give `license.gun` to
10-
a given group in `Permissions.config.xml` then for this group license is not required.
11-
* You can change items required for licenses and permission names.
12-
* You can set custom color of the messages sent within translations.
4+
## Workshop (optional)
5+
[2350128257](https://steamcommunity.com/sharedfiles/filedetails/?id=2350128257) - Game4Freak's RP Licenses
136

14-
15-
### Default Configuration
7+
## Configuration
168
```xml
179
<?xml version="1.0" encoding="utf-8"?>
1810
<RPLicensesConfiguration xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
@@ -26,7 +18,7 @@ a given group in `Permissions.config.xml` then for this group license is not req
2618
</RPLicensesConfiguration>
2719
```
2820

29-
### Default Translations
21+
## Translations
3022
```xml
3123
<?xml version="1.0" encoding="utf-8"?>
3224
<Translations xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

RPLicenses.csproj

Lines changed: 0 additions & 78 deletions
This file was deleted.

RPLicenses.sln

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio Version 16
4-
VisualStudioVersion = 16.0.29418.71
3+
# Visual Studio Version 17
4+
VisualStudioVersion = 17.9.34728.123
55
MinimumVisualStudioVersion = 10.0.40219.1
6-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RPLicenses", "RPLicenses.csproj", "{53AFE513-A077-47F6-AA72-EA002463AB25}"
6+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RPLicenses", "RPLicenses\RPLicenses.csproj", "{53AFE513-A077-47F6-AA72-EA002463AB25}"
77
EndProject
88
Global
99
GlobalSection(SolutionConfigurationPlatforms) = preSolution

RPLicenses/RPLicenses.csproj

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<TargetFramework>net48</TargetFramework>
5+
<LangVersion>latest</LangVersion>
6+
<RootNamespace>RestoreMonarchy.RPLicenses</RootNamespace>
7+
<Version>1.1.0</Version>
8+
</PropertyGroup>
9+
10+
<ItemGroup>
11+
<Reference Include="Assembly-CSharp">
12+
<HintPath>..\lib\Assembly-CSharp.dll</HintPath>
13+
<Private>False</Private>
14+
</Reference>
15+
<Reference Include="com.rlabrecque.steamworks.net">
16+
<HintPath>..\lib\com.rlabrecque.steamworks.net.dll</HintPath>
17+
<Private>False</Private>
18+
</Reference>
19+
<Reference Include="Newtonsoft.Json">
20+
<HintPath>..\lib\Newtonsoft.Json.dll</HintPath>
21+
<Private>False</Private>
22+
</Reference>
23+
<Reference Include="Rocket.API">
24+
<HintPath>..\lib\Rocket.API.dll</HintPath>
25+
<Private>False</Private>
26+
</Reference>
27+
<Reference Include="Rocket.Core">
28+
<HintPath>..\lib\Rocket.Core.dll</HintPath>
29+
<Private>False</Private>
30+
</Reference>
31+
<Reference Include="Rocket.Unturned">
32+
<HintPath>..\lib\Rocket.Unturned.dll</HintPath>
33+
<Private>False</Private>
34+
</Reference>
35+
<Reference Include="SDG.NetTransport">
36+
<HintPath>..\lib\SDG.NetTransport.dll</HintPath>
37+
<Private>False</Private>
38+
</Reference>
39+
<Reference Include="UnityEngine">
40+
<HintPath>..\lib\UnityEngine.dll</HintPath>
41+
<Private>False</Private>
42+
</Reference>
43+
<Reference Include="UnityEngine.CoreModule">
44+
<HintPath>..\lib\UnityEngine.CoreModule.dll</HintPath>
45+
<Private>False</Private>
46+
</Reference>
47+
</ItemGroup>
48+
49+
<ItemGroup>
50+
<Content Include="..\lib\output\*.*">
51+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
52+
</Content>
53+
</ItemGroup>
54+
55+
</Project>
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
using Rocket.API;
2+
3+
namespace RestoreMonarchy.RPLicenses
4+
{
5+
public class RPLicensesConfiguration : IRocketPluginConfiguration
6+
{
7+
public string MessageColor { get; set; }
8+
public bool VehicleLicenseEnabled { get; set; }
9+
public bool GunLicenseEnabled { get; set; }
10+
public string VehicleLicensePermission { get; set; }
11+
public string GunLicensePermission { get; set; }
12+
public ushort VehicleLicenseID { get; set; }
13+
public ushort GunLicenseID { get; set; }
14+
15+
public void LoadDefaults()
16+
{
17+
MessageColor = "yellow";
18+
VehicleLicenseEnabled = true;
19+
GunLicenseEnabled = true;
20+
VehicleLicensePermission = "license.vehicle";
21+
GunLicensePermission = "license.gun";
22+
VehicleLicenseID = 1052; // dollar note $10
23+
GunLicenseID = 1054; // dollar note $50
24+
}
25+
}
26+
}
Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
using Rocket.API;
22
using Rocket.Unturned.Player;
3-
using SDG.Unturned;
43

54
namespace RestoreMonarchy.RPLicenses
65
{
Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,11 @@
22
using Rocket.Core.Plugins;
33
using Rocket.Unturned;
44
using Rocket.Unturned.Chat;
5-
using Rocket.Unturned.Events;
65
using Rocket.Unturned.Player;
76
using SDG.Unturned;
87
using System;
98
using UnityEngine;
109
using Logger = Rocket.Core.Logging.Logger;
11-
using Rocket.API;
1210

1311
namespace RestoreMonarchy.RPLicenses
1412
{

0 commit comments

Comments
 (0)