mcjZeroOrigin
================================================================================
Introduction
================================================================================
When importing wavefront objects ( .obj) in daz studio, the origin gets set to the geometric center of the object
but sometimes you purposefully modeled that object to have its center at ( 0, 0, 0 )
this script solves this in 1 click !
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
see the steel hooks on the boots .... that's why i wrote this script
================================================================================
History
================================================================================
May 1th 2018 7:34AM - release
================================================================================
Installation
================================================================================
The zip package is found at the bottom of this page
unzip it in your daz content folder,
typically :
C:\Users\USERNAME\Documents\DAZ 3D\Studio\My Library
once installed, it will appear in your content library, under
The Daz Script will be found in My Library / Scripts / mcasual
================================================================================
Use
================================================================================
select the object
run the script
this can be undone through Daz Studio's Edit/Undo
================================================================================
Source code
================================================================================
it's as simple as
THE CODE
var node = Scene.getPrimarySelection();
if( node )
{
beginUndo();
node.setOrigin( DzVec3( 0, 0, 0 ) );
acceptUndo( "mcjZeroOrigin" );
}
================================================================================
License
================================================================================
// by mCasual/Jacques
// You can use this script freely for personal or commercial use.
// You may not resell, distribute for profit, sub-license or rent this script in any way.
// you may credit this script to mCasual/Jacques
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
// PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE
// FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.