VS C#生成dll,C#和unity工程调用
1, C# 生成dll a, vs新建C#类库工程生成dll,对应的cs文件。 DllSuccess.cs using System ; using System . Collections . Generic ; using System . Linq ; using System . Text ; //using System.Threading.Tasks; namespace DllSuccess { public class Poem { public void PrintPoem () { Console . WriteLine ( "白日依山尽,黄河入海流!" ); } public static void PrintPoems () { Console . WriteLine ( "且将新火试新茶,诗酒趁年华。" ); } public static int UnityAdd ( int a , int b ) { int c = a + b ; return c ; } public static void WritePoem ( char [] strs_poem ) { String str_poem = "人有悲欢离合,月有阴晴圆缺。此事古难全!" ; char [] str = str_poem . ToCharArray (); int len =