using GadgetCore.API;
using GadgetCore.API.ConfigMenu;
using ScrapYard.API;

namespace MultiplayerClientSpawn
{
  [Gadget("MultiplayerClientSpawn", LoadAfter: new string[] { "ScrapYard" }, Dependencies: new string[] { "ScrapYard" })]
  public class MultiplayerClientSpawn : Gadget<MultiplayerClientSpawn>
  {
    public const string MOD_VERSION = "1.1"; // Set this to the version of your mod.
    public const string CONFIG_VERSION = "1.0"; // Increment this whenever you change your mod's config file.

    public override IGadgetConfigMenu GetConfigMenu() { return null; }

    public override string GetModDescription()
    {
      return "A mod that adds a multiplayer spawn point.";
    }

    protected override void Initialize()
    {
      Logger.Log("Multiplayer Client Spawn v" + Info.Mod.Version);
      Core.logger = Logger;

      Core.itemSpawnId = ItemUtil.CreatePlacableSpawnItem("spawnpoint.png", "iSpawn.png", "spawnpoint0.png", "spawnpoint1.png", "Multiplayer Spawn");
      ShopPlatform.DefaultObjects.AddShopPlatformEntry(new ShopPlatformEntry(Core.itemSpawnId, 10));
    }
  }
}
