Please clarify the type of DLL, is this a C++ DLL or a C# DLL? If this is C#, just call the methods like you would if you wrote the class in the engine itself, if this is C++ you have to create a carbon bundle and have an .A file like mylib.a vs mylib.dll, pro has instructions on how to set this up.
The client needs to have MySQL installed on the machine for this to work or have a DNS configured, you might be better off doing what is posted at this wiki:
You can do this. (It bloats your webplayer like crazy). Just add the .dll files to your asset folder.
Mono.CSharp.dll I think contains a c# compiler with a .net api. I am totally enjoying being able to parse c# at runtime.
It comforts me that you are parsing c# at runtime… that’s exactly what i am aiming to do.
I would really appreciate if you could provide me with a quick step by step, or an example for that matter showing us how you get to do it.
Adding the dlls to our asset folder is the first step, but i am kinda lost in what’s next on putting into use those dlls to parse c# at runtime. I CAN do this in the editor, but the problem shows up when we use the Web Player… i can’t parse c# in runtime.
I would really appreciate help, for your time, thank you.
You can’t access local variables like that. You can however pass them trough static variables in a class.
Try something along the lines of below.
(email code, might need some tweaks to compile, but that’s the idea)
Bye, Lucas
public class DataHolder
{
public static int HeyThere = 4;
}
public class Test
{
static void Main()
{
Mono.CSharp.Evaluator.Init(new string[] {} );
Assembly a = Assembly.GetExecutingAssembly();
Mono.CSharp.Evaluator.ReferenceAssembly(a);
Debug.Log("result2: "+Mono.CSharp.Evaluator.Evaluate("DataHolder.HeyThere+5"));
}
}