[+] Added WeaponDeal System (Gangs Only) (WIP)

[+] New Timer in WeaponRack (will be removed for LSPD and FIB)
     [+] New Items for WeaponDeal System
[**] Huge Improvements on Inventory System w/ bug fixes (WIP)
This commit is contained in:
Lukas Moungos
2019-10-29 17:20:26 +01:00
39 changed files with 3676 additions and 132 deletions

View File

@@ -20,6 +20,7 @@ namespace ReallifeGamemode.Database.Entities
[StringLength(32)]
public string Name { get; set; }
public bool StateOwned { get; set; }
public int WeaponDealTime { get; set; } = 60;
public IBankAccount GetBankAccount(DatabaseContext databaseContext = null)
{

View File

@@ -20,5 +20,6 @@ namespace ReallifeGamemode.Database.Entities
public string WeaponModel { get; set; }
public int SlotID { get; set; }
public int Rank { get; set; }
public int Ammount { get; set; }
}
}

View File

@@ -88,7 +88,7 @@ namespace ReallifeGamemode.Database.Entities
public int JailTime { get; set; }
public int PaydayTimer { get; set; }
public int PaydayTimer { get; set; } = 60;
public bool IsAdmin(AdminLevel level) => AdminLevel >= level;

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,35 @@
using Microsoft.EntityFrameworkCore.Migrations;
namespace ReallifeGamemode.Database.Migrations
{
public partial class WeaponDealTimer : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<int>(
name: "WeaponDealTime",
table: "Factions",
nullable: false,
defaultValue: 0);
migrationBuilder.AlterColumn<int>(
name: "PaydayTimer",
table: "Users",
nullable: false,
defaultValue: 60);
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "WeaponDealTime",
table: "Factions");
migrationBuilder.AlterColumn<int>(
name: "PaydayTimer",
table: "Users",
nullable: false,
defaultValue: 0);
}
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,23 @@
using Microsoft.EntityFrameworkCore.Migrations;
namespace ReallifeGamemode.Database.Migrations
{
public partial class FactionWeaponAmount : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<int>(
name: "Ammount",
table: "FactionWeapons",
nullable: false,
defaultValue: 0);
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "Ammount",
table: "FactionWeapons");
}
}
}

View File

@@ -356,6 +356,8 @@ namespace ReallifeGamemode.Database.Migrations
b.Property<bool>("StateOwned");
b.Property<int>("WeaponDealTime");
b.HasKey("Id");
b.ToTable("Factions");
@@ -408,6 +410,8 @@ namespace ReallifeGamemode.Database.Migrations
b.Property<int>("Id")
.ValueGeneratedOnAdd();
b.Property<int>("Ammount");
b.Property<int?>("FactionId");
b.Property<int>("Rank");