ItemDB+API

This commit is contained in:
dingo
2025-12-04 09:30:32 -05:00
parent 841b241ef2
commit d66ff2af40
10 changed files with 2183 additions and 1 deletions
+173
View File
@@ -210,6 +210,168 @@ namespace SystemRevivalServer.Migrations
b.ToTable("equipment", (string)null);
});
modelBuilder.Entity("Server.Data.GameItem", b =>
{
b.Property<int>("Id")
.HasColumnType("int");
b.Property<int>("AmmoType")
.HasColumnType("int");
b.Property<int>("Category")
.HasColumnType("int");
b.Property<int>("CraftCost")
.HasColumnType("int");
b.Property<DateTime>("CreatedAt")
.ValueGeneratedOnAdd()
.HasColumnType("datetime(6)")
.HasDefaultValueSql("CURRENT_TIMESTAMP(6)");
b.Property<int>("Damage")
.HasColumnType("int");
b.Property<float>("DamageReduction")
.HasColumnType("float");
b.Property<float>("DashCooldown")
.HasColumnType("float");
b.Property<float>("DashDistance")
.HasColumnType("float");
b.Property<string>("Description")
.IsRequired()
.HasMaxLength(256)
.HasColumnType("varchar(256)");
b.Property<float>("ExplosionRadius")
.HasColumnType("float");
b.Property<float>("FireRate")
.HasColumnType("float");
b.Property<float>("HarvestMultiplier")
.HasColumnType("float");
b.Property<int>("HealAmount")
.HasColumnType("int");
b.Property<int>("HealthBonus")
.HasColumnType("int");
b.Property<bool>("IsEnabled")
.ValueGeneratedOnAdd()
.HasColumnType("tinyint(1)")
.HasDefaultValue(true);
b.Property<int>("LootValue")
.HasColumnType("int");
b.Property<string>("Name")
.IsRequired()
.HasMaxLength(64)
.HasColumnType("varchar(64)");
b.Property<int>("PelletCount")
.HasColumnType("int");
b.Property<float>("ProjectileSpeed")
.HasColumnType("float");
b.Property<float>("Range")
.HasColumnType("float");
b.Property<float>("ScanCooldown")
.HasColumnType("float");
b.Property<float>("ScanRadius")
.HasColumnType("float");
b.Property<float>("ShieldBoostDuration")
.HasColumnType("float");
b.Property<float>("ShieldDuration")
.HasColumnType("float");
b.Property<int>("ShieldHealth")
.HasColumnType("int");
b.Property<float>("SpeedBoostDuration")
.HasColumnType("float");
b.Property<float>("SpeedMultiplier")
.HasColumnType("float");
b.Property<float>("SpeedPenalty")
.HasColumnType("float");
b.Property<float>("Spread")
.HasColumnType("float");
b.Property<bool>("Stackable")
.HasColumnType("tinyint(1)");
b.Property<DateTime>("UpdatedAt")
.ValueGeneratedOnAddOrUpdate()
.HasColumnType("datetime(6)")
.HasDefaultValueSql("CURRENT_TIMESTAMP(6)");
MySqlPropertyBuilderExtensions.UseMySqlComputedColumn(b.Property<DateTime>("UpdatedAt"));
b.HasKey("Id");
b.HasIndex("Category");
b.HasIndex("IsEnabled");
b.ToTable("game_items", (string)null);
});
modelBuilder.Entity("Server.Data.GameRecipe", b =>
{
b.Property<int>("Id")
.HasColumnType("int");
b.Property<DateTime>("CreatedAt")
.ValueGeneratedOnAdd()
.HasColumnType("datetime(6)")
.HasDefaultValueSql("CURRENT_TIMESTAMP(6)");
b.Property<int>("EnergyCost")
.HasColumnType("int");
b.Property<bool>("IsEnabled")
.ValueGeneratedOnAdd()
.HasColumnType("tinyint(1)")
.HasDefaultValue(true);
b.Property<int>("RareCost")
.HasColumnType("int");
b.Property<int>("ResultItemId")
.HasColumnType("int");
b.Property<int>("ScrapCost")
.HasColumnType("int");
b.Property<DateTime>("UpdatedAt")
.ValueGeneratedOnAddOrUpdate()
.HasColumnType("datetime(6)")
.HasDefaultValueSql("CURRENT_TIMESTAMP(6)");
MySqlPropertyBuilderExtensions.UseMySqlComputedColumn(b.Property<DateTime>("UpdatedAt"));
b.HasKey("Id");
b.HasIndex("IsEnabled");
b.HasIndex("ResultItemId");
b.ToTable("game_recipes", (string)null);
});
modelBuilder.Entity("Server.Data.InventoryItem", b =>
{
b.Property<ulong>("Id")
@@ -591,6 +753,17 @@ namespace SystemRevivalServer.Migrations
b.Navigation("ItemTemplate");
});
modelBuilder.Entity("Server.Data.GameRecipe", b =>
{
b.HasOne("Server.Data.GameItem", "ResultItem")
.WithMany()
.HasForeignKey("ResultItemId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("ResultItem");
});
modelBuilder.Entity("Server.Data.InventoryItem", b =>
{
b.HasOne("Server.Data.Character", "Character")