tumira Posted February 17, 2017 Share Posted February 17, 2017 I'm a bit confused about the return unit ? For example I set the camera at the editor at this position. x=0.0 , y=77, z=-27.0. When I use this code on the camera to get the z position, "self.entity:GetPosition().z" it returns -0.27 ? I need to multiply my position from codes to 100 to get the exact same value with the editor? Quote Link to comment Share on other sites More sharing options...
gamecreator Posted February 17, 2017 Share Posted February 17, 2017 Yes, the editor uses a different scale (multiplied by 100). Quote Link to comment Share on other sites More sharing options...
tumira Posted February 17, 2017 Author Share Posted February 17, 2017 Yes, the editor uses a different scale (multiplied by 100). But why ? 1 Quote Link to comment Share on other sites More sharing options...
macklebee Posted February 17, 2017 Share Posted February 17, 2017 It made more sense to use centimeters in the Editor when creating CSG as it would be easier to texture with common texture sizes (256, 512, etc instead of 2.56, 5.12, etc). The engine position related commands use or return meters. 1 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...
Josh Posted February 17, 2017 Share Posted February 17, 2017 This is why: http://www.leadwerks.com/werkspace/topic/10016-mapping-standards/ Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Einlander Posted February 17, 2017 Share Posted February 17, 2017 The editor use to be in Meters ( multiples of 10), but Josh changed it to be powers of 2 (256, 512, 1024). I still rather it was in multiples of 10. 256cm has no room for jumping indoors, so I have to make all my interiors 384cm, which is not as pretty in the editor. Quote Link to comment Share on other sites More sharing options...
tumira Posted February 18, 2017 Author Share Posted February 18, 2017 Why not just returns all unit in centimeters (code and editor) ? So it will standardize. I've been converting my Unity project and I noticed that Leadwerks value is way off. Turns out it returns value differently from the editor(cm and m). Its not a big problem, I just need to multiple the value that I got from codes to 100 to get it the same with the editor. But still In my opinion kinda odd to why not make it a standard for both editor and codes. Maybe to avoid breaking stuff up with current project ? Quote Link to comment Share on other sites More sharing options...
CharlesPax Posted February 24, 2017 Share Posted February 24, 2017 thank you Brynet-Inc for your reply. i understand that it has nothing to do with O/S. but what i want to change the return address of the function to my shellcode. can you please give me example how to do it.? with my source code. . Quote 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.