最近在工作中进行游戏开发,在Xlua与C#的调用中,发现一些问题,这里记录一下,便于后期复习。
1、C#和lua关于"."与":"的区别使用,懒得写,直接传送:传送门
2、@,一般用来做转义使用,例,不加@ string fileName = "D://文本文件//text.txt"; 加@string fileName = @"D:/文本文件/text.txt";
其次用于字符串换行,目前没有尝试过string sql="select * from A"+“left join B”+" ON A.ID=B.ID";------->
string <a href="mailto:sql=@"select">sql=@"select * from A
在标识符中加@可使用关键字,pg:
namespace @namespace
{
class @class
{
public static void @static(int @int)
{
if (@int > 0)
{
System.Console.WriteLine("Positive Integer");
}
elseif (@int == 0)
{
System.Console.WriteLine("Zero");
}
else
{
System.Console.WriteLine("Negative Integer");
}
}
}
}