public GetPublicDataResult GetPublicData(GetPublicDataRequest request) { AbstractData data = new AbstractData { Version = 0, Layout = 12, Data = new byte[0] }; switch (request.ContainerName) { case PublicDataContainerTypes.WeaponLoadouts: break; case PublicDataContainerTypes.ArmorLoadouts: var armorLoadout = new ArmorLoadout { PrimaryColor = "color_pri_13", SecondaryColor = "color_sec_13", VisorColor = "color_visor_5", LightsColor = "color_lights_3", HologramsColor = "color_holo_3", Slots = Enumerable.Repeat(new ArmorLoadoutSlot { Head = "helmet_air_assault", Shoulders = "shoulder_air_assault", Torso = "chest_air_assault", Hands = "arms_air_assault", Legs = "legs_air_assault", Reserved = "" }, 5).ToList() }; data = armorLoadout.Serialize(); break; case PublicDataContainerTypes.Customizations: break; default: break; } return new GetPublicDataResult { Result = new ServiceResult<List<PerUser>> { Data = new List<PerUser> { new PerUser { User = new UserId { Id = 1 }, PerUserData = data } } } }; }
public GetPublicDataResult GetPublicData(GetPublicDataRequest request) { AbstractData data; switch (request.ContainerName) { case DataContainerTypes.WeaponLoadouts: var weaponLoadout = new WeaponLoadout { ActiveLoadoutSlotIndex = 0, LoadoutSlots = Enumerable.Repeat(new WeaponLoadoutSlot { PrimaryWeapon = "assault_rifle", SecondaryWeapon = "magnum", Grenades = "frag_grenade", Booster = "", ConsumableFirst = "", ConsumableSecond = "", ConsumableThird = "", ConsumableFourth = "" } , 5).ToList() }; data = weaponLoadout.Serialize(); break; case DataContainerTypes.ArmorLoadouts: var armorLoadout = new ArmorLoadout { ActiveLoadoutSlotIndex = 0, PrimaryColor = "color_pri_13", SecondaryColor = "color_sec_13", VisorColor = "color_visor_5", LightsColor = "color_lights_3", HologramsColor = "color_holo_3", Slots = Enumerable.Repeat(new ArmorLoadoutSlot { Head = "helmet_air_assault", Shoulders = "shoulder_air_assault", Torso = "chest_air_assault", Hands = "arms_air_assault", Legs = "legs_air_assault", Accessory = "" }, 5).ToList() }; data = armorLoadout.Serialize(); break; case DataContainerTypes.Customizations: var customization = new Customization { AccountLabel = "account_label" }; data = customization.Serialize(); break; default: throw new ArgumentException("ContainerName"); } return(new GetPublicDataResult { Result = new ServiceResult <List <PerUser> > { Data = new List <PerUser> { new PerUser { User = new UserId { Id = 1 }, PerUserData = data } } } }); }
public GetPublicDataResult GetPublicData(GetPublicDataRequest request) { AbstractData data; switch (request.ContainerName) { case DataContainerTypes.WeaponLoadouts: var weaponLoadout = new WeaponLoadout { ActiveLoadoutSlotIndex = 0, LoadoutSlots = Enumerable.Repeat(new WeaponLoadoutSlot { PrimaryWeapon = "assault_rifle", SecondaryWeapon = "magnum", Grenades = "frag_grenade", Booster = "", ConsumableFirst = "", ConsumableSecond = "", ConsumableThird = "", ConsumableFourth = "" } , 5).ToList() }; data = weaponLoadout.Serialize(); break; case DataContainerTypes.ArmorLoadouts: var armorLoadout = new ArmorLoadout { ActiveLoadoutSlotIndex = 0, PrimaryColor = "color_pri_13", SecondaryColor = "color_sec_13", VisorColor = "color_visor_5", LightsColor = "color_lights_3", HologramsColor = "color_holo_3", Slots = Enumerable.Repeat(new ArmorLoadoutSlot { Head = "helmet_air_assault", Shoulders = "shoulder_air_assault", Torso = "chest_air_assault", Hands = "arms_air_assault", Legs = "legs_air_assault", Accessory = "" }, 5).ToList() }; data = armorLoadout.Serialize(); break; case DataContainerTypes.Customizations: var customization = new Customization { AccountLabel = "account_label" }; data = customization.Serialize(); break; default: throw new ArgumentException("ContainerName"); } return new GetPublicDataResult { Result = new ServiceResult<List<PerUser>> { Data = new List<PerUser> { new PerUser { User = new UserId { Id = 1 }, PerUserData = data } } } }; }