出于某种原因,我不能像在Unity中创建的那样将这些图块映射出来......像素艺术从Tiled导入Unity.
有谁知道如何解决这个问题?提前致谢!
我想创建一个以XML或JSON格式返回数据的Web应用程序,我该如何做呢?
该模型:
namespace ReturningJSONandXML.Models
{
public class SomeImportantInformation
{
public int ID { get; set; }
public string Information { get; set; }
}
}
Run Code Online (Sandbox Code Playgroud)
控制器:
namespace ReturningJSONandXML.Controllers
{
public class GetInfoController : Controller
{
// GET: /<controller>/
public List<SomeImportantInformation> Get()
{
List<SomeImportantInformation> ImportantInfo = new List<SomeImportantInformation>();
ImportantInfo.Add(new SomeImportantInformation { ID = 0, Information = "Awesome info" });
ImportantInfo.Add(new SomeImportantInformation { ID = 1, Information = "Some other interesting info" });
return ImportantInfo;
}
}
}
Run Code Online (Sandbox Code Playgroud)
我想返回一个XML和JSON文件......
我应该在这里使用的最佳实践是什么?