ShiftOS_TheReturn/ShiftOS.Frontend/Hacking/HackableProvider.cs

45 lines
1.1 KiB
C#
Raw Normal View History

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ShiftOS.Objects;
using ShiftOS.Engine;
using Newtonsoft.Json;
namespace ShiftOS.Frontend
{
public class HackableProvider : IHackableProvider
{
public Hackable[] GetHackables()
{
return JsonConvert.DeserializeObject<Hackable[]>(Properties.Resources.Hackables);
}
2017-07-27 23:34:27 +00:00
public Exploit[] GetExploits()
{
return JsonConvert.DeserializeObject<Exploit[]>(Properties.Resources.Exploits);
}
public Payload[] GetPayloads()
{
return JsonConvert.DeserializeObject<Payload[]>(Properties.Resources.Payloads);
}
2017-07-28 00:27:31 +00:00
public Port[] GetPorts()
{
return JsonConvert.DeserializeObject<Port[]>(Properties.Resources.Ports);
}
public byte[] GetLootFromResource(string resId)
{
return new byte[] { 0xDE, 0xAD, 0xBE, 0xEF }; //nyi
}
2017-07-29 04:38:44 +00:00
public Loot[] GetLoot()
{
2017-07-29 04:38:44 +00:00
return JsonConvert.DeserializeObject<Loot[]>(Properties.Resources.LootInfo);
}
}
}