Moved tuning garages to database, moved vehicle distance driven counter timer from update event to timer

This commit is contained in:
hydrant
2019-04-12 19:03:23 +02:00
parent 5749b15151
commit 434e19e6ea
10 changed files with 1194 additions and 46 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,32 @@
using Microsoft.EntityFrameworkCore.Metadata;
using Microsoft.EntityFrameworkCore.Migrations;
namespace ReallifeGamemode.Migrations
{
public partial class TuningGarage : Migration
{
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "TuningGarages",
columns: table => new
{
Id = table.Column<int>(nullable: false)
.Annotation("MySql:ValueGenerationStrategy", MySqlValueGenerationStrategy.IdentityColumn),
X = table.Column<float>(nullable: false),
Y = table.Column<float>(nullable: false),
Z = table.Column<float>(nullable: false)
},
constraints: table =>
{
table.PrimaryKey("PK_TuningGarages", x => x.Id);
});
}
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "TuningGarages");
}
}
}

View File

@@ -704,6 +704,22 @@ namespace ReallifeGamemode.Migrations
b.HasDiscriminator<string>("Discriminator").HasValue("ServerVehicle");
});
modelBuilder.Entity("ReallifeGamemode.Server.Entities.TuningGarage", b =>
{
b.Property<int>("Id")
.ValueGeneratedOnAdd();
b.Property<float>("X");
b.Property<float>("Y");
b.Property<float>("Z");
b.HasKey("Id");
b.ToTable("TuningGarages");
});
modelBuilder.Entity("ReallifeGamemode.Server.Entities.User", b =>
{
b.Property<int>("Id")