Beispiel #1
0
        public VehicleAPI()
        {
            this.API_getHealth = (API_GetHealth)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetHealth@Vehicle@API@@YAMXZ"), typeof(API_GetHealth));

            this.API_getModelID      = (API_GetModelID)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetModelID@Vehicle@API@@YAHXZ"), typeof(API_GetModelID));
            this.API_getSpeed        = (API_GetSpeed)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetSpeed@Vehicle@API@@YAMXZ"), typeof(API_GetSpeed));
            this.API_isEngineRunning = (API_IsEngineRunning)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?IsEngineRunning@Vehicle@API@@YA_NXZ"), typeof(API_IsEngineRunning));
            this.API_isLightActive   = (API_IsLightActive)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?IsLightActive@Vehicle@API@@YA_NXZ"), typeof(API_IsLightActive));
            this.API_isLocked        = (API_IsLocked)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?IsLocked@Vehicle@API@@YA_NXZ"), typeof(API_IsLocked));
            this.API_useHorn         = (API_UseHorn)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?UseHorn@Vehicle@API@@YA_NXZ"), typeof(API_UseHorn));
            this.API_useSiren        = (API_UseSiren)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?UseSiren@Vehicle@API@@YA_NXZ"), typeof(API_UseSiren));
        }
Beispiel #2
0
        public PlayerAPI()
        {
            this.API_getHealth = (API_GetHealth)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetHealth@Player@API@@YAHXZ"), typeof(API_GetHealth));

            this.API_getArmor      = (API_GetArmor)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetArmor@Player@API@@YAHXZ"), typeof(API_GetArmor));
            this.API_inInterior    = (API_InInterior)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?InInterior@Player@API@@YA_NXZ"), typeof(API_InInterior));
            this.API_inVehicle     = (API_InVehicle)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?InVehicle@Player@API@@YA_NXZ"), typeof(API_InVehicle));
            this.API_isDriver      = (API_IsDriver)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?IsDriver@Player@API@@YA_NXZ"), typeof(API_IsDriver));
            this.API_isFreezed     = (API_IsFreezed)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?IsFreezed@Player@API@@YA_NXZ"), typeof(API_IsFreezed));
            this.API_getYaw        = (API_GetYaw)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetYaw@Player@API@@YAMXZ"), typeof(API_GetYaw));
            this.API_getInteriorId = (API_GetInteriorId)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetInteriorId@Player@API@@YAHXZ"), typeof(API_GetInteriorId));
            this.API_getPosition   = (API_GetPosition)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetPosition@Player@API@@YAXAAM00@Z"), typeof(API_GetPosition));
            this.API_getCity       = (API_GetCity)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetCity@Player@API@@YAXPA_WH@Z"), typeof(API_GetCity));
            this.API_getDistrict   = (API_GetDistrict)Marshal.GetDelegateForFunctionPointer(GeneralAPI.Instance.GetFunctionPointer("?GetDistrict@Player@API@@YAXPA_WH@Z"), typeof(API_GetDistrict));
        }