Ejemplo n.º 1
0
            internal static void changeMaterial(IntPtr thisPtr, uint slot, [MarshalAs(UnmanagedType.LPWStr)] string newMat)
            {
                if (_changeMaterialFunc == null)
                {
                    _changeMaterialFunc =
                        (_changeMaterial)Marshal.GetDelegateForFunctionPointer(Torque3D.DllLoadUtils.GetProcAddress(Torque3D.Torque3DLibHandle,
                                                                                                                    "fn_MeshComponent_changeMaterial"), typeof(_changeMaterial));
                }

                _changeMaterialFunc(thisPtr, slot, newMat);
            }
Ejemplo n.º 2
0
            internal static void changeMaterial(IntPtr thisPtr, [MarshalAs(UnmanagedType.LPWStr)] string mapTo, IntPtr oldMat, IntPtr newMat)
            {
                if (_changeMaterialFunc == null)
                {
                    _changeMaterialFunc =
                        (_changeMaterial)Marshal.GetDelegateForFunctionPointer(Torque3D.DllLoadUtils.GetProcAddress(Torque3D.Torque3DLibHandle,
                                                                                                                    "fn_TSStatic_changeMaterial"), typeof(_changeMaterial));
                }

                _changeMaterialFunc(thisPtr, mapTo, oldMat, newMat);
            }