October 28, 2020, 06:04:18 AM

Author Topic: [bb] Blitz3dSDK - C/C++ - Newton's Itmbin Wrapper by ZJP [ 1+ years ago ]  (Read 1477 times)

Offline BlitzBot

  • Jr. Member
  • **
  • Posts: 1
Title : Blitz3dSDK - C/C++ - Newton's Itmbin Wrapper
Author : ZJP
Posted : 1+ years ago

Description : How to use the Itmbin's wrapper www.blitzbasic.com/Community/posts.php?topic=66659

C/C++ example
Code: [Select]
// Test Blitz3D SDK and Newton Physic
#include <windows.h>
#include <math.h>
#include <stdio.h>
#include <time.h>

#include <blitz3dsdk.h>

int main( int argc, char** argv ){

    #include "INCLUDE_newton.cpp" // Newton declaration
   
    srand(time(NULL)); // random generator

bbBeginBlitz3D(); // Init SDK
    bbSetBlitz3DDebugMode(1);

bbGraphics3D(800, 600, 32, 0);
 
    int cam = bbCreateCamera();
    bbPositionEntity (cam,0,3,-10);

    int plane   = bbCreatePlane();
    int Texture = bbLoadTexture("cell.bmp");
    bbEntityTexture (plane,Texture);

    bbEntityAlpha (plane,0.9 );

    int miroir = bbCreateMirror() ;
   
    int light = bbCreateLight();
    bbRotateEntity (light,0,0,140);

    phWorldCreate(1,"key"); // Init Newton. Do not forget to double the '' if is present in the licence key string.. Thx to MeowZ

    int entity = bbCreateCube();
bbScaleMesh (entity,0.5,0.5,0.5);
    bbEntityColor(entity,rand() % 255,rand() % 255,rand() % 255);

    int body = phBodyCreateBox(1,1,1,10); // Create body. Size==> Blitz_Size*2
    phBodySetPos(body,0,7,0);
    phBodySetRot(body,rand() % 360,rand() % 360,rand() % 360);

while (!bbKeyHit(KEY_ESCAPE)) {

        if (bbKeyHit(KEY_1))
            {
  phBodyAddForce(body, 1500, 0, 0);
}
        if (bbKeyHit(KEY_2))
            {
  phBodyAddForce(body, 0, 1500, 0);
}
        if (bbKeyHit(KEY_3))
            {
            phBodyAddForce(body, 0, 0, 1500);
            phBodyAddRelForceAtRelPos(body,0,0,300,-1,-1,-2);
}
  bbUpdateWorld();
 
    phWorldStep(0.5);

   bbPositionEntity (entity,phBodyGetX(body),phBodyGetY(body),phBodyGetZ(body));
    bbRotateEntity (entity, phBodyGetPitch(body),phBodyGetYaw(body),phBodyGetRoll(body));
   
bbRenderWorld();

bbFlip();
}

bbEndBlitz3D();

return 0;
}


Next, the C/C++ Newton include file [/i]

Code :
Code: BlitzBasic
  1. HINSTANCE nwDLL = LoadLibrary("nwphx.DLL");
  2.  
  3. typedef void(WINAPI *DLL_phWorldCreate)(int plane, char *license_key);
  4. DLL_phWorldCreate phWorldCreate;
  5. phWorldCreate = (DLL_phWorldCreate)GetProcAddress(nwDLL,"_phWorldCreate@8");
  6. // Use ==> phWorldCreate(int plane, char *license_key);
  7.  
  8. typedef void(WINAPI *DLL_phWorldSetGravity)(float gx, float gy, float gz);
  9. DLL_phWorldSetGravity phWorldSetGravity;
  10. phWorldSetGravity = (DLL_phWorldSetGravity)GetProcAddress(nwDLL,"_phWorldSetGravity@12");
  11. // Use ==> phWorldSetGravity(float gx, float gy, float gz);
  12.  
  13. typedef void(WINAPI *DLL_phWorldStep)(float timestep);
  14. DLL_phWorldStep phWorldStep;
  15. phWorldStep = (DLL_phWorldStep)GetProcAddress(nwDLL,"_phWorldStep@4");
  16. // Use ==> phWorldStep(float timestep);
  17.  
  18. typedef void(WINAPI *DLL_phWorldSetSize)(float x1, float y1, float z1, float x2, float y2, float z2);
  19. DLL_phWorldSetSize phWorldSetSize;
  20. phWorldSetSize = (DLL_phWorldSetSize)GetProcAddress(nwDLL,"_phWorldSetSize@24");
  21. // Use ==> phWorldSetSize(float x1, float y1, float z1, float x2, float y2, float z2);
  22.  
  23. typedef void(WINAPI *DLL_phWorldSetSolverModel)(int model);
  24. DLL_phWorldSetSolverModel phWorldSetSolverModel;
  25. phWorldSetSolverModel = (DLL_phWorldSetSolverModel)GetProcAddress(nwDLL,"_phWorldSetSolverModel@4");
  26. // Use ==> phWorldSetSolverModel(int model);
  27.  
  28. typedef void(WINAPI *DLL_phWorldSetFrictionModel)(int model);
  29. DLL_phWorldSetFrictionModel phWorldSetFrictionModel;
  30. phWorldSetFrictionModel = (DLL_phWorldSetFrictionModel)GetProcAddress(nwDLL,"_phWorldSetFrictionModel@4");
  31. // Use ==> phWorldSetFrictionModel(int model);
  32.  
  33. typedef void(WINAPI *DLL_phWorldMagnetize)(float x, float y, float z, float r, float a0, float a1, float a2, float max);
  34. DLL_phWorldMagnetize phWorldMagnetize;
  35. phWorldMagnetize = (DLL_phWorldMagnetize)GetProcAddress(nwDLL,"_phWorldMagnetize@32");
  36. // Use ==> phWorldMagnetize(float x, float y, float z, float r, float a0, float a1, float a2, float max);
  37.  
  38. typedef void(WINAPI *DLL_phWorldDestroy)();
  39. DLL_phWorldDestroy phWorldDestroy;
  40. phWorldDestroy = (DLL_phWorldDestroy)GetProcAddress(nwDLL,"_phWorldDestroy@0");
  41. // Use ==> phWorldDestroy();
  42.  
  43. typedef int(WINAPI *DLL_phMatCreate)();
  44. DLL_phMatCreate phMatCreate;
  45. phMatCreate = (DLL_phMatCreate)GetProcAddress(nwDLL,"_phMatCreate@0");
  46. // Use ==> int result = phMatCreate();
  47.  
  48. typedef void(WINAPI *DLL_phMatSetCollidable)(int mat1, int mat2, int IsColl);
  49. DLL_phMatSetCollidable phMatSetCollidable;
  50. phMatSetCollidable = (DLL_phMatSetCollidable)GetProcAddress(nwDLL,"_phMatSetCollidable@12");
  51. // Use ==> phMatSetCollidable(int mat1, int mat2, int IsColl);
  52.  
  53. typedef void(WINAPI *DLL_phMatSetFriction)(int mat1, int mat2, float stFric, float dynFric);
  54. DLL_phMatSetFriction phMatSetFriction;
  55. phMatSetFriction = (DLL_phMatSetFriction)GetProcAddress(nwDLL,"_phMatSetFriction@16");
  56. // Use ==> phMatSetFriction(int mat1, int mat2, float stFric, float dynFric);
  57.  
  58. typedef void(WINAPI *DLL_phMatSetElasticity)(int mat1, int mat2, float elas);
  59. DLL_phMatSetElasticity phMatSetElasticity;
  60. phMatSetElasticity = (DLL_phMatSetElasticity)GetProcAddress(nwDLL,"_phMatSetElasticity@12");
  61. // Use ==> phMatSetElasticity(int mat1, int mat2, float elas);
  62.  
  63. typedef void(WINAPI *DLL_phMatSetSoftness)(int mat1, int mat2, float soft);
  64. DLL_phMatSetSoftness phMatSetSoftness;
  65. phMatSetSoftness = (DLL_phMatSetSoftness)GetProcAddress(nwDLL,"_phMatSetSoftness@12");
  66. // Use ==> phMatSetSoftness(int mat1, int mat2, float soft);
  67.  
  68. typedef void(WINAPI *DLL_phMatSetDefCollidable)(int IsColl);
  69. DLL_phMatSetDefCollidable phMatSetDefCollidable;
  70. phMatSetDefCollidable = (DLL_phMatSetDefCollidable)GetProcAddress(nwDLL,"_phMatSetDefCollidable@4");
  71. // Use ==> phMatSetDefCollidable(int IsColl);
  72.  
  73. typedef void(WINAPI *DLL_phMatSetDefFriction)(float stFric, float dynFric);
  74. DLL_phMatSetDefFriction phMatSetDefFriction;
  75. phMatSetDefFriction = (DLL_phMatSetDefFriction)GetProcAddress(nwDLL,"_phMatSetDefFriction@8");
  76. // Use ==> phMatSetDefFriction(float stFric, float dynFric);
  77.  
  78. typedef void(WINAPI *DLL_phMatSetDefElasticity)(float elas);
  79. DLL_phMatSetDefElasticity phMatSetDefElasticity;
  80. phMatSetDefElasticity = (DLL_phMatSetDefElasticity)GetProcAddress(nwDLL,"_phMatSetDefElasticity@4");
  81. // Use ==> phMatSetDefElasticity(float elas);
  82.  
  83. typedef void(WINAPI *DLL_phMatSetDefSoftness)(float soft);
  84. DLL_phMatSetDefSoftness phMatSetDefSoftness;
  85. phMatSetDefSoftness = (DLL_phMatSetDefSoftness)GetProcAddress(nwDLL,"_phMatSetDefSoftness@4");
  86. // Use ==> phMatSetDefSoftness(float soft);
  87.  
  88. typedef int(WINAPI *DLL_phBodyCreateNull)(float mass);
  89. DLL_phBodyCreateNull phBodyCreateNull;
  90. phBodyCreateNull = (DLL_phBodyCreateNull)GetProcAddress(nwDLL,"_phBodyCreateNull@4");
  91. // Use ==> int result = phBodyCreateNull(float mass);
  92.  
  93. typedef int(WINAPI *DLL_phBodyCreateBox)(float dx, float dy, float dz, float mass);
  94. DLL_phBodyCreateBox phBodyCreateBox;
  95. phBodyCreateBox = (DLL_phBodyCreateBox)GetProcAddress(nwDLL,"_phBodyCreateBox@16");
  96. // Use ==> int result = phBodyCreateBox(float dx, float dy, float dz, float mass);
  97.  
  98. typedef int(WINAPI *DLL_phBodyCreateSphere)(float rx, float ry, float rz, float mass);
  99. DLL_phBodyCreateSphere phBodyCreateSphere;
  100. phBodyCreateSphere = (DLL_phBodyCreateSphere)GetProcAddress(nwDLL,"_phBodyCreateSphere@16");
  101. // Use ==> int result = phBodyCreateSphere(float rx, float ry, float rz, float mass);
  102.  
  103. typedef int(WINAPI *DLL_phBodyCreateCyl)(float r, float h, float mass);
  104. DLL_phBodyCreateCyl phBodyCreateCyl;
  105. phBodyCreateCyl = (DLL_phBodyCreateCyl)GetProcAddress(nwDLL,"_phBodyCreateCyl@12");
  106. // Use ==> int result = phBodyCreateCyl(float r, float h, float mass);
  107.  
  108. typedef int(WINAPI *DLL_phBodyCreateCone)(float r, float h, float mass);
  109. DLL_phBodyCreateCone phBodyCreateCone;
  110. phBodyCreateCone = (DLL_phBodyCreateCone)GetProcAddress(nwDLL,"_phBodyCreateCone@12");
  111. // Use ==> int result = phBodyCreateCone(float r, float h, float mass);
  112.  
  113. typedef int(WINAPI *DLL_phBodyCreateCapsule)(float r, float h, float mass);
  114. DLL_phBodyCreateCapsule phBodyCreateCapsule;
  115. phBodyCreateCapsule = (DLL_phBodyCreateCapsule)GetProcAddress(nwDLL,"_phBodyCreateCapsule@12");
  116. // Use ==> int result = phBodyCreateCapsule(float r, float h, float mass);
  117.  
  118. typedef int(WINAPI *DLL_phBodyCreateHull)(int *Vertices, int VertexCount, float mass);
  119. DLL_phBodyCreateHull phBodyCreateHull;
  120. phBodyCreateHull = (DLL_phBodyCreateHull)GetProcAddress(nwDLL,"_phBodyCreateHull@12");
  121. // Use ==> int result = phBodyCreateHull(int *Vertices, int VertexCount, float mass);
  122.  
  123. typedef int(WINAPI *DLL_phBodyCreateMesh)(int *Vertices, int VertexCount, float mass);
  124. DLL_phBodyCreateMesh phBodyCreateMesh;
  125. phBodyCreateMesh = (DLL_phBodyCreateMesh)GetProcAddress(nwDLL,"_phBodyCreateMesh@12");
  126. // Use ==> int result = phBodyCreateMesh(int *Vertices, int VertexCount, float mass);
  127.  
  128. typedef void(WINAPI *DLL_phBodyCompoundBegin)();
  129. DLL_phBodyCompoundBegin phBodyCompoundBegin;
  130. phBodyCompoundBegin = (DLL_phBodyCompoundBegin)GetProcAddress(nwDLL,"_phBodyCompoundBegin@0");
  131. // Use ==> phBodyCompoundBegin();
  132.  
  133. typedef void(WINAPI *DLL_phBodyCompoundAddHull)(int *Vertices, int VertexCount);
  134. DLL_phBodyCompoundAddHull phBodyCompoundAddHull;
  135. phBodyCompoundAddHull = (DLL_phBodyCompoundAddHull)GetProcAddress(nwDLL,"_phBodyCompoundAddHull@8");
  136. // Use ==> phBodyCompoundAddHull(int *Vertices, int VertexCount);
  137.  
  138. typedef void(WINAPI *DLL_phBodyCompoundAddBody)(int body);
  139. DLL_phBodyCompoundAddBody phBodyCompoundAddBody;
  140. phBodyCompoundAddBody = (DLL_phBodyCompoundAddBody)GetProcAddress(nwDLL,"_phBodyCompoundAddBody@4");
  141. // Use ==> phBodyCompoundAddBody(int body);
  142.  
  143. typedef int(WINAPI *DLL_phBodyCompoundEnd)(float mass);
  144. DLL_phBodyCompoundEnd phBodyCompoundEnd;
  145. phBodyCompoundEnd = (DLL_phBodyCompoundEnd)GetProcAddress(nwDLL,"_phBodyCompoundEnd@4");
  146. // Use ==> int result = phBodyCompoundEnd(float mass);
  147.  
  148. typedef void(WINAPI *DLL_phBodyCompoundExBegin)();
  149. DLL_phBodyCompoundExBegin phBodyCompoundExBegin;
  150. phBodyCompoundExBegin = (DLL_phBodyCompoundExBegin)GetProcAddress(nwDLL,"_phBodyCompoundExBegin@0");
  151. // Use ==> phBodyCompoundExBegin();
  152.  
  153. typedef void(WINAPI *DLL_phBodyCompoundExAddHull)(int *Vertices, int VertexCount, float mass);
  154. DLL_phBodyCompoundExAddHull phBodyCompoundExAddHull;
  155. phBodyCompoundExAddHull = (DLL_phBodyCompoundExAddHull)GetProcAddress(nwDLL,"_phBodyCompoundExAddHull@12");
  156. // Use ==> phBodyCompoundExAddHull(int *Vertices, int VertexCount, float mass);
  157.  
  158. typedef void(WINAPI *DLL_phBodyCompoundExAddHullDens)(int *Vertices, int VertexCount, float density);
  159. DLL_phBodyCompoundExAddHullDens phBodyCompoundExAddHullDens;
  160. phBodyCompoundExAddHullDens = (DLL_phBodyCompoundExAddHullDens)GetProcAddress(nwDLL,"_phBodyCompoundExAddHullDens@12");
  161. // Use ==> phBodyCompoundExAddHullDens(int *Vertices, int VertexCount, float density);
  162.  
  163. typedef void(WINAPI *DLL_phBodyCompoundExAddBody)(int body);
  164. DLL_phBodyCompoundExAddBody phBodyCompoundExAddBody;
  165. phBodyCompoundExAddBody = (DLL_phBodyCompoundExAddBody)GetProcAddress(nwDLL,"_phBodyCompoundExAddBody@4");
  166. // Use ==> phBodyCompoundExAddBody(int body);
  167.  
  168. typedef int(WINAPI *DLL_phBodyCompoundExEnd)();
  169. DLL_phBodyCompoundExEnd phBodyCompoundExEnd;
  170. phBodyCompoundExEnd = (DLL_phBodyCompoundExEnd)GetProcAddress(nwDLL,"_phBodyCompoundExEnd@0");
  171. // Use ==> int result = phBodyCompoundExEnd();
  172.  
  173. typedef void(WINAPI *DLL_phBodyDestroy)(int body);
  174. DLL_phBodyDestroy phBodyDestroy;
  175. phBodyDestroy = (DLL_phBodyDestroy)GetProcAddress(nwDLL,"_phBodyDestroy@4");
  176. // Use ==> phBodyDestroy(int body);
  177.  
  178. typedef void(WINAPI *DLL_phBodySetMat)(int body, int mat);
  179. DLL_phBodySetMat phBodySetMat;
  180. phBodySetMat = (DLL_phBodySetMat)GetProcAddress(nwDLL,"_phBodySetMat@8");
  181. // Use ==> phBodySetMat(int body, int mat);
  182.  
  183. typedef int(WINAPI *DLL_phBodyGetMat)(int body);
  184. DLL_phBodyGetMat phBodyGetMat;
  185. phBodyGetMat = (DLL_phBodyGetMat)GetProcAddress(nwDLL,"_phBodyGetMat@4");
  186. // Use ==> int result = phBodyGetMat(int body);
  187.  
  188. typedef float(WINAPI *DLL_phBodyGetX)(int body);
  189. DLL_phBodyGetX phBodyGetX;
  190. phBodyGetX = (DLL_phBodyGetX)GetProcAddress(nwDLL,"_phBodyGetX@4");
  191. // Use ==> float result = phBodyGetX(int body);
  192.  
  193. typedef float(WINAPI *DLL_phBodyGetY)(int body);
  194. DLL_phBodyGetY phBodyGetY;
  195. phBodyGetY = (DLL_phBodyGetY)GetProcAddress(nwDLL,"_phBodyGetY@4");
  196. // Use ==> float result = phBodyGetY(int body);
  197.  
  198. typedef float(WINAPI *DLL_phBodyGetZ)(int body);
  199. DLL_phBodyGetZ phBodyGetZ;
  200. phBodyGetZ = (DLL_phBodyGetZ)GetProcAddress(nwDLL,"_phBodyGetZ@4");
  201. // Use ==> float result = phBodyGetZ(int body);
  202.  
  203. typedef void(WINAPI *DLL_phBodySetPos)(int boyd, float x, float y, float z);
  204. DLL_phBodySetPos phBodySetPos;
  205. phBodySetPos = (DLL_phBodySetPos)GetProcAddress(nwDLL,"_phBodySetPos@16");
  206. // Use ==> phBodySetPos(int boyd, float x, float y, float z);
  207.  
  208. typedef float(WINAPI *DLL_phBodyGetPitch)(int body);
  209. DLL_phBodyGetPitch phBodyGetPitch;
  210. phBodyGetPitch = (DLL_phBodyGetPitch)GetProcAddress(nwDLL,"_phBodyGetPitch@4");
  211. // Use ==> float result = phBodyGetPitch(int body);
  212.  
  213. typedef float(WINAPI *DLL_phBodyGetYaw)(int body);
  214. DLL_phBodyGetYaw phBodyGetYaw;
  215. phBodyGetYaw = (DLL_phBodyGetYaw)GetProcAddress(nwDLL,"_phBodyGetYaw@4");
  216. // Use ==> float result = phBodyGetYaw(int body);
  217.  
  218. typedef float(WINAPI *DLL_phBodyGetRoll)(int body);
  219. DLL_phBodyGetRoll phBodyGetRoll;
  220. phBodyGetRoll = (DLL_phBodyGetRoll)GetProcAddress(nwDLL,"_phBodyGetRoll@4");
  221. // Use ==> float result = phBodyGetRoll(int body);
  222.  
  223. typedef void(WINAPI *DLL_phBodySetRot)(int body, float pitch, float yaw, float roll);
  224. DLL_phBodySetRot phBodySetRot;
  225. phBodySetRot = (DLL_phBodySetRot)GetProcAddress(nwDLL,"_phBodySetRot@16");
  226. // Use ==> phBodySetRot(int body, float pitch, float yaw, float roll);
  227.  
  228. typedef float(WINAPI *DLL_phBodyGetVelX)(int body);
  229. DLL_phBodyGetVelX phBodyGetVelX;
  230. phBodyGetVelX = (DLL_phBodyGetVelX)GetProcAddress(nwDLL,"_phBodyGetVelX@4");
  231. // Use ==> float result = phBodyGetVelX(int body);
  232.  
  233. typedef float(WINAPI *DLL_phBodyGetVelY)(int body);
  234. DLL_phBodyGetVelY phBodyGetVelY;
  235. phBodyGetVelY = (DLL_phBodyGetVelY)GetProcAddress(nwDLL,"_phBodyGetVelY@4");
  236. // Use ==> float result = phBodyGetVelY(int body);
  237.  
  238. typedef float(WINAPI *DLL_phBodyGetVelZ)(int body);
  239. DLL_phBodyGetVelZ phBodyGetVelZ;
  240. phBodyGetVelZ = (DLL_phBodyGetVelZ)GetProcAddress(nwDLL,"_phBodyGetVelZ@4");
  241. // Use ==> float result = phBodyGetVelZ(int body);
  242.  
  243. typedef void(WINAPI *DLL_phBodySetVel)(int body, float vx, float vy, float vz);
  244. DLL_phBodySetVel phBodySetVel;
  245. phBodySetVel = (DLL_phBodySetVel)GetProcAddress(nwDLL,"_phBodySetVel@16");
  246. // Use ==> phBodySetVel(int body, float vx, float vy, float vz);
  247.  
  248. typedef float(WINAPI *DLL_phBodyGetVelXAtPos)(int body, float x, float y, float z);
  249. DLL_phBodyGetVelXAtPos phBodyGetVelXAtPos;
  250. phBodyGetVelXAtPos = (DLL_phBodyGetVelXAtPos)GetProcAddress(nwDLL,"_phBodyGetVelXAtPos@16");
  251. // Use ==> float result = phBodyGetVelXAtPos(int body, float x, float y, float z);
  252.  
  253. typedef float(WINAPI *DLL_phBodyGetVelYAtPos)(int body, float x, float y, float z);
  254. DLL_phBodyGetVelYAtPos phBodyGetVelYAtPos;
  255. phBodyGetVelYAtPos = (DLL_phBodyGetVelYAtPos)GetProcAddress(nwDLL,"_phBodyGetVelYAtPos@16");
  256. // Use ==> float result = phBodyGetVelYAtPos(int body, float x, float y, float z);
  257.  
  258. typedef float(WINAPI *DLL_phBodyGetVelZAtPos)(int body, float x, float y, float z);
  259. DLL_phBodyGetVelZAtPos phBodyGetVelZAtPos;
  260. phBodyGetVelZAtPos = (DLL_phBodyGetVelZAtPos)GetProcAddress(nwDLL,"_phBodyGetVelZAtPos@16");
  261. // Use ==> float result = phBodyGetVelZAtPos(int body, float x, float y, float z);
  262.  
  263. typedef float(WINAPI *DLL_phBodyGetOmegaX)(int body);
  264. DLL_phBodyGetOmegaX phBodyGetOmegaX;
  265. phBodyGetOmegaX = (DLL_phBodyGetOmegaX)GetProcAddress(nwDLL,"_phBodyGetOmegaX@4");
  266. // Use ==> float result = phBodyGetOmegaX(int body);
  267.  
  268. typedef float(WINAPI *DLL_phBodyGetOmegaY)(int body);
  269. DLL_phBodyGetOmegaY phBodyGetOmegaY;
  270. phBodyGetOmegaY = (DLL_phBodyGetOmegaY)GetProcAddress(nwDLL,"_phBodyGetOmegaY@4");
  271. // Use ==> float result = phBodyGetOmegaY(int body);
  272.  
  273. typedef float(WINAPI *DLL_phBodyGetOmegaZ)(int body);
  274. DLL_phBodyGetOmegaZ phBodyGetOmegaZ;
  275. phBodyGetOmegaZ = (DLL_phBodyGetOmegaZ)GetProcAddress(nwDLL,"_phBodyGetOmegaZ@4");
  276. // Use ==> float result = phBodyGetOmegaZ(int body);
  277.  
  278. typedef void(WINAPI *DLL_phBodySetOmega)(int body, float ox, float oy, float oz);
  279. DLL_phBodySetOmega phBodySetOmega;
  280. phBodySetOmega = (DLL_phBodySetOmega)GetProcAddress(nwDLL,"_phBodySetOmega@16");
  281. // Use ==> phBodySetOmega(int body, float ox, float oy, float oz);
  282.  
  283. typedef void(WINAPI *DLL_phBodyAddForce)(int body, float fx, float fy, float fz);
  284. DLL_phBodyAddForce phBodyAddForce;
  285. phBodyAddForce = (DLL_phBodyAddForce)GetProcAddress(nwDLL,"_phBodyAddForce@16");
  286. // Use ==> phBodyAddForce(int body, float fx, float fy, float fz);
  287.  
  288. typedef void(WINAPI *DLL_phBodyAddRelForce)(int body, float fx, float fy, float fz);
  289. DLL_phBodyAddRelForce phBodyAddRelForce;
  290. phBodyAddRelForce = (DLL_phBodyAddRelForce)GetProcAddress(nwDLL,"_phBodyAddRelForce@16");
  291. // Use ==> phBodyAddRelForce(int body, float fx, float fy, float fz);
  292.  
  293. typedef void(WINAPI *DLL_phBodyAddForceAtPos)(int body, float fx, float fy, float fz, float x, float y, float z);
  294. DLL_phBodyAddForceAtPos phBodyAddForceAtPos;
  295. phBodyAddForceAtPos = (DLL_phBodyAddForceAtPos)GetProcAddress(nwDLL,"_phBodyAddForceAtPos@28");
  296. // Use ==> phBodyAddForceAtPos(int body, float fx, float fy, float fz, float x, float y, float z);
  297.  
  298. typedef void(WINAPI *DLL_phBodyAddRelForceAtRelPos)(int body, float fx, float fy, float fz, float x, float y, float z);
  299. DLL_phBodyAddRelForceAtRelPos phBodyAddRelForceAtRelPos;
  300. phBodyAddRelForceAtRelPos = (DLL_phBodyAddRelForceAtRelPos)GetProcAddress(nwDLL,"_phBodyAddRelForceAtRelPos@28");
  301. // Use ==> phBodyAddRelForceAtRelPos(int body, float fx, float fy, float fz, float x, float y, float z);
  302.  
  303. typedef void(WINAPI *DLL_phBodyAddImpulse)(int body, float x, float y, float z, float vx, float vy, float vz);
  304. DLL_phBodyAddImpulse phBodyAddImpulse;
  305. phBodyAddImpulse = (DLL_phBodyAddImpulse)GetProcAddress(nwDLL,"_phBodyAddImpulse@28");
  306. // Use ==> phBodyAddImpulse(int body, float x, float y, float z, float vx, float vy, float vz);
  307.  
  308. typedef void(WINAPI *DLL_phBodySetGravityMode)(int body, int mode);
  309. DLL_phBodySetGravityMode phBodySetGravityMode;
  310. phBodySetGravityMode = (DLL_phBodySetGravityMode)GetProcAddress(nwDLL,"_phBodySetGravityMode@8");
  311. // Use ==> phBodySetGravityMode(int body, int mode);
  312.  
  313. typedef int(WINAPI *DLL_phBodyGetGravityMode)(int body);
  314. DLL_phBodyGetGravityMode phBodyGetGravityMode;
  315. phBodyGetGravityMode = (DLL_phBodyGetGravityMode)GetProcAddress(nwDLL,"_phBodyGetGravityMode@4");
  316. // Use ==> int result = phBodyGetGravityMode(int body);
  317.  
  318. typedef void(WINAPI *DLL_phBodySetWater)(int body, float x, float y, float z, float nx, float ny, float nz, float density, float lin_damping, float ang_damping);
  319. DLL_phBodySetWater phBodySetWater;
  320. phBodySetWater = (DLL_phBodySetWater)GetProcAddress(nwDLL,"_phBodySetWater@40");
  321. // Use ==> phBodySetWater(int body, float x, float y, float z, float nx, float ny, float nz, float density, float lin_damping, float ang_damping);
  322.  
  323. typedef void(WINAPI *DLL_phBodyDisableWater)(int body);
  324. DLL_phBodyDisableWater phBodyDisableWater;
  325. phBodyDisableWater = (DLL_phBodyDisableWater)GetProcAddress(nwDLL,"_phBodyDisableWater@4");
  326. // Use ==> phBodyDisableWater(int body);
  327.  
  328. typedef void(WINAPI *DLL_phBodyAddTorque)(int body, float tx, float ty, float tz);
  329. DLL_phBodyAddTorque phBodyAddTorque;
  330. phBodyAddTorque = (DLL_phBodyAddTorque)GetProcAddress(nwDLL,"_phBodyAddTorque@16");
  331. // Use ==> phBodyAddTorque(int body, float tx, float ty, float tz);
  332.  
  333. typedef void(WINAPI *DLL_phBodyAddRelTorque)(int body, float tx, float ty, float tz);
  334. DLL_phBodyAddRelTorque phBodyAddRelTorque;
  335. phBodyAddRelTorque = (DLL_phBodyAddRelTorque)GetProcAddress(nwDLL,"_phBodyAddRelTorque@16");
  336. // Use ==> phBodyAddRelTorque(int body, float tx, float ty, float tz);
  337.  
  338. typedef void(WINAPI *DLL_phBodySetDamping)(int body, float linear, float angular);
  339. DLL_phBodySetDamping phBodySetDamping;
  340. phBodySetDamping = (DLL_phBodySetDamping)GetProcAddress(nwDLL,"_phBodySetDamping@12");
  341. // Use ==> phBodySetDamping(int body, float linear, float angular);
  342.  
  343. typedef void(WINAPI *DLL_phBodySetContinuousCollisionMode)(int body, int mode);
  344. DLL_phBodySetContinuousCollisionMode phBodySetContinuousCollisionMode;
  345. phBodySetContinuousCollisionMode = (DLL_phBodySetContinuousCollisionMode)GetProcAddress(nwDLL,"_phBodySetContinuousCollisionMode@8");
  346. // Use ==> phBodySetContinuousCollisionMode(int body, int mode);
  347.  
  348. typedef int(WINAPI *DLL_phBodyGetContinuousCollisionMode)(int body);
  349. DLL_phBodyGetContinuousCollisionMode phBodyGetContinuousCollisionMode;
  350. phBodyGetContinuousCollisionMode = (DLL_phBodyGetContinuousCollisionMode)GetProcAddress(nwDLL,"_phBodyGetContinuousCollisionMode@4");
  351. // Use ==> int result = phBodyGetContinuousCollisionMode(int body);
  352.  
  353. typedef void(WINAPI *DLL_phBodySetSleep)(int body, int state);
  354. DLL_phBodySetSleep phBodySetSleep;
  355. phBodySetSleep = (DLL_phBodySetSleep)GetProcAddress(nwDLL,"_phBodySetSleep@8");
  356. // Use ==> phBodySetSleep(int body, int state);
  357.  
  358. typedef int(WINAPI *DLL_phBodyGetSleep)(int body);
  359. DLL_phBodyGetSleep phBodyGetSleep;
  360. phBodyGetSleep = (DLL_phBodyGetSleep)GetProcAddress(nwDLL,"_phBodyGetSleep@4");
  361. // Use ==> int result = phBodyGetSleep(int body);
  362.  
  363. typedef void(WINAPI *DLL_phBodySetAutoSleep)(int body, int state);
  364. DLL_phBodySetAutoSleep phBodySetAutoSleep;
  365. phBodySetAutoSleep = (DLL_phBodySetAutoSleep)GetProcAddress(nwDLL,"_phBodySetAutoSleep@8");
  366. // Use ==> phBodySetAutoSleep(int body, int state);
  367.  
  368. typedef void(WINAPI *DLL_phBodySetAutoSleepTreshold)(int body, float vel, float omega, int frames);
  369. DLL_phBodySetAutoSleepTreshold phBodySetAutoSleepTreshold;
  370. phBodySetAutoSleepTreshold = (DLL_phBodySetAutoSleepTreshold)GetProcAddress(nwDLL,"_phBodySetAutoSleepTreshold@16");
  371. // Use ==> phBodySetAutoSleepTreshold(int body, float vel, float omega, int frames);
  372.  
  373. typedef void(WINAPI *DLL_phBodySetData)(int body, int data);
  374. DLL_phBodySetData phBodySetData;
  375. phBodySetData = (DLL_phBodySetData)GetProcAddress(nwDLL,"_phBodySetData@8");
  376. // Use ==> phBodySetData(int body, int data);
  377.  
  378. typedef int(WINAPI *DLL_phBodyGetData)(int body);
  379. DLL_phBodyGetData phBodyGetData;
  380. phBodyGetData = (DLL_phBodyGetData)GetProcAddress(nwDLL,"_phBodyGetData@4");
  381. // Use ==> int result = phBodyGetData(int body);
  382.  
  383. typedef void(WINAPI *DLL_phBodySetEntity)(int body, int ent);
  384. DLL_phBodySetEntity phBodySetEntity;
  385. phBodySetEntity = (DLL_phBodySetEntity)GetProcAddress(nwDLL,"_phBodySetEntity@8");
  386. // Use ==> phBodySetEntity(int body, int ent);
  387.  
  388. typedef int(WINAPI *DLL_phBodyGetEntity)(int body);
  389. DLL_phBodyGetEntity phBodyGetEntity;
  390. phBodyGetEntity = (DLL_phBodyGetEntity)GetProcAddress(nwDLL,"_phBodyGetEntity@4");
  391. // Use ==> int result = phBodyGetEntity(int body);
  392.  
  393. typedef int(WINAPI *DLL_phBodyGetCollNum)(int body);
  394. DLL_phBodyGetCollNum phBodyGetCollNum;
  395. phBodyGetCollNum = (DLL_phBodyGetCollNum)GetProcAddress(nwDLL,"_phBodyGetCollNum@4");
  396. // Use ==> int result = phBodyGetCollNum(int body);
  397.  
  398. typedef float(WINAPI *DLL_phBodyGetCollX)(int body, int coll);
  399. DLL_phBodyGetCollX phBodyGetCollX;
  400. phBodyGetCollX = (DLL_phBodyGetCollX)GetProcAddress(nwDLL,"_phBodyGetCollX@8");
  401. // Use ==> float result = phBodyGetCollX(int body, int coll);
  402.  
  403. typedef float(WINAPI *DLL_phBodyGetCollY)(int body, int coll);
  404. DLL_phBodyGetCollY phBodyGetCollY;
  405. phBodyGetCollY = (DLL_phBodyGetCollY)GetProcAddress(nwDLL,"_phBodyGetCollY@8");
  406. // Use ==> float result = phBodyGetCollY(int body, int coll);
  407.  
  408. typedef float(WINAPI *DLL_phBodyGetCollZ)(int body, int coll);
  409. DLL_phBodyGetCollZ phBodyGetCollZ;
  410. phBodyGetCollZ = (DLL_phBodyGetCollZ)GetProcAddress(nwDLL,"_phBodyGetCollZ@8");
  411. // Use ==> float result = phBodyGetCollZ(int body, int coll);
  412.  
  413. typedef float(WINAPI *DLL_phBodyGetCollNX)(int body, int coll);
  414. DLL_phBodyGetCollNX phBodyGetCollNX;
  415. phBodyGetCollNX = (DLL_phBodyGetCollNX)GetProcAddress(nwDLL,"_phBodyGetCollNX@8");
  416. // Use ==> float result = phBodyGetCollNX(int body, int coll);
  417.  
  418. typedef float(WINAPI *DLL_phBodyGetCollNY)(int body, int coll);
  419. DLL_phBodyGetCollNY phBodyGetCollNY;
  420. phBodyGetCollNY = (DLL_phBodyGetCollNY)GetProcAddress(nwDLL,"_phBodyGetCollNY@8");
  421. // Use ==> float result = phBodyGetCollNY(int body, int coll);
  422.  
  423. typedef float(WINAPI *DLL_phBodyGetCollNZ)(int body, int coll);
  424. DLL_phBodyGetCollNZ phBodyGetCollNZ;
  425. phBodyGetCollNZ = (DLL_phBodyGetCollNZ)GetProcAddress(nwDLL,"_phBodyGetCollNZ@8");
  426. // Use ==> float result = phBodyGetCollNZ(int body, int coll);
  427.  
  428. typedef float(WINAPI *DLL_phBodyGetCollFX)(int body, int coll);
  429. DLL_phBodyGetCollFX phBodyGetCollFX;
  430. phBodyGetCollFX = (DLL_phBodyGetCollFX)GetProcAddress(nwDLL,"_phBodyGetCollFX@8");
  431. // Use ==> float result = phBodyGetCollFX(int body, int coll);
  432.  
  433. typedef float(WINAPI *DLL_phBodyGetCollFY)(int body, int coll);
  434. DLL_phBodyGetCollFY phBodyGetCollFY;
  435. phBodyGetCollFY = (DLL_phBodyGetCollFY)GetProcAddress(nwDLL,"_phBodyGetCollFY@8");
  436. // Use ==> float result = phBodyGetCollFY(int body, int coll);
  437.  
  438. typedef float(WINAPI *DLL_phBodyGetCollFZ)(int body, int coll);
  439. DLL_phBodyGetCollFZ phBodyGetCollFZ;
  440. phBodyGetCollFZ = (DLL_phBodyGetCollFZ)GetProcAddress(nwDLL,"_phBodyGetCollFZ@8");
  441. // Use ==> float result = phBodyGetCollFZ(int body, int coll);
  442.  
  443. typedef float(WINAPI *DLL_phBodyGetCollNVel)(int body, int coll);
  444. DLL_phBodyGetCollNVel phBodyGetCollNVel;
  445. phBodyGetCollNVel = (DLL_phBodyGetCollNVel)GetProcAddress(nwDLL,"_phBodyGetCollNVel@8");
  446. // Use ==> float result = phBodyGetCollNVel(int body, int coll);
  447.  
  448. typedef float(WINAPI *DLL_phBodyGetCollTVel)(int body, int coll);
  449. DLL_phBodyGetCollTVel phBodyGetCollTVel;
  450. phBodyGetCollTVel = (DLL_phBodyGetCollTVel)GetProcAddress(nwDLL,"_phBodyGetCollTVel@8");
  451. // Use ==> float result = phBodyGetCollTVel(int body, int coll);
  452.  
  453. typedef float(WINAPI *DLL_phBodyGetCollBVel)(int body, int coll);
  454. DLL_phBodyGetCollBVel phBodyGetCollBVel;
  455. phBodyGetCollBVel = (DLL_phBodyGetCollBVel)GetProcAddress(nwDLL,"_phBodyGetCollBVel@8");
  456. // Use ==> float result = phBodyGetCollBVel(int body, int coll);
  457.  
  458. typedef int(WINAPI *DLL_phBodyGetCollBody)(int body, int coll);
  459. DLL_phBodyGetCollBody phBodyGetCollBody;
  460. phBodyGetCollBody = (DLL_phBodyGetCollBody)GetProcAddress(nwDLL,"_phBodyGetCollBody@8");
  461. // Use ==> int result = phBodyGetCollBody(int body, int coll);
  462.  
  463. typedef int(WINAPI *DLL_phBodyIsCollidedWith)(int body1, int body2);
  464. DLL_phBodyIsCollidedWith phBodyIsCollidedWith;
  465. phBodyIsCollidedWith = (DLL_phBodyIsCollidedWith)GetProcAddress(nwDLL,"_phBodyIsCollidedWith@8");
  466. // Use ==> int result = phBodyIsCollidedWith(int body1, int body2);
  467.  
  468. typedef void(WINAPI *DLL_phBodySetMass)(int body, float mass);
  469. DLL_phBodySetMass phBodySetMass;
  470. phBodySetMass = (DLL_phBodySetMass)GetProcAddress(nwDLL,"_phBodySetMass@8");
  471. // Use ==> phBodySetMass(int body, float mass);
  472.  
  473. typedef void(WINAPI *DLL_phBodySetMassMatrix)(int body, float mass, float Ixx, float Iyy, float Izz);
  474. DLL_phBodySetMassMatrix phBodySetMassMatrix;
  475. phBodySetMassMatrix = (DLL_phBodySetMassMatrix)GetProcAddress(nwDLL,"_phBodySetMassMatrix@20");
  476. // Use ==> phBodySetMassMatrix(int body, float mass, float Ixx, float Iyy, float Izz);
  477.  
  478. typedef float(WINAPI *DLL_phBodyGetMass)(int body);
  479. DLL_phBodyGetMass phBodyGetMass;
  480. phBodyGetMass = (DLL_phBodyGetMass)GetProcAddress(nwDLL,"_phBodyGetMass@4");
  481. // Use ==> float result = phBodyGetMass(int body);
  482.  
  483. typedef float(WINAPI *DLL_phBodyGetMassIxx)(int body);
  484. DLL_phBodyGetMassIxx phBodyGetMassIxx;
  485. phBodyGetMassIxx = (DLL_phBodyGetMassIxx)GetProcAddress(nwDLL,"_phBodyGetMassIxx@4");
  486. // Use ==> float result = phBodyGetMassIxx(int body);
  487.  
  488. typedef float(WINAPI *DLL_phBodyGetMassIyy)(int body);
  489. DLL_phBodyGetMassIyy phBodyGetMassIyy;
  490. phBodyGetMassIyy = (DLL_phBodyGetMassIyy)GetProcAddress(nwDLL,"_phBodyGetMassIyy@4");
  491. // Use ==> float result = phBodyGetMassIyy(int body);
  492.  
  493. typedef float(WINAPI *DLL_phBodyGetMassIzz)(int body);
  494. DLL_phBodyGetMassIzz phBodyGetMassIzz;
  495. phBodyGetMassIzz = (DLL_phBodyGetMassIzz)GetProcAddress(nwDLL,"_phBodyGetMassIzz@4");
  496. // Use ==> float result = phBodyGetMassIzz(int body);
  497.  
  498. typedef void(WINAPI *DLL_phBodySetMassCentre)(int body, float x, float y, float z);
  499. DLL_phBodySetMassCentre phBodySetMassCentre;
  500. phBodySetMassCentre = (DLL_phBodySetMassCentre)GetProcAddress(nwDLL,"_phBodySetMassCentre@16");
  501. // Use ==> phBodySetMassCentre(int body, float x, float y, float z);
  502.  
  503. typedef float(WINAPI *DLL_phBodyGetMassCentreX)(int body);
  504. DLL_phBodyGetMassCentreX phBodyGetMassCentreX;
  505. phBodyGetMassCentreX = (DLL_phBodyGetMassCentreX)GetProcAddress(nwDLL,"_phBodyGetMassCentreX@4");
  506. // Use ==> float result = phBodyGetMassCentreX(int body);
  507.  
  508. typedef float(WINAPI *DLL_phBodyGetMassCentreY)(int body);
  509. DLL_phBodyGetMassCentreY phBodyGetMassCentreY;
  510. phBodyGetMassCentreY = (DLL_phBodyGetMassCentreY)GetProcAddress(nwDLL,"_phBodyGetMassCentreY@4");
  511. // Use ==> float result = phBodyGetMassCentreY(int body);
  512.  
  513. typedef float(WINAPI *DLL_phBodyGetMassCentreZ)(int body);
  514. DLL_phBodyGetMassCentreZ phBodyGetMassCentreZ;
  515. phBodyGetMassCentreZ = (DLL_phBodyGetMassCentreZ)GetProcAddress(nwDLL,"_phBodyGetMassCentreZ@4");
  516. // Use ==> float result = phBodyGetMassCentreZ(int body);
  517.  
  518. typedef float(WINAPI *DLL_phBodyGetVolume)(int body);
  519. DLL_phBodyGetVolume phBodyGetVolume;
  520. phBodyGetVolume = (DLL_phBodyGetVolume)GetProcAddress(nwDLL,"_phBodyGetVolume@4");
  521. // Use ==> float result = phBodyGetVolume(int body);
  522.  
  523. typedef void(WINAPI *DLL_phBodySetRayCasting)(int body, int raycast);
  524. DLL_phBodySetRayCasting phBodySetRayCasting;
  525. phBodySetRayCasting = (DLL_phBodySetRayCasting)GetProcAddress(nwDLL,"_phBodySetRayCasting@8");
  526. // Use ==> phBodySetRayCasting(int body, int raycast);
  527.  
  528. typedef int(WINAPI *DLL_phBodyGetRayCasting)(int body);
  529. DLL_phBodyGetRayCasting phBodyGetRayCasting;
  530. phBodyGetRayCasting = (DLL_phBodyGetRayCasting)GetProcAddress(nwDLL,"_phBodyGetRayCasting@4");
  531. // Use ==> int result = phBodyGetRayCasting(int body);
  532.  
  533. typedef void(WINAPI *DLL_phLevelBuildBegin)();
  534. DLL_phLevelBuildBegin phLevelBuildBegin;
  535. phLevelBuildBegin = (DLL_phLevelBuildBegin)GetProcAddress(nwDLL,"_phLevelBuildBegin@0");
  536. // Use ==> phLevelBuildBegin();
  537.  
  538. typedef void(WINAPI *DLL_phLevelAddFace)(float x1, float y1, float z1, float x2, float y2, float z2, float x3, float y3, float z3);
  539. DLL_phLevelAddFace phLevelAddFace;
  540. phLevelAddFace = (DLL_phLevelAddFace)GetProcAddress(nwDLL,"_phLevelAddFace@36");
  541. // Use ==> phLevelAddFace(float x1, float y1, float z1, float x2, float y2, float z2, float x3, float y3, float z3);
  542.  
  543. typedef int(WINAPI *DLL_phLevelBuildEnd)();
  544. DLL_phLevelBuildEnd phLevelBuildEnd;
  545. phLevelBuildEnd = (DLL_phLevelBuildEnd)GetProcAddress(nwDLL,"_phLevelBuildEnd@0");
  546. // Use ==> int result = phLevelBuildEnd();
  547.  
  548. typedef int(WINAPI *DLL_phTerrainCreate)(int nSize, float CellWidth, int *height);
  549. DLL_phTerrainCreate phTerrainCreate;
  550. phTerrainCreate = (DLL_phTerrainCreate)GetProcAddress(nwDLL,"_phTerrainCreate@12");
  551. // Use ==> int result = phTerrainCreate(int nSize, float CellWidth, int *height);
  552.  
  553. typedef int(WINAPI *DLL_phJointBallCreate)(float x, float y, float z, int body1, int body2);
  554. DLL_phJointBallCreate phJointBallCreate;
  555. phJointBallCreate = (DLL_phJointBallCreate)GetProcAddress(nwDLL,"_phJointBallCreate@20");
  556. // Use ==> int result = phJointBallCreate(float x, float y, float z, int body1, int body2);
  557.  
  558. typedef void(WINAPI *DLL_phJointBallSetLimit)(int joint, float nx, float ny, float nz, float coneAngle, float twistAngle);
  559. DLL_phJointBallSetLimit phJointBallSetLimit;
  560. phJointBallSetLimit = (DLL_phJointBallSetLimit)GetProcAddress(nwDLL,"_phJointBallSetLimit@24");
  561. // Use ==> phJointBallSetLimit(int joint, float nx, float ny, float nz, float coneAngle, float twistAngle);
  562.  
  563. typedef float(WINAPI *DLL_phJointBallGetForce)(int joint);
  564. DLL_phJointBallGetForce phJointBallGetForce;
  565. phJointBallGetForce = (DLL_phJointBallGetForce)GetProcAddress(nwDLL,"_phJointBallGetForce@4");
  566. // Use ==> float result = phJointBallGetForce(int joint);
  567.  
  568. typedef int(WINAPI *DLL_phJointHingeCreate)(float x, float y, float z, float nx, float ny, float nz, int body1, int body2);
  569. DLL_phJointHingeCreate phJointHingeCreate;
  570. phJointHingeCreate = (DLL_phJointHingeCreate)GetProcAddress(nwDLL,"_phJointHingeCreate@32");
  571. // Use ==> int result = phJointHingeCreate(float x, float y, float z, float nx, float ny, float nz, int body1, int body2);
  572.  
  573. typedef void(WINAPI *DLL_phJointHingeSetLimit)(int joint, float min, float max);
  574. DLL_phJointHingeSetLimit phJointHingeSetLimit;
  575. phJointHingeSetLimit = (DLL_phJointHingeSetLimit)GetProcAddress(nwDLL,"_phJointHingeSetLimit@12");
  576. // Use ==> phJointHingeSetLimit(int joint, float min, float max);
  577.  
  578. typedef float(WINAPI *DLL_phJointHingeGetAngle)(int joint);
  579. DLL_phJointHingeGetAngle phJointHingeGetAngle;
  580. phJointHingeGetAngle = (DLL_phJointHingeGetAngle)GetProcAddress(nwDLL,"_phJointHingeGetAngle@4");
  581. // Use ==> float result = phJointHingeGetAngle(int joint);
  582.  
  583. typedef float(WINAPI *DLL_phJointHingeGetOmega)(int joint);
  584. DLL_phJointHingeGetOmega phJointHingeGetOmega;
  585. phJointHingeGetOmega = (DLL_phJointHingeGetOmega)GetProcAddress(nwDLL,"_phJointHingeGetOmega@4");
  586. // Use ==> float result = phJointHingeGetOmega(int joint);
  587.  
  588. typedef float(WINAPI *DLL_phJointHingeGetForce)(int joint);
  589. DLL_phJointHingeGetForce phJointHingeGetForce;
  590. phJointHingeGetForce = (DLL_phJointHingeGetForce)GetProcAddress(nwDLL,"_phJointHingeGetForce@4");
  591. // Use ==> float result = phJointHingeGetForce(int joint);
  592.  
  593. typedef int(WINAPI *DLL_phJointSliderCreate)(float x, float y, float z, float nx, float ny, float nz, int body1, int body2);
  594. DLL_phJointSliderCreate phJointSliderCreate;
  595. phJointSliderCreate = (DLL_phJointSliderCreate)GetProcAddress(nwDLL,"_phJointSliderCreate@32");
  596. // Use ==> int result = phJointSliderCreate(float x, float y, float z, float nx, float ny, float nz, int body1, int body2);
  597.  
  598. typedef void(WINAPI *DLL_phJointSliderSetLimit)(int joint, float min, float max);
  599. DLL_phJointSliderSetLimit phJointSliderSetLimit;
  600. phJointSliderSetLimit = (DLL_phJointSliderSetLimit)GetProcAddress(nwDLL,"_phJointSliderSetLimit@12");
  601. // Use ==> phJointSliderSetLimit(int joint, float min, float max);
  602.  
  603. typedef float(WINAPI *DLL_phJointSliderGetPos)(int joint);
  604. DLL_phJointSliderGetPos phJointSliderGetPos;
  605. phJointSliderGetPos = (DLL_phJointSliderGetPos)GetProcAddress(nwDLL,"_phJointSliderGetPos@4");
  606. // Use ==> float result = phJointSliderGetPos(int joint);
  607.  
  608. typedef float(WINAPI *DLL_phJointSliderGetVel)(int joint);
  609. DLL_phJointSliderGetVel phJointSliderGetVel;
  610. phJointSliderGetVel = (DLL_phJointSliderGetVel)GetProcAddress(nwDLL,"_phJointSliderGetVel@4");
  611. // Use ==> float result = phJointSliderGetVel(int joint);
  612.  
  613. typedef float(WINAPI *DLL_phJointSliderGetForce)(int joint);
  614. DLL_phJointSliderGetForce phJointSliderGetForce;
  615. phJointSliderGetForce = (DLL_phJointSliderGetForce)GetProcAddress(nwDLL,"_phJointSliderGetForce@4");
  616. // Use ==> float result = phJointSliderGetForce(int joint);
  617.  
  618. typedef int(WINAPI *DLL_phJointCorkCreate)(float x, float y, float z, float nx, float ny, float nz, int body1, int body2);
  619. DLL_phJointCorkCreate phJointCorkCreate;
  620. phJointCorkCreate = (DLL_phJointCorkCreate)GetProcAddress(nwDLL,"_phJointCorkCreate@32");
  621. // Use ==> int result = phJointCorkCreate(float x, float y, float z, float nx, float ny, float nz, int body1, int body2);
  622.  
  623. typedef void(WINAPI *DLL_phJointCorkSetLimit)(float min, float max, float amin, float amax);
  624. DLL_phJointCorkSetLimit phJointCorkSetLimit;
  625. phJointCorkSetLimit = (DLL_phJointCorkSetLimit)GetProcAddress(nwDLL,"_phJointCorkSetLimit@20");
  626. // Use ==> phJointCorkSetLimit(float min, float max, float amin, float amax);
  627.  
  628. typedef float(WINAPI *DLL_phJointCorkGetPos)(int joint);
  629. DLL_phJointCorkGetPos phJointCorkGetPos;
  630. phJointCorkGetPos = (DLL_phJointCorkGetPos)GetProcAddress(nwDLL,"_phJointCorkGetPos@4");
  631. // Use ==> float result = phJointCorkGetPos(int joint);
  632.  
  633. typedef float(WINAPI *DLL_phJointCorkGetVel)(int joint);
  634. DLL_phJointCorkGetVel phJointCorkGetVel;
  635. phJointCorkGetVel = (DLL_phJointCorkGetVel)GetProcAddress(nwDLL,"_phJointCorkGetVel@4");
  636. // Use ==> float result = phJointCorkGetVel(int joint);
  637.  
  638. typedef float(WINAPI *DLL_phJointCorkGetAngle)(int joint);
  639. DLL_phJointCorkGetAngle phJointCorkGetAngle;
  640. phJointCorkGetAngle = (DLL_phJointCorkGetAngle)GetProcAddress(nwDLL,"_phJointCorkGetAngle@4");
  641. // Use ==> float result = phJointCorkGetAngle(int joint);
  642.  
  643. typedef float(WINAPI *DLL_phJointCorkGetOmega)(int joint);
  644. DLL_phJointCorkGetOmega phJointCorkGetOmega;
  645. phJointCorkGetOmega = (DLL_phJointCorkGetOmega)GetProcAddress(nwDLL,"_phJointCorkGetOmega@4");
  646. // Use ==> float result = phJointCorkGetOmega(int joint);
  647.  
  648. typedef float(WINAPI *DLL_phJointCorkGetForce)(int joint);
  649. DLL_phJointCorkGetForce phJointCorkGetForce;
  650. phJointCorkGetForce = (DLL_phJointCorkGetForce)GetProcAddress(nwDLL,"_phJointCorkGetForce@4");
  651. // Use ==> float result = phJointCorkGetForce(int joint);
  652.  
  653. typedef int(WINAPI *DLL_phJointUpVectorCreate)(float nx, float ny, float nz, int body);
  654. DLL_phJointUpVectorCreate phJointUpVectorCreate;
  655. phJointUpVectorCreate = (DLL_phJointUpVectorCreate)GetProcAddress(nwDLL,"_phJointUpVectorCreate@16");
  656. // Use ==> int result = phJointUpVectorCreate(float nx, float ny, float nz, int body);
  657.  
  658. typedef void(WINAPI *DLL_phJointUpVectorSetPin)(int joint, float nx, float ny, float nz);
  659. DLL_phJointUpVectorSetPin phJointUpVectorSetPin;
  660. phJointUpVectorSetPin = (DLL_phJointUpVectorSetPin)GetProcAddress(nwDLL,"_phJointUpVectorSetPin@16");
  661. // Use ==> phJointUpVectorSetPin(int joint, float nx, float ny, float nz);
  662.  
  663. typedef float(WINAPI *DLL_phJointUpVectorGetPinX)(int joint);
  664. DLL_phJointUpVectorGetPinX phJointUpVectorGetPinX;
  665. phJointUpVectorGetPinX = (DLL_phJointUpVectorGetPinX)GetProcAddress(nwDLL,"_phJointUpVectorGetPinX@4");
  666. // Use ==> float result = phJointUpVectorGetPinX(int joint);
  667.  
  668. typedef float(WINAPI *DLL_phJointUpVectorGetPinY)(int joint);
  669. DLL_phJointUpVectorGetPinY phJointUpVectorGetPinY;
  670. phJointUpVectorGetPinY = (DLL_phJointUpVectorGetPinY)GetProcAddress(nwDLL,"_phJointUpVectorGetPinY@4");
  671. // Use ==> float result = phJointUpVectorGetPinY(int joint);
  672.  
  673. typedef float(WINAPI *DLL_phJointUpVectorGetPinZ)(int joint);
  674. DLL_phJointUpVectorGetPinZ phJointUpVectorGetPinZ;
  675. phJointUpVectorGetPinZ = (DLL_phJointUpVectorGetPinZ)GetProcAddress(nwDLL,"_phJointUpVectorGetPinZ@4");
  676. // Use ==> float result = phJointUpVectorGetPinZ(int joint);
  677.  
  678. typedef int(WINAPI *DLL_phJointUniversalCreate)(float x, float y, float z, float nx1, float ny1, float nz1, float nx2, float ny2, float nz2, int body1, int body2);
  679. DLL_phJointUniversalCreate phJointUniversalCreate;
  680. phJointUniversalCreate = (DLL_phJointUniversalCreate)GetProcAddress(nwDLL,"_phJointUniversalCreate@44");
  681. // Use ==> int result = phJointUniversalCreate(float x, float y, float z, float nx1, float ny1, float nz1, float nx2, float ny2, float nz2, int body1, int body2);
  682.  
  683. typedef float(WINAPI *DLL_phJointUniversalGetAngle1)(int joint);
  684. DLL_phJointUniversalGetAngle1 phJointUniversalGetAngle1;
  685. phJointUniversalGetAngle1 = (DLL_phJointUniversalGetAngle1)GetProcAddress(nwDLL,"_phJointUniversalGetAngle1@4");
  686. // Use ==> float result = phJointUniversalGetAngle1(int joint);
  687.  
  688. typedef float(WINAPI *DLL_phJointUniversalGetAngle2)(int joint);
  689. DLL_phJointUniversalGetAngle2 phJointUniversalGetAngle2;
  690. phJointUniversalGetAngle2 = (DLL_phJointUniversalGetAngle2)GetProcAddress(nwDLL,"_phJointUniversalGetAngle2@4");
  691. // Use ==> float result = phJointUniversalGetAngle2(int joint);
  692.  
  693. typedef float(WINAPI *DLL_phJointUniversalGetOmega1)(int joint);
  694. DLL_phJointUniversalGetOmega1 phJointUniversalGetOmega1;
  695. phJointUniversalGetOmega1 = (DLL_phJointUniversalGetOmega1)GetProcAddress(nwDLL,"_phJointUniversalGetOmega1@4");
  696. // Use ==> float result = phJointUniversalGetOmega1(int joint);
  697.  
  698. typedef float(WINAPI *DLL_phJointUniversalGetOmega2)(int joint);
  699. DLL_phJointUniversalGetOmega2 phJointUniversalGetOmega2;
  700. phJointUniversalGetOmega2 = (DLL_phJointUniversalGetOmega2)GetProcAddress(nwDLL,"_phJointUniversalGetOmega2@4");
  701. // Use ==> float result = phJointUniversalGetOmega2(int joint);
  702.  
  703. typedef float(WINAPI *DLL_phJointUniversalGetForce)(int joint);
  704. DLL_phJointUniversalGetForce phJointUniversalGetForce;
  705. phJointUniversalGetForce = (DLL_phJointUniversalGetForce)GetProcAddress(nwDLL,"_phJointUniversalGetForce@4");
  706. // Use ==> float result = phJointUniversalGetForce(int joint);
  707.  
  708. typedef void(WINAPI *DLL_phJointUniversalSetLimit)(int joint, float min1, float max1, float min2, float max2);
  709. DLL_phJointUniversalSetLimit phJointUniversalSetLimit;
  710. phJointUniversalSetLimit = (DLL_phJointUniversalSetLimit)GetProcAddress(nwDLL,"_phJointUniversalSetLimit@20");
  711. // Use ==> phJointUniversalSetLimit(int joint, float min1, float max1, float min2, float max2);
  712.  
  713. typedef int(WINAPI *DLL_phJointSpringCreate)(float x1, float y1, float z1, float x2, float y2, float z2, float strong, float dampfer, int body1, int body2);
  714. DLL_phJointSpringCreate phJointSpringCreate;
  715. phJointSpringCreate = (DLL_phJointSpringCreate)GetProcAddress(nwDLL,"_phJointSpringCreate@40");
  716. // Use ==> int result = phJointSpringCreate(float x1, float y1, float z1, float x2, float y2, float z2, float strong, float dampfer, int body1, int body2);
  717.  
  718. typedef int(WINAPI *DLL_phJointFixedCreate)(int body1, int body2);
  719. DLL_phJointFixedCreate phJointFixedCreate;
  720. phJointFixedCreate = (DLL_phJointFixedCreate)GetProcAddress(nwDLL,"_phJointFixedCreate@8");
  721. // Use ==> int result = phJointFixedCreate(int body1, int body2);
  722.  
  723. typedef int(WINAPI *DLL_phJointSuspCreate)(float x, float y, float z, float nx1, float ny1, float nz1, float nx2, float ny2, float nz2, float k, float s, int body1, int body2);
  724. DLL_phJointSuspCreate phJointSuspCreate;
  725. phJointSuspCreate = (DLL_phJointSuspCreate)GetProcAddress(nwDLL,"_phJointSuspCreate@52");
  726. // Use ==> int result = phJointSuspCreate(float x, float y, float z, float nx1, float ny1, float nz1, float nx2, float ny2, float nz2, float k, float s, int body1, int body2);
  727.  
  728. typedef void(WINAPI *DLL_phJointSuspSetSteer)(int joint, float steer);
  729. DLL_phJointSuspSetSteer phJointSuspSetSteer;
  730. phJointSuspSetSteer = (DLL_phJointSuspSetSteer)GetProcAddress(nwDLL,"_phJointSuspSetSteer@8");
  731. // Use ==> phJointSuspSetSteer(int joint, float steer);
  732.  
  733. typedef void(WINAPI *DLL_phJointSuspAddTorque)(int joint, float torque);
  734. DLL_phJointSuspAddTorque phJointSuspAddTorque;
  735. phJointSuspAddTorque = (DLL_phJointSuspAddTorque)GetProcAddress(nwDLL,"_phJointSuspAddTorque@8");
  736. // Use ==> phJointSuspAddTorque(int joint, float torque);
  737.  
  738. typedef void(WINAPI *DLL_phJointSuspSetFriction)(int joint, float min, float max);
  739. DLL_phJointSuspSetFriction phJointSuspSetFriction;
  740. phJointSuspSetFriction = (DLL_phJointSuspSetFriction)GetProcAddress(nwDLL,"_phJointSuspSetFriction@12");
  741. // Use ==> phJointSuspSetFriction(int joint, float min, float max);
  742.  
  743. typedef void(WINAPI *DLL_phJointSuspSetLimit)(int joint, float nim, float max);
  744. DLL_phJointSuspSetLimit phJointSuspSetLimit;
  745. phJointSuspSetLimit = (DLL_phJointSuspSetLimit)GetProcAddress(nwDLL,"_phJointSuspSetLimit@12");
  746. // Use ==> phJointSuspSetLimit(int joint, float nim, float max);
  747.  
  748. typedef float(WINAPI *DLL_phJointSuspGetPos)(int joint);
  749. DLL_phJointSuspGetPos phJointSuspGetPos;
  750. phJointSuspGetPos = (DLL_phJointSuspGetPos)GetProcAddress(nwDLL,"_phJointSuspGetPos@4");
  751. // Use ==> float result = phJointSuspGetPos(int joint);
  752.  
  753. typedef void(WINAPI *DLL_phJointDestroy)(int joint);
  754. DLL_phJointDestroy phJointDestroy;
  755. phJointDestroy = (DLL_phJointDestroy)GetProcAddress(nwDLL,"_phJointDestroy@4");
  756. // Use ==> phJointDestroy(int joint);
  757.  
  758. typedef void(WINAPI *DLL_phJointSetCollisionMode)(int joint, int mode);
  759. DLL_phJointSetCollisionMode phJointSetCollisionMode;
  760. phJointSetCollisionMode = (DLL_phJointSetCollisionMode)GetProcAddress(nwDLL,"_phJointSetCollisionMode@8");
  761. // Use ==> phJointSetCollisionMode(int joint, int mode);
  762.  
  763. typedef void(WINAPI *DLL_phJointSetStiffness)(int joint, float stf);
  764. DLL_phJointSetStiffness phJointSetStiffness;
  765. phJointSetStiffness = (DLL_phJointSetStiffness)GetProcAddress(nwDLL,"_phJointSetStiffness@8");
  766. // Use ==> phJointSetStiffness(int joint, float stf);
  767.  
  768. typedef int(WINAPI *DLL_phJointVehicleCreate)(float upx, float upy, float upz, int body);
  769. DLL_phJointVehicleCreate phJointVehicleCreate;
  770. phJointVehicleCreate = (DLL_phJointVehicleCreate)GetProcAddress(nwDLL,"_phJointVehicleCreate@16");
  771. // Use ==> int result = phJointVehicleCreate(float upx, float upy, float upz, int body);
  772.  
  773. typedef int(WINAPI *DLL_phJointVehicleAddTire)(int veh, float dx, float dy, float dz, float nx, float ny, float nz, float mass, float width, float radius, float shock, float spring, float lenght, int mat);
  774. DLL_phJointVehicleAddTire phJointVehicleAddTire;
  775. phJointVehicleAddTire = (DLL_phJointVehicleAddTire)GetProcAddress(nwDLL,"_phJointVehicleAddTire@56");
  776. // Use ==> int result = phJointVehicleAddTire(int veh, float dx, float dy, float dz, float nx, float ny, float nz, float mass, float width, float radius, float shock, float spring, float lenght, int mat);
  777.  
  778. typedef float(WINAPI *DLL_phJointVehicleGetTireX)(int veh, int tire);
  779. DLL_phJointVehicleGetTireX phJointVehicleGetTireX;
  780. phJointVehicleGetTireX = (DLL_phJointVehicleGetTireX)GetProcAddress(nwDLL,"_phJointVehicleGetTireX@8");
  781. // Use ==> float result = phJointVehicleGetTireX(int veh, int tire);
  782.  
  783. typedef float(WINAPI *DLL_phJointVehicleGetTireY)(int veh, int tire);
  784. DLL_phJointVehicleGetTireY phJointVehicleGetTireY;
  785. phJointVehicleGetTireY = (DLL_phJointVehicleGetTireY)GetProcAddress(nwDLL,"_phJointVehicleGetTireY@8");
  786. // Use ==> float result = phJointVehicleGetTireY(int veh, int tire);
  787.  
  788. typedef float(WINAPI *DLL_phJointVehicleGetTireZ)(int veh, int tire);
  789. DLL_phJointVehicleGetTireZ phJointVehicleGetTireZ;
  790. phJointVehicleGetTireZ = (DLL_phJointVehicleGetTireZ)GetProcAddress(nwDLL,"_phJointVehicleGetTireZ@8");
  791. // Use ==> float result = phJointVehicleGetTireZ(int veh, int tire);
  792.  
  793. typedef float(WINAPI *DLL_phJointVehicleGetTirePitch)(int veh, int tire);
  794. DLL_phJointVehicleGetTirePitch phJointVehicleGetTirePitch;
  795. phJointVehicleGetTirePitch = (DLL_phJointVehicleGetTirePitch)GetProcAddress(nwDLL,"_phJointVehicleGetTirePitch@8");
  796. // Use ==> float result = phJointVehicleGetTirePitch(int veh, int tire);
  797.  
  798. typedef float(WINAPI *DLL_phJointVehicleGetTireYaw)(int veh, int tire);
  799. DLL_phJointVehicleGetTireYaw phJointVehicleGetTireYaw;
  800. phJointVehicleGetTireYaw = (DLL_phJointVehicleGetTireYaw)GetProcAddress(nwDLL,"_phJointVehicleGetTireYaw@8");
  801. // Use ==> float result = phJointVehicleGetTireYaw(int veh, int tire);
  802.  
  803. typedef float(WINAPI *DLL_phJointVehicleGetTireRoll)(int veh, int tire);
  804. DLL_phJointVehicleGetTireRoll phJointVehicleGetTireRoll;
  805. phJointVehicleGetTireRoll = (DLL_phJointVehicleGetTireRoll)GetProcAddress(nwDLL,"_phJointVehicleGetTireRoll@8");
  806. // Use ==> float result = phJointVehicleGetTireRoll(int veh, int tire);
  807.  
  808. typedef void(WINAPI *DLL_phJointVehicleSetTireSteer)(int veh, int tire, float steer);
  809. DLL_phJointVehicleSetTireSteer phJointVehicleSetTireSteer;
  810. phJointVehicleSetTireSteer = (DLL_phJointVehicleSetTireSteer)GetProcAddress(nwDLL,"_phJointVehicleSetTireSteer@12");
  811. // Use ==> phJointVehicleSetTireSteer(int veh, int tire, float steer);
  812.  
  813. typedef void(WINAPI *DLL_phJointVehicleAddTireTorque)(int veh, int tire, float torque);
  814. DLL_phJointVehicleAddTireTorque phJointVehicleAddTireTorque;
  815. phJointVehicleAddTireTorque = (DLL_phJointVehicleAddTireTorque)GetProcAddress(nwDLL,"_phJointVehicleAddTireTorque@12");
  816. // Use ==> phJointVehicleAddTireTorque(int veh, int tire, float torque);
  817.  
  818. typedef float(WINAPI *DLL_phJointVehicleGetTireOmega)(int veh, int tire);
  819. DLL_phJointVehicleGetTireOmega phJointVehicleGetTireOmega;
  820. phJointVehicleGetTireOmega = (DLL_phJointVehicleGetTireOmega)GetProcAddress(nwDLL,"_phJointVehicleGetTireOmega@8");
  821. // Use ==> float result = phJointVehicleGetTireOmega(int veh, int tire);
  822.  
  823. typedef float(WINAPI *DLL_phJointVehicleGetTireLoad)(int veh, int tire);
  824. DLL_phJointVehicleGetTireLoad phJointVehicleGetTireLoad;
  825. phJointVehicleGetTireLoad = (DLL_phJointVehicleGetTireLoad)GetProcAddress(nwDLL,"_phJointVehicleGetTireLoad@8");
  826. // Use ==> float result = phJointVehicleGetTireLoad(int veh, int tire);
  827.  
  828. typedef float(WINAPI *DLL_phJointVehicleGetTireLateralSpeed)(int veh, int tire);
  829. DLL_phJointVehicleGetTireLateralSpeed phJointVehicleGetTireLateralSpeed;
  830. phJointVehicleGetTireLateralSpeed = (DLL_phJointVehicleGetTireLateralSpeed)GetProcAddress(nwDLL,"_phJointVehicleGetTireLateralSpeed@8");
  831. // Use ==> float result = phJointVehicleGetTireLateralSpeed(int veh, int tire);
  832.  
  833. typedef float(WINAPI *DLL_phJointVehicleGetTireLongitudinalSpeed)(int veh, int tire);
  834. DLL_phJointVehicleGetTireLongitudinalSpeed phJointVehicleGetTireLongitudinalSpeed;
  835. phJointVehicleGetTireLongitudinalSpeed = (DLL_phJointVehicleGetTireLongitudinalSpeed)GetProcAddress(nwDLL,"_phJointVehicleGetTireLongitudinalSpeed@8");
  836. // Use ==> float result = phJointVehicleGetTireLongitudinalSpeed(int veh, int tire);
  837.  
  838. typedef int(WINAPI *DLL_phJointVehicleGetTireAir)(int veh, int tire);
  839. DLL_phJointVehicleGetTireAir phJointVehicleGetTireAir;
  840. phJointVehicleGetTireAir = (DLL_phJointVehicleGetTireAir)GetProcAddress(nwDLL,"_phJointVehicleGetTireAir@8");
  841. // Use ==> int result = phJointVehicleGetTireAir(int veh, int tire);
  842.  
  843. typedef int(WINAPI *DLL_phJointVehicleGetTireGrip)(int veh, int tire);
  844. DLL_phJointVehicleGetTireGrip phJointVehicleGetTireGrip;
  845. phJointVehicleGetTireGrip = (DLL_phJointVehicleGetTireGrip)GetProcAddress(nwDLL,"_phJointVehicleGetTireGrip@8");
  846. // Use ==> int result = phJointVehicleGetTireGrip(int veh, int tire);
  847.  
  848. typedef int(WINAPI *DLL_phJointVehicleGetTireTraction)(int veh, int tire);
  849. DLL_phJointVehicleGetTireTraction phJointVehicleGetTireTraction;
  850. phJointVehicleGetTireTraction = (DLL_phJointVehicleGetTireTraction)GetProcAddress(nwDLL,"_phJointVehicleGetTireTraction@8");
  851. // Use ==> int result = phJointVehicleGetTireTraction(int veh, int tire);
  852.  
  853. typedef void(WINAPI *DLL_phJointVehicleSetTireBrake)(int veh, int tire, float acc, float fric);
  854. DLL_phJointVehicleSetTireBrake phJointVehicleSetTireBrake;
  855. phJointVehicleSetTireBrake = (DLL_phJointVehicleSetTireBrake)GetProcAddress(nwDLL,"_phJointVehicleSetTireBrake@16");
  856. // Use ==> phJointVehicleSetTireBrake(int veh, int tire, float acc, float fric);
  857.  
  858. typedef void(WINAPI *DLL_phJointVehicleSetTireSliding)(int veh, int tire, float sidevel, float sidek, float longvel, float longk);
  859. DLL_phJointVehicleSetTireSliding phJointVehicleSetTireSliding;
  860. phJointVehicleSetTireSliding = (DLL_phJointVehicleSetTireSliding)GetProcAddress(nwDLL,"_phJointVehicleSetTireSliding@24");
  861. // Use ==> phJointVehicleSetTireSliding(int veh, int tire, float sidevel, float sidek, float longvel, float longk);
  862.  
  863. typedef void(WINAPI *DLL_phJointVehicleReset)(int veh);
  864. DLL_phJointVehicleReset phJointVehicleReset;
  865. phJointVehicleReset = (DLL_phJointVehicleReset)GetProcAddress(nwDLL,"_phJointVehicleReset@4");
  866. // Use ==> phJointVehicleReset(int veh);
  867.  
  868. typedef int(WINAPI *DLL_phJointDryRollingCreate)(int body, float radius, float friction);
  869. DLL_phJointDryRollingCreate phJointDryRollingCreate;
  870. phJointDryRollingCreate = (DLL_phJointDryRollingCreate)GetProcAddress(nwDLL,"_phJointDryRollingCreate@12");
  871. // Use ==> int result = phJointDryRollingCreate(int body, float radius, float friction);
  872.  
  873. typedef int(WINAPI *DLL_phJointDryRollingSetFriction)(int joint, float radius, float friction);
  874. DLL_phJointDryRollingSetFriction phJointDryRollingSetFriction;
  875. phJointDryRollingSetFriction = (DLL_phJointDryRollingSetFriction)GetProcAddress(nwDLL,"_phJointDryRollingSetFriction@12");
  876. // Use ==> int result = phJointDryRollingSetFriction(int joint, float radius, float friction);
  877.  
  878. typedef int(WINAPI *DLL_phJointPlaneCreate)(int body, float x, float y, float z, float nx, float ny, float nz);
  879. DLL_phJointPlaneCreate phJointPlaneCreate;
  880. phJointPlaneCreate = (DLL_phJointPlaneCreate)GetProcAddress(nwDLL,"_phJointPlaneCreate@28");
  881. // Use ==> int result = phJointPlaneCreate(int body, float x, float y, float z, float nx, float ny, float nz);
  882.  
  883. typedef int(WINAPI *DLL_phRayCast)(float x1, float y1, float z1, float x2, float y2, float z2);
  884. DLL_phRayCast phRayCast;
  885. phRayCast = (DLL_phRayCast)GetProcAddress(nwDLL,"_phRayCast@24");
  886. // Use ==> int result = phRayCast(float x1, float y1, float z1, float x2, float y2, float z2);
  887.  
  888. typedef float(WINAPI *DLL_phRayGetX)();
  889. DLL_phRayGetX phRayGetX;
  890. phRayGetX = (DLL_phRayGetX)GetProcAddress(nwDLL,"_phRayGetX@0");
  891. // Use ==> float result = phRayGetX();
  892.  
  893. typedef float(WINAPI *DLL_phRayGetY)();
  894. DLL_phRayGetY phRayGetY;
  895. phRayGetY = (DLL_phRayGetY)GetProcAddress(nwDLL,"_phRayGetY@0");
  896. // Use ==> float result = phRayGetY();
  897.  
  898. typedef float(WINAPI *DLL_phRayGetZ)();
  899. DLL_phRayGetZ phRayGetZ;
  900. phRayGetZ = (DLL_phRayGetZ)GetProcAddress(nwDLL,"_phRayGetZ@0");
  901. // Use ==> float result = phRayGetZ();
  902.  
  903. typedef float(WINAPI *DLL_phRayGetNX)();
  904. DLL_phRayGetNX phRayGetNX;
  905. phRayGetNX = (DLL_phRayGetNX)GetProcAddress(nwDLL,"_phRayGetNX@0");
  906. // Use ==> float result = phRayGetNX();
  907.  
  908. typedef float(WINAPI *DLL_phRayGetNY)();
  909. DLL_phRayGetNY phRayGetNY;
  910. phRayGetNY = (DLL_phRayGetNY)GetProcAddress(nwDLL,"_phRayGetNY@0");
  911. // Use ==> float result = phRayGetNY();
  912.  
  913. typedef float(WINAPI *DLL_phRayGetNZ)();
  914. DLL_phRayGetNZ phRayGetNZ;
  915. phRayGetNZ = (DLL_phRayGetNZ)GetProcAddress(nwDLL,"_phRayGetNZ@0");
  916. // Use ==> float result = phRayGetNZ();
  917.  
  918. typedef int(WINAPI *DLL_phRayGetBody)();
  919. DLL_phRayGetBody phRayGetBody;
  920. phRayGetBody = (DLL_phRayGetBody)GetProcAddress(nwDLL,"_phRayGetBody@0");
  921. // Use ==> int result = phRayGetBody();


Comments :


ZJP(Posted 1+ years ago)

 Save as "INCLUDE_newton.cpp".


 

SimplePortal 2.3.6 © 2008-2014, SimplePortal