Hi there,
I was wondering if the types outlined here:
http://developer.muchdifferent.com/unitypark/uLink/Serialization
…Can be used as RPC arguments.
For example, would the following work: (Assume everything is public.)
struct MyStruct {
int a, b, c;
float x, y, z;
int[] myIntArray;
}
...
networkView.RPC("MyRpc",
new MyStruct(...),
new int[] {1, 2, 3});
...
void MyRpc(MyStruct myStruct, int[] intArray, uLink.NetworkMessageInfo info) {
...
}
Note that X is a struct, not a class. uLink mentions classes in #6 but not structs, I assume it doesn’t care which one you use.
Also, is the uLink.NetworkMessageInfo argument optional? Sometimes I don’t use it, and I’d rather not include it when I don’t use it as it makes the code a little uglier.
Thanks for your help!