flachdrache Posted July 9, 2011 Share Posted July 9, 2011 Well, i try to get a 8 wheeler vehicle lua script to work and keep failing with the given .gmf pipeline. Currently i want to verify the memory leak the default monster_truck.lua produces but le2.43 keeps overwriting the .phy collider mesh in its own, given, folder ... and it seams the garbage collector of le2.43 just does a better job. The bad thing is, i need to fully understand leadwerks implementation within its newton boundaries - since i need the 8 wheeler, a jeep and a motorcycle for the player to drive. Please understand my issue here ... its by design. Well, here`s the deal ... UU3D cant export multi-group .gmf models (to my knowledge) - only fbx2gmf.exe does keep its childs to be found. The models structure looks like : scene-root (mesh:Static_Mesh) - Mesh:body - Mesh:Tire_L1 etc. etc - Mesh:TirePivot_L1 etc. etc Yes, i added tires and tire pivots ... just to have them available. These are scene root childs which can be found to hide/replace the visual models - which does happen. Here is the block of script : pivot=object.model:FindChild("PL1") -- PL1 is a Mesh:TirePivot if pivot~=nil then Print("found PL1") tireradius=pivot.aabb.h*2.0 object.vehicle:AddTire(TFormPoint(pivot.position, pivot.parent, model),tireradius,suspensionlength,springconstant,springdamper) object.tire[0]=LoadMesh("abstract::vehicle_truck_stryker_Wheel.gmf", object.model) pivot:Hide() end The "pivot" gets found and hidden, no matter if its my "Mesh:TirePivot" or my "Mesh:Tire". The instance of "TFormPoint(pivot.position, pivot.parent, model)" is what bugs me the most - the "model" in the line does have no reference but the very "class:CreateObject(model)" - which looks like a hack non the less. Even if the pivots got found and replaced by its visual, non physic, vehicle tires - the actual "AddTire" fails on me ... please take a look into the provided model source and help me understand this newton thing here ... a dummy vehicle SDK setup would be nice too and highly needed because of the model pipeline. thx. Quote AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3 zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5 Xxploration FPS in progress ... Link to comment Share on other sites More sharing options...
macklebee Posted July 9, 2011 Share Posted July 9, 2011 Assuming that the truck model has the same issue that the jeep model does, then you have ran into the same issue as I have. The mesh jeep model has all of the meshes in the hierarchy but the positions of the separate meshes are lost. All of their origins are the main model's origin, which then screws up the size of the tire radius and the placement of the physics tire. So you would have to offset it to the correct position for each tire as needed from the model's origin and set the tire radius separate from the bounding box. And the conversation with LE/UU3D has taken place concerning saving the mesh hierarchy (including the positions/origins of each separate mesh) but so far has fell on deaf ears. You can hack around it and save the mesh hierarchy from UU3D but it still suffers from the same issue of only one origin. Quote Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590 LE / 3DWS / BMX / Hexagon macklebee's channel Link to comment Share on other sites More sharing options...
flachdrache Posted July 9, 2011 Author Share Posted July 9, 2011 ? Thats the first time i read about a position of a subMesh could get lost - i wouldnt mind to set up a pivot rig ... if it works. So, there are still 6 to 9 other ways to do it differently ... good. PS: here is the 8 wheeler - just for reference. Jeep and Truck Models where found on the interweb w/o attached license e.g. for private use only. If you are a fancy 3dStudioMax owner - i wouldnt mind to get a working stryker_truck 8 wheeler. Edit : I looked in my database and the stryker vehicle was downloaded from "gfx-3d-model.blogspot.com" but is no longer featured there. Models w/o license end up in my "non-commercial" folder but this particular model was offered as no-strings-attached download. Quote AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3 zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5 Xxploration FPS in progress ... Link to comment Share on other sites More sharing options...
macklebee Posted July 9, 2011 Share Posted July 9, 2011 uu3d does not save the position information. look at your model in the modelviewer and you will see that the positions read 0,0,0... if you have the old windmill model and you view it with the modelviewer, you will see that its submesh has values for position referenced from the main model's origin. no unfortunately im not a 3dsmax owner... and even more unfortunate, it appears they are the only ones that have the ability to save mesh hierarchy correctly in LE. Quote Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590 LE / 3DWS / BMX / Hexagon macklebee's channel Link to comment Share on other sites More sharing options...
flachdrache Posted July 9, 2011 Author Share Posted July 9, 2011 OK - somewhat solved ... no 8 wheels though - i only get 4 visible wheels to spin atm. Quote AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3 zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5 Xxploration FPS in progress ... Link to comment Share on other sites More sharing options...
diedir Posted July 10, 2011 Share Posted July 10, 2011 never try but someone does know ! found on the front page site : Quote AMD Ryzen 5900HX - Nvidia RTX 3070 - 32 Go - 1To SSD - W11 Link to comment Share on other sites More sharing options...
flachdrache Posted July 10, 2011 Author Share Posted July 10, 2011 Well, i dont consider advertising being a wish list either but since there is no real sample for it i guess the script just breaks at one point. I was just too tired to go on / clean up. Edit: solved ... one actually just need to update all tires in the array. Clean and tweak vehicle model in uu3d to obj to blender-2.56, for positioning tires etc. relative to vehicle body (group origin to geometry). Quote AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3 zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5 Xxploration FPS in progress ... Link to comment Share on other sites More sharing options...
macklebee Posted July 10, 2011 Share Posted July 10, 2011 Clean and tweak vehicle model in uu3d to obj to blender-2.56, for positioning tires etc. relative to vehicle body (group origin to geometry). please explain this in detail. are you saying that your model now has individual origins for the individual submeshes or that you were just able to get the exact location of each submesh from blender then used those values to properly set the position of the tires by code? Quote Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590 LE / 3DWS / BMX / Hexagon macklebee's channel Link to comment Share on other sites More sharing options...
flachdrache Posted July 10, 2011 Author Share Posted July 10, 2011 Exactly - the pipeline worked out just like it should be. I wouldn't say programmer friendly but doable with little experience in blender. The mode itself has some issues which i need to fix still but the pos and orientation is finally there. The script is just like the monsterTruck but with 4x steering wheels. I already had imaginations of all kinds of horror scenarios for work arounds really ... good that no 6k model programm is needed too. I think grouping isnt needed at all just the models relation to each-other need to be obtained. Quote AMD 64 X2 Dual 5k - 4GB - XFX GForce9800GT - nv196.21 - WinXP Sp3 zBrush4R2 - Silo2Pro - Unwrap3DPro - Gile - MaPZone2.5 Xxploration FPS in progress ... Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.