Jump to content
Sign in to follow this  
Kirey

How to change attribute path

Recommended Posts

Hello! Help me please.. 

I have paced models whit primitiv attribute /shop/blablabla , but  i working in mat context. how to change attribute path /shop/blablabla >/mat/blablabla ? 

 

thanks of lot

Edited by Kirey

Share this post


Link to post
Share on other sites

you could do this in a Python sop maybe, although I am not very good with python

oldPath = /shop/blablabla

lastPart = oldPath.split("/")

newPath = "/mat/" + lastPart[-1]

Share this post


Link to post
Share on other sites

In vex:

s@path = "/shop/blablabla";
s@path = re_replace("blablabla", "mat", s@path);

  • Thanks 1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×