Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private static ImportedFunction func_doAThing;
- private delegate void DelegatedoAThing( int foo, float bar );
- public static void doAThing( int foo, float bar )
- {
- if( func_doAThing == null ) func_doAThing = new ImportedFunction( "anothertestobject.doAThing", "void(int32_t, float)" );
- DelegatedoAThing call = (DelegatedoAThing)System.Runtime.InteropServices.Marshal.GetDelegateForFunctionPointer( func_doAThing.FuncPtr, typeof( DelegatedoAThing ) );
- call( foo, bar );
- }
- //------------------------------------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement